<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">While we are talking about what toolchain targets should do I don’t understand this [1]? Why does OVMF need to turn on —keepexceptiontable? If these toolchains require it why don’t they turn it on? I see Mike fixed it[2]. Is this another case of a global GENFW_FLAG breaking things? Looks like the CLANGPDB toolchain does what I would expect, and the other toolchains do not? Is there some history here I’m missing?<div class=""><br class=""></div><div class="">[1] <font color="#9fa01c" class=""><span style="caret-color: rgb(159, 160, 28);" class=""> </span></font><span style="font-family: Menlo; font-size: 11px; font-variant-ligatures: no-common-ligatures;" class="">$ git grep "keepexceptiontable"</span><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">BaseTools/Conf/tools_def.template</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">2872</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">DEBUG_CLANGPDB_X64_GENFW_FLAGS      = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">BaseTools/Conf/tools_def.template</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">2882</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">NOOPT_CLANGPDB_X64_GENFW_FLAGS      = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures;" class="">…</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures;" class="">OvmfPkg/OvmfPkgIa32X64.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: rgb(46, 174, 187);" class="">:</span><span style="font-variant-ligatures: no-common-ligatures;" class="">80</span><span style="font-variant-ligatures: no-common-ligatures; color: rgb(46, 174, 187);" class="">:</span><span style="font-variant-ligatures: no-common-ligatures;" class="">  MSFT:*_*_X64_GENFW_FLAGS  = </span>--<b style="color: rgb(180, 36, 25);" class="">keepexceptiontable</b></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfPkgIa32X64.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">81</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  GCC:*_*_X64_GENFW_FLAGS   = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfPkgIa32X64.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">82</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  INTEL:*_*_X64_GENFW_FLAGS = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfPkgX64.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">80</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  MSFT:*_*_X64_GENFW_FLAGS  = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfPkgX64.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">81</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  GCC:*_*_X64_GENFW_FLAGS   = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfPkgX64.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">82</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  INTEL:*_*_X64_GENFW_FLAGS = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfXen.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">71</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  MSFT:*_*_X64_GENFW_FLAGS  = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfXen.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">72</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  GCC:*_*_X64_GENFW_FLAGS   = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">OvmfPkg/OvmfXen.dsc</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">73</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">  INTEL:*_*_X64_GENFW_FLAGS = --</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">keepexceptiontable</b></span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class=""><br class=""></b></span></div><div class="">[2] $ git show bbcafc442b2db</div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(159, 160, 28);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">commit bbcafc442b2db91322dd3ba04e166236a41b111d</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">Author: mdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">Date:   Wed Oct 3 21:00:26 2012 +0000</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""></span><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    The exception table information in X64 PE/COFF images is being stripped by default in the OvmfPkg.</span></div><p style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    </span><br class="webkit-block-placeholder"></p><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    This patch preserves this information when SOURCE_DEBUG_ENABLE is set.</span></div><p style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    </span><br class="webkit-block-placeholder"></p><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    Contributed-under: TianoCore Contribution Agreement 1.0</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    Signed-off-by: Michael Kinney <<a href="mailto:michael.d.kinney@intel.com" class="">michael.d.kinney@intel.com</a>></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    Reviewed-by: Laszlo Ersek</span></div><p style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    </span><br class="webkit-block-placeholder"></p><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">    git-svn-id: <a href="https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13780" class="">https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13780</a> 6f19259b-4bc3-4df7-8a09-765794883524</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""></span><br class=""></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">index 9b2ba8626ab3..40fd5e97b24e 100644</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">--- a/OvmfPkg/OvmfPkgIa32X64.dsc</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">+++ b/OvmfPkg/OvmfPkgIa32X64.dsc</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(46, 174, 187);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">@@ -41,7 +41,12 @@</span><span style="font-variant-ligatures: no-common-ligatures; color: #000000" class=""> [BuildOptions]</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">   INTEL:RELEASE_*_*_CC_FLAGS           = /D MDEPKG_NDEBUG</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">   MSFT:RELEASE_*_*_CC_FLAGS            = /D MDEPKG_NDEBUG</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">   GCC:*_*_*_CC_FLAGS                   = -mno-mmx -mno-sse</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(180, 36, 25);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">-</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+!ifdef $(SOURCE_DEBUG_ENABLE)</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+  MSFT:*_*_X64_GENFW_FLAGS  = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+!endif</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures; color: #2fb41d" class="">+</span><span style="font-variant-ligatures: no-common-ligatures; background-color: #850002" class="">  </span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> ################################################################################</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> #</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> # SKU Identification section - list of all SKU IDs supported by this Platform.</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">index 9ff4a5de1005..c61d41dccbbe 100644</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">--- a/OvmfPkg/OvmfPkgX64.dsc</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><b class="">+++ b/OvmfPkg/OvmfPkgX64.dsc</b></span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(46, 174, 187);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">@@ -41,6 +41,11 @@</span><span style="font-variant-ligatures: no-common-ligatures; color: #000000" class=""> [BuildOptions]</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">   INTEL:RELEASE_*_*_CC_FLAGS           = /D MDEPKG_NDEBUG</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">   MSFT:RELEASE_*_*_CC_FLAGS            = /D MDEPKG_NDEBUG</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">   GCC:*_*_*_CC_FLAGS                   = -mno-mmx -mno-sse</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+!ifdef $(SOURCE_DEBUG_ENABLE)</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+  MSFT:*_*_X64_GENFW_FLAGS  = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal; color: rgb(47, 180, 29);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+!endif</span></div><p style="margin: 0px; font-stretch: normal; line-height: normal; min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> </span><br class="webkit-block-placeholder"></p><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> ################################################################################</span></div><div style="margin: 0px; font-stretch: normal; line-height: normal;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> #</span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><br class=""></span></div></div><div><br class=""></div><div>Thanks,</div><div><br class=""></div><div>Andrew Fish</div><div><br class=""><blockquote type="cite" class=""><div class="">On Mar 24, 2021, at 8:38 PM, Andrew Fish <<a href="mailto:afish@apple.com" class="">afish@apple.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Liming,<div class=""><br class=""></div><div class="">I understand how the tool works, but that is not how it is used. To make it work like other toolchains *_*_*_GENFW_FLAGS for ELF targets should pass —zero for builds that do not contain symbols. This is how it works today [1].</div><div class=""><br class=""></div><div class="">The proposed fix is a global hammer ` RELEASE_*_*_GENFW_FLAGS = --zero` and it prevents some one from overriding the toolchain definition to turn on source level debugging for Release builds. In all the other places this is a tool chain choice. So my complaint is solving this globally vs. on a per toolchain basis. All the other toolchains don’t produce.</div><div class=""><br class=""></div><div class="">If you look at the XCODE5 toolchian that we override the edk2 default   DEBUG_XCODE5_X64_CC_FLAGS has -g and RELEASE_XCODE5_X64_CC_FLAGS does not. So the source level debugging or not is part of the compiler target choice. </div><div class=""><div class="">  DEBUG_XCODE5_*_MTOC_FLAGS = -align 0x20 -d $(DEBUG_DIR)/$(MODULE_NAME).dll</div><div class="">RELEASE_XCODE5_*_MTOC_FLAGS = -align 0x20</div><div class=""><br class=""></div><div class="">For our override we pass -g to RELEASE builds CC_FLAGS and do `RELEASE_XCODE5_*_MTOC_FLAGS = -align 0x20 -d $(MODULE_GUID)` so the override to force --zero on every call to GenFw will break this. </div><div class=""><br class=""></div><div class="">So my point is if the toolchain is generating a Debug Directory entry in a RELEASE target that does not support debugging then that target should setting `RELEASE_<target>_*_GENFW_FLAGS = —zero` to undo the unwanted work. I understand why the debug info gets added as it reduces the complexity of the ELF to PE/COFF conversion, so I’m not complaining about that just that the ELF targets don’t handle this themselves. So to me this fix is working the bug of the ELF targets not passing —zero on RELEASE builds to GenFw.</div><div class=""><br class=""></div><div class="">[1] <span style="font-family: Menlo; font-size: 11px;" class="">$ git grep _GENFW_FLAGS -- *.template</span></div><div class=""><div class=""><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">BaseTools/Conf/tools_def.template</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">2872</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">DEBUG_CLANGPDB_X64</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">_GENFW_FLAGS</b></span><span style="font-variant-ligatures: no-common-ligatures" class="">      = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">BaseTools/Conf/tools_def.template</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">2877</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">RELEASE_CLANGPDB_X64</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">_GENFW_FLAGS</b></span><span style="font-variant-ligatures: no-common-ligatures" class="">    =</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">BaseTools/Conf/tools_def.template</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">2882</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">NOOPT_CLANGPDB_X64</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">_GENFW_FLAGS</b></span><span style="font-variant-ligatures: no-common-ligatures" class="">      = --keepexceptiontable</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">BaseTools/Conf/tools_def.template</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">3124</span><span style="font-variant-ligatures: no-common-ligatures; color: #2eaebb" class="">:</span><span style="font-variant-ligatures: no-common-ligatures" class="">*_*_*</span><span style="font-variant-ligatures: no-common-ligatures; color: #b42419" class=""><b class="">_GENFW_FLAGS</b></span><span style="font-variant-ligatures: no-common-ligatures" class="">                  =</span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><br class=""></span></div></div></div><div class="">Thanks,</div><div class=""><br class=""></div><div class="">Andrew Fish</div><div class=""><br class=""><blockquote type="cite" class=""><div class="">On Mar 24, 2021, at 7:24 PM, gaoliming <<a href="mailto:gaoliming@byosoft.com.cn" class="">gaoliming@byosoft.com.cn</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta charset="UTF-8" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" style="font-size: 10.5pt; font-family: 等线;" class="">Andrew:<o:p class=""></o:p></span></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" style="font-size: 10.5pt; font-family: 等线;" class=""> GenFw generates debug entry, and zero debug entry. Its functionality is same to the image without debug entry. So, new option is not introduced to control whether GenFw generates debug entry when it converts ELF image to EFI image.<span class="Apple-converted-space"> </span><o:p class=""></o:p></span></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" style="font-size: 10.5pt; font-family: 等线;" class=""><o:p class=""> </o:p></span></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" style="font-size: 10.5pt; font-family: 等线;" class="">Thanks<o:p class=""></o:p></span></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" style="font-size: 10.5pt; font-family: 等线;" class="">Liming<o:p class=""></o:p></span></div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div style="border-style: solid none none; border-top-width: 1pt; border-top-color: rgb(225, 225, 225); padding: 3pt 0cm 0cm;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><b class=""><span style="font-size: 11pt; font-family: 等线;" class="">发件人<span lang="EN-US" class="">:</span></span></b><span lang="EN-US" style="font-size: 11pt; font-family: 等线;" class=""><span class="Apple-converted-space"> </span><a href="mailto:devel@edk2.groups.io" style="color: blue; text-decoration: underline;" class="">devel@edk2.groups.io</a><span class="Apple-converted-space"> </span><<a href="mailto:devel@edk2.groups.io" style="color: blue; text-decoration: underline;" class="">devel@edk2.groups.io</a>><span class="Apple-converted-space"> </span></span><b class=""><span style="font-size: 11pt; font-family: 等线;" class="">代表<span class="Apple-converted-space"> </span></span></b><span lang="EN-US" style="font-size: 11pt; font-family: 等线;" class="">Andrew Fish via<span class="Apple-converted-space"> </span><a href="http://groups.io/" style="color: blue; text-decoration: underline;" class="">groups.io</a><br class=""></span><b class=""><span style="font-size: 11pt; font-family: 等线;" class="">发送时间<span lang="EN-US" class="">:</span></span></b><span lang="EN-US" style="font-size: 11pt; font-family: 等线;" class=""><span class="Apple-converted-space"> </span>2021</span><span style="font-size: 11pt; font-family: 等线;" class="">年<span lang="EN-US" class="">3</span>月<span lang="EN-US" class="">25</span>日<span lang="EN-US" class=""><span class="Apple-converted-space"> </span>7:26<br class=""></span><b class="">收件人<span lang="EN-US" class="">:</span></b><span lang="EN-US" class=""><span class="Apple-converted-space"> </span>edk2-devel-groups-io <<a href="mailto:devel@edk2.groups.io" style="color: blue; text-decoration: underline;" class="">devel@edk2.groups.io</a>>;<span class="Apple-converted-space"> </span><a href="mailto:ross@burtonini.com" style="color: blue; text-decoration: underline;" class="">ross@burtonini.com</a><br class=""></span><b class="">抄送<span lang="EN-US" class="">:</span></b><span lang="EN-US" class=""><span class="Apple-converted-space"> </span><a href="mailto:lersek@redhat.com" style="color: blue; text-decoration: underline;" class="">lersek@redhat.com</a><br class=""></span><b class="">主题<span lang="EN-US" class="">:</span></b><span lang="EN-US" class=""><span class="Apple-converted-space"> </span>Re: [edk2-devel] [PATCH v2] OvmfPkg: strip build paths in release builds<o:p class=""></o:p></span></span></div></div></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span lang="EN-US" class="">This breaks some usage we have have in our fork. We have symbols turned on for Release builds, so this change would break that. <o:p class=""></o:p></span></div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div></div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">It looks to me that the root cause of this issue might be that the GenFw is blindly writing the debug directory entry into the PE/COFF? For native PE/COFF I think this is controlled by linker flags? For Xcode/clang it is controlled by the *_XCODE5_*_MTOC_FLAGS. So at this point it is kind of up to each toolchain how they want to deal with symbols on release builds. <o:p class=""></o:p></span></div></div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div></div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">It seems kind of strange to insert a section and then zero it. Almost seems like the intent of —zero was to post process compare images? <o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div></div><div class=""><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">  -z, --zero            Zero the Debug Data Fields in the PE input image file.<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                        It also zeros the time stamp fields.<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                        This option can be used to compare the binary efi image.<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                        It can't be combined with other action options<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                        except for -o, -r option. It is a action option.<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                        If it is combined with other action options, the later<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 8.5pt; font-family: Menlo, serif;" class="">                        input action option will override the previous one.<o:p class=""></o:p></span></div></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div></div><div class=""><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">And in case you are going to ask our fork uses relative paths from the Build directory and/or a UUID string for the Debug Directory entry file name so it is a constant value and does not impact build reproducibility. <o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">From a feature stand point this change will break any hope of source level debugging with RELEASE builds. I also think it changes the exception handler code output in OVMF [1] for ELF toolchains. You are going to get the (No PDB) vs. the file and path you were getting today. I assume if you had tools that natively produce PE/COFF and did not have a Debug Directory entry the same thing would happen prior to this change. <o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div></div><div class=""><table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" style="border-collapse: collapse; box-sizing: border-box; border-spacing: 0px; tab-size: 8; caret-color: rgb(36, 41, 46);"><tbody class=""><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L133" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC133" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">   <span class="Apple-converted-space"> </span>Status =<span class="Apple-converted-space"> </span><span class="pl-c1">PeCoffLoaderGetEntryPoint</span><span class="Apple-converted-space"> </span>((VOID *) Pe32Data, &EntryPoint);<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L134" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC134" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">    <span class="pl-k">if</span><span class="Apple-converted-space"> </span>(<span class="pl-c1">EFI_ERROR</span><span class="Apple-converted-space"> </span>(Status)) {<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L135" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC135" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">     <span class="Apple-converted-space"> </span>EntryPoint =<span class="Apple-converted-space"> </span><span class="pl-c1">NULL</span>;<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L136" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC136" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">   <span class="Apple-converted-space"> </span>}<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L137" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC137" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">    <span class="pl-c1">InternalPrintMessage</span><span class="Apple-converted-space"> </span>(<span class="pl-pds">"</span><span class="pl-s">!!!! Find image based on IP(0x</span><span class="pl-c1">%x</span><span class="pl-s">)<span class="Apple-converted-space"> </span></span><span class="pl-pds">"</span>, CurrentEip);<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L138" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC138" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">   <span class="Apple-converted-space"> </span>PdbPointer =<span class="Apple-converted-space"> </span><span class="pl-c1">PeCoffLoaderGetPdbPointer</span><span class="Apple-converted-space"> </span>((VOID *) Pe32Data);<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L139" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC139" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">    <span class="pl-k">if</span><span class="Apple-converted-space"> </span>(PdbPointer !=<span class="Apple-converted-space"> </span><span class="pl-c1">NULL</span>) {<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L140" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC140" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">      <span class="pl-c1">InternalPrintMessage</span><span class="Apple-converted-space"> </span>(<span class="pl-pds">"</span><span class="pl-c1">%a</span><span class="pl-pds">"</span>, PdbPointer);<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L141" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC141" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">   <span class="Apple-converted-space"> </span>}<span class="Apple-converted-space"> </span><span class="pl-k">else</span><span class="Apple-converted-space"> </span>{<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L142" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC142" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">      <span class="pl-c1">InternalPrintMessage</span><span class="Apple-converted-space"> </span>(<span class="pl-pds">"</span><span class="pl-s">(No PDB)<span class="Apple-converted-space"> </span></span><span class="pl-pds">"</span><span class="Apple-converted-space"> </span>);<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L143" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC143" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">   <span class="Apple-converted-space"> </span>}<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L144" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC144" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">    <span class="pl-c1">InternalPrintMessage</span><span class="Apple-converted-space"> </span>(<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L145" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC145" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">      <span class="pl-pds">"</span><span class="pl-s"><span class="Apple-converted-space"> </span>(ImageBase=</span><span class="pl-c1">%016lp</span><span class="pl-s">, EntryPoint=</span><span class="pl-c1">%016p</span><span class="pl-s">) !!!!</span><span class="pl-cce">\n</span><span class="pl-pds">"</span>,<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L146" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC146" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">     <span class="Apple-converted-space"> </span>(VOID *) Pe32Data,<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L147" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC147" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">     <span class="Apple-converted-space"> </span>EntryPoint<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td width="50" nowrap="" valign="top" id="L148" style="width: 37.5pt; padding: 0cm 7.5pt; box-sizing: border-box; min-width: 50px; color: var(--color-diff-blob-num-text); cursor: pointer; -webkit-user-select: none;" class=""></td><td valign="top" id="LC148" style="padding: 0cm 7.5pt; box-sizing: border-box; color: var(--color-text-primary); overflow: visible;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体; line-height: 15pt;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class="">     <span class="Apple-converted-space"> </span>);<o:p class=""></o:p></span></div></td></tr><tr style="box-sizing: border-box;" class=""><td style="padding: 0.75pt;" class=""></td><td style="padding: 0.75pt;" class=""></td></tr></tbody></table></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">Not saying we have to "stop the presses", but just trying to point out the side effects of this change. It is not so much that this change is bad, but that we have no way to turn off the Debug Directory Entry for ELF conversion, so we seem to be working around that issue with a bigger hammer?<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" style="font-size: 10.5pt; font-family: 等线;" class=""><o:p class=""> </o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">[1] <a href="https://github.com/tianocore/edk2/blob/master/UefiCpuPkg/Library/CpuExceptionHandlerLib/CpuExceptionCommon.c#L117" style="color: blue; text-decoration: underline;" class="">https://github.com/tianocore/edk2/blob/master/UefiCpuPkg/Library/CpuExceptionHandlerLib/CpuExceptionCommon.c#L117</a><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">Thanks,<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">Andrew Fish<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><br class=""><br class=""><o:p class=""></o:p></span></div><blockquote style="margin-top: 5pt; margin-bottom: 5pt;" class="" type="cite"><div class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class="">On Mar 24, 2021, at 4:58 AM, Ross Burton <<a href="mailto:ross@burtonini.com" style="color: blue; text-decoration: underline;" class="">ross@burtonini.com</a>> wrote:<o:p class=""></o:p></span></div></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div><div class=""><div class=""><p class="MsoNormal" style="margin: 0cm 0cm 12pt; font-size: 12pt; font-family: 宋体;"><span lang="EN-US" class="">GenFw will embed a NB10 section which contains the path to the input file,<br class="">which means the output files have build paths embedded in them.  To reduce<br class="">information leakage and ensure reproducible builds, pass --zero in release<br class="">builds to remove this information.<br class=""><br class="">Ref:<span class="Apple-converted-space"> </span><a href="https://bugzilla.tianocore.org/show_bug.cgi?id=3256" style="color: blue; text-decoration: underline;" class="">https://bugzilla.tianocore.org/show_bug.cgi?id=3256</a><br class="">Signed-off-by: Ross Burton <<a href="mailto:ross.burton@arm.com" style="color: blue; text-decoration: underline;" class="">ross.burton@arm.com</a>><br class="">---<br class="">OvmfPkg/AmdSev/AmdSevX64.dsc | 1 +<br class="">OvmfPkg/Bhyve/BhyveX64.dsc   | 1 +<br class="">OvmfPkg/OvmfPkgIa32.dsc      | 1 +<br class="">OvmfPkg/OvmfPkgIa32X64.dsc   | 1 +<br class="">OvmfPkg/OvmfPkgX64.dsc       | 1 +<br class="">OvmfPkg/OvmfXen.dsc          | 1 +<br class="">6 files changed, 6 insertions(+)<br class=""><br class="">diff --git a/OvmfPkg/AmdSev/AmdSevX64.dsc b/OvmfPkg/AmdSev/AmdSevX64.dsc<br class="">index 65c42284d9..69a05feea9 100644<br class="">--- a/OvmfPkg/AmdSev/AmdSevX64.dsc<br class="">+++ b/OvmfPkg/AmdSev/AmdSevX64.dsc<br class="">@@ -78,6 +78,7 @@<br class="">  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable<br class="">  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable<br class="">!endif<br class="">+  RELEASE_*_*_GENFW_FLAGS = --zero<br class=""><br class="">  #<br class="">  # Disable deprecated APIs.<br class="">diff --git a/OvmfPkg/Bhyve/BhyveX64.dsc b/OvmfPkg/Bhyve/BhyveX64.dsc<br class="">index 4a1cdf5aca..132f55cf69 100644<br class="">--- a/OvmfPkg/Bhyve/BhyveX64.dsc<br class="">+++ b/OvmfPkg/Bhyve/BhyveX64.dsc<br class="">@@ -76,6 +76,7 @@<br class="">  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable<br class="">  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable<br class="">!endif<br class="">+  RELEASE_*_*_GENFW_FLAGS = --zero<br class=""><br class="">  #<br class="">  # Disable deprecated APIs.<br class="">diff --git a/OvmfPkg/OvmfPkgIa32.dsc b/OvmfPkg/OvmfPkgIa32.dsc<br class="">index 1eaf3e99c6..93c209950c 100644<br class="">--- a/OvmfPkg/OvmfPkgIa32.dsc<br class="">+++ b/OvmfPkg/OvmfPkgIa32.dsc<br class="">@@ -80,6 +80,7 @@<br class="">!if $(TOOL_CHAIN_TAG) != "XCODE5" && $(TOOL_CHAIN_TAG) != "CLANGPDB"<br class="">  GCC:*_*_*_CC_FLAGS                   = -mno-mmx -mno-sse<br class="">!endif<br class="">+  RELEASE_*_*_GENFW_FLAGS = --zero<br class=""><br class="">  #<br class="">  # Disable deprecated APIs.<br class="">diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc<br class="">index 4a5a430147..97cc438250 100644<br class="">--- a/OvmfPkg/OvmfPkgIa32X64.dsc<br class="">+++ b/OvmfPkg/OvmfPkgIa32X64.dsc<br class="">@@ -84,6 +84,7 @@<br class="">  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable<br class="">  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable<br class="">!endif<br class="">+  RELEASE_*_*_GENFW_FLAGS = --zero<br class=""><br class="">  #<br class="">  # Disable deprecated APIs.<br class="">diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc<br class="">index d4d601b444..f544fb04bf 100644<br class="">--- a/OvmfPkg/OvmfPkgX64.dsc<br class="">+++ b/OvmfPkg/OvmfPkgX64.dsc<br class="">@@ -84,6 +84,7 @@<br class="">  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable<br class="">  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable<br class="">!endif<br class="">+  RELEASE_*_*_GENFW_FLAGS = --zero<br class=""><br class="">  #<br class="">  # Disable deprecated APIs.<br class="">diff --git a/OvmfPkg/OvmfXen.dsc b/OvmfPkg/OvmfXen.dsc<br class="">index 507029404f..fcaa35acf1 100644<br class="">--- a/OvmfPkg/OvmfXen.dsc<br class="">+++ b/OvmfPkg/OvmfXen.dsc<br class="">@@ -74,6 +74,7 @@<br class="">  GCC:*_*_X64_GENFW_FLAGS   = --keepexceptiontable<br class="">  INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable<br class="">!endif<br class="">+  RELEASE_*_*_GENFW_FLAGS = --zero<br class=""><br class="">  #<br class="">  # Disable deprecated APIs.<br class="">--<span class="Apple-converted-space"> </span><br class="">2.25.1<br class=""><br class=""><br class=""><br class=""><br class=""><br class=""><o:p class=""></o:p></span></p></div></div></blockquote></div><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""><span lang="EN-US" class=""><o:p class=""> </o:p></span></div></div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div style="margin: 0cm; font-size: 12pt; font-family: 宋体;" class=""></div></div></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></div></body></html>


 <div width="1" style="color:white;clear:both">_._,_._,_</div> <hr> Groups.io Links:<p>   You receive all messages sent to this group.    <p> <a target="_blank" href="https://edk2.groups.io/g/devel/message/73254">View/Reply Online (#73254)</a> |    |  <a target="_blank" href="https://groups.io/mt/81594755/1813853">Mute This Topic</a>  | <a href="https://edk2.groups.io/g/devel/post">New Topic</a><br>    <a href="https://edk2.groups.io/g/devel/editsub/1813853">Your Subscription</a> | <a href="mailto:devel+owner@edk2.groups.io">Contact Group Owner</a> |  <a href="https://edk2.groups.io/g/devel/unsub">Unsubscribe</a>  [edk2-devel-archive@redhat.com]<br> <div width="1" style="color:white;clear:both">_._,_._,_</div>