[llvm] [BOLT][DWARF] Fix unit layout with forward DW_FORM_ref_udata references (PR #226076)

Alexander Yermolovich via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 28 09:51:55 PDT 2026


================
@@ -2,16 +2,40 @@
 
 # RUN: llvm-mc -dwarf-version=5 -filetype=obj -triple x86_64-unknown-linux %s -o %t.o
 # RUN: %clang %cflags -dwarf-5 %t.o -o %t.exe -Wl,-q
+# RUN: llvm-dwarfdump --show-form --verbose --debug-info %t.exe | \
+# RUN:   FileCheck %s --check-prefix CHECK-INPUT
 # RUN: llvm-bolt %t.exe -o %t.bolt --update-debug-sections 2>&1 | \
 # RUN:   FileCheck %s --check-prefix CHECK-BOLT
-# RUN: llvm-dwarfdump --show-form --verbose --debug-info %t.bolt | FileCheck %s
+# RUN: llvm-dwarfdump --show-form --verbose --debug-info %t.bolt 2>&1 | \
+# RUN:   FileCheck %s --implicit-check-not=warning:
+# RUN: llvm-dwarfdump --verify %t.bolt | FileCheck %s --check-prefix CHECK-VERIFY
 
-## Verify BOLT preserves DW_FORM_ref_udata (CU-relative ULEB128 DIE reference),
-## a form GCC may emit instead of DW_FORM_ref4.
+## Verify BOLT handles DW_FORM_ref_udata (CU-relative ULEB128 DIE reference),
----------------
ayermolo wrote:

Can you tighten the comment please. LLMs are to verbose. :)

https://github.com/llvm/llvm-project/pull/226076


More information about the llvm-commits mailing list