Files
clang-p2996/llvm/test/Bitcode/thinlto-preserve-uselistorder.ll
Matt Arsenault c5ac63e4fc ThinLTO: Add flag to print uselistorder in bitcode writer pass (#133230)
This is needed in llvm-reduce to avoid perturbing the uselistorder in
intermediate steps. Really llvm-reduce wants pure serialization with
no dependency on the pass manager. There are other optimizations mixed
in to the serialization here depending on metadata in the module, which
is also bad.
    
Part of #63621
2025-04-14 20:34:02 +02:00

22 lines
458 B
LLVM

; Check that thin lto bitcode respects preserve-bc-uselistorder
; RUN: opt --preserve-bc-uselistorder --thinlto-bc --thinlto-split-lto-unit < %s | llvm-dis --preserve-ll-uselistorder | FileCheck %s
; CHECK: uselistorder ptr @g, { 3, 2, 1, 0 }
@g = external global i32
define void @func1() {
load i32, ptr @g
load i32, ptr @g
ret void
}
define void @func2() {
load i32, ptr @g
load i32, ptr @g
ret void
}
uselistorder ptr @g, { 3, 2, 1, 0 }