summaryrefslogtreecommitdiffstats
path: root/llvm/test/DebugInfo/omit-empty.ll
Commit message (Collapse)AuthorAgeFilesLines
* Mark a test as requiring a default tripleVedant Kumar2017-05-311-0/+1
| | | | | | | | | | | | | This test assumes that llc can infer a default triple. I'm not sure why exactly, but the Verify MachineInstrs bot requires tests to be explicit about this dependency. This commit follows the lead from r248452 and adds in 'REQUIRES: default_triple' to omit-empty.ll. Bot URL: http://lab.llvm.org:8080/green/job/Verify-Machineinstrs_AArch64/7500 llvm-svn: 304269
* DebugInfo: Do not emit empty CUsDavid Blaikie2017-05-261-0/+12
Consistent with GCC and addresses a shortcoming with ThinLTO where many imported CUs may end up being empty (because the functions imported from them either ended up not being used (and were then discarded, since they're imported as available_externally) or optimized away entirely). Test cases previously testing empty CUs (either intentionally, or because they didn't need anything more complicated) had a trivial 'int' or similar basic type added to their retained types list. This is a first order approximation - a deeper implementation could do things like: 1) Be more lazy about construction of the CU - for example if two CUs containing a single identical retained type are linked together, with this change one of the two CUs will be produced but empty (since a duplicate type won't be produced). 2) Go further and invert all the CU links the same way the subprogram link is inverted - keep named CU lists of retained types, macros, etc, and have those link back to the CU. Then if they're emitted, the CU is emitted, but never otherwise - this would allow the metadata itself to be dropped earlier too, though it seems unlikely that's an important optimization as there shouldn't be many CUs relative to the number of other entities. llvm-svn: 304020
OpenPOWER on IntegriCloud