xref: /llvm-project/llvm/test/MC/RISCV/twice.ll (revision e45087fd53d5946f47efa7bb7be088c668c386a1)
1; Check for state persistence bugs in the RISC-V MC backend
2; This should neither fail (in the comparison that the second object
3; is bit-identical to the first) nor crash. Either failure would most
4; likely indicate some state that is not properly reset in the
5; appropriate ::reset method.
6; RUN: llc -compile-twice -filetype=obj -mtriple=riscv64 %s -o - \
7; RUN:     | llvm-objdump --section-headers - \
8; RUN:     | FileCheck %s
9
10; CHECK:      Sections:
11; CHECK-NEXT: Idx Name              Size     VMA              Type
12; CHECK-NEXT:  0
13; CHECK-NEXT:  1 .strtab
14; CHECK-NEXT:  2 .text
15; CHECK-NEXT:  3 .note.GNU-stack
16; CHECK-NEXT:  4 .riscv.attributes
17; CHECK-NEXT:  5 .symtab
18