1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 20:23:11 +01:00
llvm-mirror/test/DebugInfo
Mikael Holmen 2e96ed2e60 [SROA] Really remove associated dbg.declare when removing dead alloca
Summary:
There already was code that tried to remove the dbg.declare, but that code
was placed after we had called
 I->replaceAllUsesWith(UndefValue::get(I->getType()));
on the alloca, so when we searched for the relevant dbg.declare, we
couldn't find it.

Now we do the search before we call RAUW so there is a chance to find it.

An existing testcase needed update due to this. Two dbg.declare with undef
were removed and then suddenly one of the two CHECKS failed.

Before this patch we got

  call void @llvm.dbg.declare(metadata i24* undef, metadata !14, metadata !DIExpression(DW_OP_LLVM_fragment, 32, 24)), !dbg !15
  call void @llvm.dbg.declare(metadata %struct.prog_src_register* undef, metadata !14, metadata !DIExpression()), !dbg !15
  call void @llvm.dbg.value(metadata i32 0, metadata !14, metadata !DIExpression(DW_OP_LLVM_fragment, 0, 32)), !dbg !15
  call void @llvm.dbg.value(metadata i32 0, metadata !14, metadata !DIExpression(DW_OP_LLVM_fragment, 32, 24)), !dbg !15

and with it we get

  call void @llvm.dbg.value(metadata i32 0, metadata !14, metadata !DIExpression(DW_OP_LLVM_fragment, 0, 32)), !dbg !15
  call void @llvm.dbg.value(metadata i32 0, metadata !14, metadata !DIExpression(DW_OP_LLVM_fragment, 32, 24)), !dbg !15

However, the CHECKs in the testcase checked things in a silly order, so
they only passed since they found things in the first dbg.declare. Now
we changed the order of the checks and the test passes.

Reviewers: rnk

Reviewed By: rnk

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D37900

llvm-svn: 313875
2017-09-21 11:14:27 +00:00
..
AArch64 llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
AMDGPU llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
ARM llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
COFF Re-land "Fix Bug 30978 by emitting cv file checksums." 2017-09-19 18:14:45 +00:00
Generic DebugInfo: Remove unneeded attributes from test/DebugInfo/Generic/imported-name-inlined.ll 2017-09-20 15:59:57 +00:00
Inputs Update testcase that was XFAILed on Darwin for llvm-dwarfdump change. 2017-09-13 22:30:43 +00:00
Lanai
Mips llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
MIR llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
MSP430 Parse and print DIExpressions inline to ease IR and MIR testing 2017-08-23 20:31:27 +00:00
PDB [llvm-pdbutil] Print detailed S_UDT stats. 2017-08-31 20:43:22 +00:00
PowerPC Canonicalize the representation of empty an expression in DIGlobalVariableExpression 2017-08-30 18:06:51 +00:00
Sparc llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
SystemZ llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
WebAssembly [WebAssembly] Update debug info test after r312144 2017-08-30 19:54:08 +00:00
X86 [SROA] Really remove associated dbg.declare when removing dead alloca 2017-09-21 11:14:27 +00:00
arm-relocs.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
debuglineinfo-macho.test
debuglineinfo.test
debugmacinfo.test llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
dwarfdump-64-bit-dwarf.test llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
dwarfdump-accel.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-debug-frame-simple.test [dwarfdump] Make .eh_frame an alias for .debug_frame 2017-09-18 14:15:57 +00:00
dwarfdump-decompression-corrupt.test [Object] Verify object sizes before handing out StringRefs pointing out 2017-08-31 12:27:10 +00:00
dwarfdump-decompression-error.test [llvm-dwarfdump] - Print an error message if section decompression failed. 2017-05-05 10:52:39 +00:00
dwarfdump-dump-flags.test llvm-dwarfdump: automatically dump both regular and .dwo variant of sections 2017-09-13 22:09:01 +00:00
dwarfdump-dump-gdbindex.test llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
dwarfdump-dwp.test llvm-dwarfdump: automatically dump both regular and .dwo variant of sections 2017-09-13 22:09:01 +00:00
dwarfdump-header.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-implicit-const.test llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
dwarfdump-invalid.test
dwarfdump-line-dwo.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-macho-relocs.test llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
dwarfdump-macho-universal.test Adapt more testcases for llvm-dwarfdump changes. 2017-09-14 17:27:03 +00:00
dwarfdump-objc.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-pubnames.test llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
dwarfdump-ranges.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-str-offsets-dwp.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-str-offsets-invalid.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-str-offsets.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-type-units.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwarfdump-zlib.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
dwo.ll llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
invalid-relocations.test [DWARF] - Add testcase for checking message about broken relocations. 2017-07-11 12:29:07 +00:00
llvm-symbolizer-split-dwarf-empty.test [llvm] Get rid of "%T" expansions 2017-08-15 20:29:24 +00:00
llvm-symbolizer-zlib.test
llvm-symbolizer.test Migrate llvm-symbolizer tests to not use %T 2017-09-08 21:10:01 +00:00
macro_link.ll
member-pointers.o
missing-abstract-variable.o
omit-empty.ll DebugInfo: Consider a CU containing only local imported entities to be 'empty' 2017-07-28 03:06:25 +00:00
pr34186.ll Canonicalize the representation of empty an expression in DIGlobalVariableExpression 2017-08-30 18:06:51 +00:00
skeletoncu.ll llvm-dwarfdump: Replace -debug-dump=sect option with individual options. 2017-09-11 22:59:45 +00:00
strip-DIGlobalVariable.ll
strip-loop-metadata.ll
typeunit-header.test llvm-dwarfdump: Make -brief the default and add a -verbose option instead. 2017-09-11 23:05:20 +00:00
unrolled-loop-remainder.ll [LoopUnroll][DebugInfo] Don't add metadata to unrolled remainder loop 2017-09-04 08:12:16 +00:00