[PATCH] D118080: [BOLT][TEST] Opt back in to the DWARFv4

Amir Ayupov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 24 15:11:04 PST 2022


Amir updated this revision to Diff 402685.
Amir added a comment.

Fixed failing tests


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D118080/new/

https://reviews.llvm.org/D118080

Files:
  bolt/test/X86/asm-func-debug.test
  bolt/test/X86/inlined-function-mixed.test
  bolt/test/keep-aranges.test
  bolt/test/lit.cfg.py
  bolt/test/non-empty-debug-line.test


Index: bolt/test/non-empty-debug-line.test
===================================================================
--- bolt/test/non-empty-debug-line.test
+++ bolt/test/non-empty-debug-line.test
@@ -3,7 +3,7 @@
 
 REQUIRES: system-linux
 
-RUN: %clang %S/Inputs/hello.c -g -o %t
+RUN: %clang %cflags %S/Inputs/hello.c -g -o %t
 RUN: llvm-bolt %t -o %t1 -update-debug-sections -funcs=_start
 RUN: llvm-readobj -S %t > %t2
 RUN: llvm-readobj -S %t1 >> %t2
Index: bolt/test/lit.cfg.py
===================================================================
--- bolt/test/lit.cfg.py
+++ bolt/test/lit.cfg.py
@@ -60,8 +60,8 @@
 llvm_config.use_clang()
 llvm_config.use_llvm_tool('lld', required=True, search_env='LLD')
 
-config.substitutions.append(('%cflags', '-no-pie'))
-config.substitutions.append(('%cxxflags', '-no-pie'))
+config.substitutions.append(('%cflags', '-no-pie -gdwarf-4'))
+config.substitutions.append(('%cxxflags', '-no-pie -gdwarf-4'))
 
 link_fdata_cmd = os.path.join(config.test_source_root, 'link_fdata.py')
 
Index: bolt/test/keep-aranges.test
===================================================================
--- bolt/test/keep-aranges.test
+++ bolt/test/keep-aranges.test
@@ -3,8 +3,8 @@
 
 REQUIRES: system-linux
 
-RUN: %clang %S/Inputs/icf_baz.c %S/Inputs/icf_main.c -Wl,--icf=all,--gdb-index \
-RUN:   -g -o %t.exe -fuse-ld=lld
+RUN: %clang %cflags %S/Inputs/icf_baz.c %S/Inputs/icf_main.c \
+RUN:   -Wl,--icf=all,--gdb-index -g -o %t.exe -fuse-ld=lld
 RUN: llvm-bolt %t.exe -o %t -update-debug-sections -keep-aranges
 RUN: llvm-dwarfdump -debug-aranges %t | FileCheck %s
 
Index: bolt/test/X86/inlined-function-mixed.test
===================================================================
--- bolt/test/X86/inlined-function-mixed.test
+++ bolt/test/X86/inlined-function-mixed.test
@@ -1,9 +1,9 @@
 # Make sure inlining from a unit with debug info into unit without
 # debug info does not cause a crash.
 
-RUN: %clangxx %S/Inputs/inlined.cpp -c -o %T/inlined.o
-RUN: %clangxx %S/Inputs/inlinee.cpp -c -o %T/inlinee.o -g
-RUN: %clangxx %T/inlined.o %T/inlinee.o -o %t
+RUN: %clangxx %cxxflags %S/Inputs/inlined.cpp -c -o %T/inlined.o
+RUN: %clangxx %cxxflags %S/Inputs/inlinee.cpp -c -o %T/inlinee.o -g
+RUN: %clangxx %cxxflags %T/inlined.o %T/inlinee.o -o %t
 
 RUN: llvm-bolt %t -o %t.bolt -update-debug-sections -reorder-blocks=reverse \
 RUN:   -inline-small-functions -force-inline=main | FileCheck %s
Index: bolt/test/X86/asm-func-debug.test
===================================================================
--- bolt/test/X86/asm-func-debug.test
+++ bolt/test/X86/asm-func-debug.test
@@ -3,7 +3,7 @@
 #
 # The input test case foo() contains nops that we remove.
 
-RUN: %clang -g %p/../Inputs/asm_foo.s %p/../Inputs/asm_main.c -o %t.exe
+RUN: %clang %cflags -g %p/../Inputs/asm_foo.s %p/../Inputs/asm_main.c -o %t.exe
 RUN: llvm-bolt %t.exe -o %t -update-debug-sections
 RUN: llvm-dwarfdump -all %t | FileCheck %s
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D118080.402685.patch
Type: text/x-patch
Size: 2945 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220124/fcf90708/attachment.bin>


More information about the llvm-commits mailing list