diff options
Diffstat (limited to 'tests/examplefiles')
| -rw-r--r-- | tests/examplefiles/llvm-mir.mir | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/tests/examplefiles/llvm-mir.mir b/tests/examplefiles/llvm-mir.mir new file mode 100644 index 00000000..561296c2 --- /dev/null +++ b/tests/examplefiles/llvm-mir.mir @@ -0,0 +1,32 @@ +# YAML line comment + +--- | + ; LLVM-IR line comment + define void @myfunction() { ret void } +... + +--- +name: myfunction +legalized: true +registers: + - { id: 0, class: gpr } +body: | + bb.0.named (address-taken): + liveins: $r0, $r1 + successors: %bb.1.alsonamed + + ; MIR line comment + %0:gpr(s64) = COPY $r0 + %1(s32) = COPY $r1 + bb.1.alsonamed: + successors: %bb.2 + + %2(s32) = EXTRACT_SUBREG %1(s32), %subreg.sub0 + %3(s32) = G_ADD %0:gpr(s32), %2(s32) killed + %4(s32) = G_CONSTANT i32 1 + %5(s32) = G_FCONSTANT float 1.0 + %6(p0) = G_LOAD %6(p0) :: (load 4 from %ir.myvar + 4) + + bb.2: + $r0 = COPY %3 +... |
