Files
clang-p2996/bolt/test/X86/Inputs/ambiguous_fragment.script
Amir Ayupov 3fe50b6dde [BOLT] Store FileSymRefs in a multimap
With aggressive ICF, it's possible to have different local symbols
(under different FILE symbols) to be mapped to the same address.

FileSymRefs only keeps a single SymbolRef per address, which prevents
fragment matching from finding the correct symbol to perform parent
function lookup.

Work around this issue by switching FileSymRefs to a multimap. In
future, uses of FileSymRefs can be replaced with SortedSymbols which
keeps essentially the same information.

Test Plan: added ambiguous_fragment.test

Reviewers: dcci, ayermolo, maksfb, rafaelauler

Reviewed By: rafaelauler

Pull Request: https://github.com/llvm/llvm-project/pull/98992
2024-07-16 22:14:43 -07:00

7 lines
99 B
Plaintext

SECTIONS {
. = 0x10000;
.text : { *(.text) }
. = 0x20000;
.text.cold : { *(.text.cold) }
}