public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH 0/1] MdeModulePkg/EbcDxe: add ARM support
@ 2016-09-22  9:43 Pete Batard
  2016-09-22 10:06 ` Ard Biesheuvel
  0 siblings, 1 reply; 12+ messages in thread
From: Pete Batard @ 2016-09-22  9:43 UTC (permalink / raw)
  To: edk2-devel

Hi,

The following is an updated/fixed version of the patch(es), put forward 
by Ard Biesheuvel on August 9 ([1], [2]), and re-submitted for formal 
inclusion, so that the EDK2 can provide EBC functionality for all of 
IA32, IA64, X64, AARCH64 and ARM at last.

This updated patch now includes the necessary corollary dsc/fdf updates 
as well as fixes to the assembly's EbcLLCALLEXNative, as I found the 
following issues there:
- At least gcc5 didn't seem to like the manually optimized branching for 
all register args ("sub r1, r1, r3, lsr #1"), and one can never be sure 
of the actual size instructions will be assembled into, in case of 
assembler internal alignment/optimization, so I broke it down into 
actual labelled branches. There are only 4 of those anyway.
- For register + stack calls, while 8 x 64 bit registers on AARCH64 do 
equate to #64 bytes that need to be taken off the stack, on ARM the 4 x 
32 bit registers equate to #16 bytes, not #32
- Even after fixing the above, I found some issues with the manual stack 
duplication assembly code, so I switched to using a call to CopyMem(), 
like IA32 does.

With these changes, I believe that the ARM/EBC feature should be fully 
functional, especially as I have heavily tested multiparameter calls 
from EBC into native, using an fasmg-based EBC assembler [3], to confirm 
that they performed just as well with ARM as with AARCH64, IA32 or X64.

Regards,

/Pete

[1] https://patches.linaro.org/patch/73554/
[2] https://patches.linaro.org/patch/73559/
[3] https://github.com/pbatard/fasmg-ebc


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2016-09-22 21:40 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
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
2016-09-22 21:24     ` Andrew Fish
2016-09-22 21:29       ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox