[BOLT][NFC] Disable ProcessAllSections in RuntimeDyld
Summary: FBD55943 changed the way ProcessAllSections works in RuntimeDyld. After the change, all sections, including symbol table, section table, etc. are loaded into memory whenever ProcessAllSections is enabled. In BOLT we rely on RuntimeDyld for processing sections with relocations. These include most allocatable sections and additionally .debug_line. The latter is skipped by RuntimeDyld without ProcessAllSections flag. If we enable ProcessAllSections, we will have to deal with allocating memory for more sections than we need (see above) and later to filter them out. The alternative is to mark all sections that we actually plan to use as "required for execution" (using RuntimeDyld terminology). For .debug_line section on ELF it means adding SHF_ALLOC flag. On MachO, RuntimeDyld currently treats all sections as required. (cherry picked from FBD28729398)
parent
5a6c379f
Please register or sign in to comment