From: Pete Batard <pete@akeo.ie>
To: Andrew Fish <afish@apple.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>,
"edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Subject: Re: [PATCH 0/1] MdeModulePkg/EbcDxe: add ARM support
Date: Thu, 22 Sep 2016 22:40:29 +0100 [thread overview]
Message-ID: <9313821b-b0f8-1548-838e-1d64dafb7bc0@akeo.ie> (raw)
In-Reply-To: <418FE198-0CCC-4A8F-8C70-69BBF4E2EF05@apple.com>
Hi Andrew,
On 2016.09.22 21:27, Andrew Fish wrote:
> It seems like tracking the PUSHes would work?
First of all, as got pointed out by Ard, I need to mention that much of
my earlier analysis results, which you quoted, were due to a misread of
the specs, as it does mandates pushing 32 bit parameters as native.
So the output I gave for AARCH64 and X64 was erroneous, since it was a
result of using PUSH32, and the problematic output disappears when using
PUSHn.
The only issue therefore, is with 32 bit ARM.
> We could update the spec to require this behavior.
If the idea is to add the tracking when processing POP/PUSH on Arm
(which is how I originally saw it), please note that we may also have to
track stack manipulation with MOV against R0, the EBC stack pointer, if
someone issues something like 'MOV R0, R0(-1,0)' (equivalent to PUSHn)
or 'MOV R0, R0(0,-8)' (equivalent to PUSH64) for some 32 or 64 bit
optional parameter...
However, this brings us back to our original issue if there exists a
succession of optional 32 and 64 bit parameters, which the application
doesn't care about filling, and that may be handled with a single 'MOV
R0, R0(-1,-8)' in the assembly. If we are faced with this in our
tracking, then we still have no way of knowing which of the 32 or 64 bit
parameter comes first.
So, notwithstanding other issues, we'd have to mandate something very
specific against doing this in the UEFI/EBC specs (such as only using
individual PUSHes)...
Regards,
/Pete
next prev parent reply other threads:[~2016-09-22 21:40 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-22 9:43 [PATCH 0/1] MdeModulePkg/EbcDxe: add ARM support Pete Batard
2016-09-22 10:06 ` Ard Biesheuvel
2016-09-22 10:13 ` Ard Biesheuvel
2016-09-22 11:05 ` Pete Batard
2016-09-22 11:14 ` Ard Biesheuvel
2016-09-22 11:26 ` Pete Batard
2016-09-22 11:40 ` Ard Biesheuvel
2016-09-22 20:27 ` Andrew Fish
2016-09-22 21:21 ` Ard Biesheuvel
2016-09-22 21:40 ` Pete Batard [this message]
2016-09-22 21:24 ` Andrew Fish
2016-09-22 21:29 ` Ard Biesheuvel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9313821b-b0f8-1548-838e-1d64dafb7bc0@akeo.ie \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox