Re: [edk2] [PATCH 1/2] ArmVirtPkg: build our DEBUG Shell using the small code model
Hi Ard, Apologies for tardiness. Could we move this into ShellPkg instead, since the mcmodel=tiny is globally applied for AARCH64, and any other direct consumers would also be affected by 2/2? / Leif On Mon, Aug 10, 2015 at 12:27:26PM +0200, Ard Biesheuvel wrote: The DEBUG build of the Shell exceeds 1 MB in size, which means that it cannot be built using the tiny code model. So force the use of the code model in this case. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- ArmVirtPkg/ArmVirt.dsc.inc | 9 + 1 file changed, 9 insertions(+) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc index 7bba6eba05a8..1ff126b2f6dc 100644 --- a/ArmVirtPkg/ArmVirt.dsc.inc +++ b/ArmVirtPkg/ArmVirt.dsc.inc @@ -406,4 +406,13 @@ [Components.common] gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0xFF gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize|FALSE gEfiMdePkgTokenSpaceGuid.PcdUefiLibMaxPrintBufferSize|8000 + +BuildOptions + # + # The DEBUG target of the Shell module may well end up being over 1 MB + # in size, which exceeds the range of the AArch64 tiny code model. So + # override the code model to 'small' in this case. + # + GCC:DEBUG_*_AARCH64_CC_FLAGS = -mcmodel=small + GCC:DEBUG_*_AARCH64_DLINK_FLAGS = -z common-page-size=0x1000 } -- 1.9.1 ___ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel
Re: [edk2] [PATCH 1/2] ArmVirtPkg: build our DEBUG Shell using the small code model
On 12 August 2015 at 01:58, Laszlo Ersek ler...@redhat.com wrote: On 08/10/15 12:27, Ard Biesheuvel wrote: The DEBUG build of the Shell exceeds 1 MB in size, which means that it cannot be built using the tiny code model. So force the use of the code model in this case. You forgot the word small. Can be fixed up at commit time. OK Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- ArmVirtPkg/ArmVirt.dsc.inc | 9 + 1 file changed, 9 insertions(+) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc index 7bba6eba05a8..1ff126b2f6dc 100644 --- a/ArmVirtPkg/ArmVirt.dsc.inc +++ b/ArmVirtPkg/ArmVirt.dsc.inc @@ -406,4 +406,13 @@ [Components.common] gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0xFF gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize|FALSE gEfiMdePkgTokenSpaceGuid.PcdUefiLibMaxPrintBufferSize|8000 + +BuildOptions + # + # The DEBUG target of the Shell module may well end up being over 1 MB + # in size, which exceeds the range of the AArch64 tiny code model. So + # override the code model to 'small' in this case. + # + GCC:DEBUG_*_AARCH64_CC_FLAGS = -mcmodel=small + GCC:DEBUG_*_AARCH64_DLINK_FLAGS = -z common-page-size=0x1000 } I hope all this finesse is going to work with gcc-4.8! :) GCC48 is my primary development toolchain, so that should be fine. For the record, I also tested with the new CLANG35 toolchain, which doesn't support the tiny code model, but happily accepts it as a command line parameter if it is superseded with 'small' later. I.e., after applying 2/2, we will pass -mcmodel=tiny ... -mcmodel=small to Clang, without any ill effects. Reviewed-by: Laszlo Ersek ler...@redhat.com Thanks, Ard. ___ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel
[edk2] [PATCH 1/2] ArmVirtPkg: build our DEBUG Shell using the small code model
The DEBUG build of the Shell exceeds 1 MB in size, which means that it cannot be built using the tiny code model. So force the use of the code model in this case. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- ArmVirtPkg/ArmVirt.dsc.inc | 9 + 1 file changed, 9 insertions(+) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc index 7bba6eba05a8..1ff126b2f6dc 100644 --- a/ArmVirtPkg/ArmVirt.dsc.inc +++ b/ArmVirtPkg/ArmVirt.dsc.inc @@ -406,4 +406,13 @@ [Components.common] gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0xFF gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize|FALSE gEfiMdePkgTokenSpaceGuid.PcdUefiLibMaxPrintBufferSize|8000 + +BuildOptions + # + # The DEBUG target of the Shell module may well end up being over 1 MB + # in size, which exceeds the range of the AArch64 tiny code model. So + # override the code model to 'small' in this case. + # + GCC:DEBUG_*_AARCH64_CC_FLAGS = -mcmodel=small + GCC:DEBUG_*_AARCH64_DLINK_FLAGS = -z common-page-size=0x1000 } -- 1.9.1 ___ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel