[DAGCombiner] Add target hook function to decide folding (mul (add x, c1), c2)
[llvm-project.git] / llvm / test / MC / RISCV / fde-reloc.s
blobd7c3f5c2bb72e6c738c0b39a6fbe3ecfb5077bb3
1 # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+relax < %s \
2 # RUN: | llvm-readobj -r - | FileCheck %s
3 # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=-relax < %s \
4 # RUN: | llvm-readobj -r - | FileCheck %s
6 # Ensure that the eh_frame records the symbolic difference with the paired
7 # relocations always.
9 func:
10 .cfi_startproc
11 ret
12 .cfi_endproc
14 # CHECK: Section (4) .rela.eh_frame {
15 # CHECK-NEXT: 0x1C R_RISCV_32_PCREL - 0x0
16 # CHECK-NEXT: 0x20 R_RISCV_ADD32 - 0x0
17 # CHECK-NEXT: 0x20 R_RISCV_SUB32 - 0x0
18 # CHECK-NEXT: }