35 lines · plain
1; RUN: llvm-dis < %s.bc | FileCheck %s2; RUN: verify-uselistorder < %s.bc3 4; aggregateOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.5; The test checks that LLVM does not misread instructions with aggregate operands6; in older bitcode files.7 8define void @extractvalue([4 x i8] %x1, [4 x [4 x i8]] %x2, {{i32, float}} %x3){9entry:10; CHECK: %res1 = extractvalue [4 x i8] %x1, 011 %res1 = extractvalue [4 x i8] %x1, 012 13; CHECK-NEXT: %res2 = extractvalue [4 x [4 x i8]] %x2, 114 %res2 = extractvalue [4 x [4 x i8 ]] %x2, 115 16; CHECK-NEXT: %res3 = extractvalue [4 x [4 x i8]] %x2, 0, 117 %res3 = extractvalue [4 x [4 x i8 ]] %x2, 0, 118 19; CHECK-NEXT: %res4 = extractvalue { { i32, float } } %x3, 0, 120 %res4 = extractvalue {{i32, float}} %x3, 0, 121 22 ret void23}24 25define void @insertvalue([4 x [4 x i8 ]] %x1){26entry:27; CHECK: %res1 = insertvalue [4 x [4 x i8]] %x1, i8 0, 0, 028 %res1 = insertvalue [4 x [4 x i8 ]] %x1, i8 0, 0, 029 30; CHECK-NEXT: %res2 = insertvalue [4 x [4 x i8]] undef, i8 0, 0, 031 %res2 = insertvalue [4 x [4 x i8 ]] undef, i8 0, 0, 032 33 ret void34}35