1
0
mirror of https://github.com/c64scene-ar/llvm-6502.git synced 2025-04-14 06:37:33 +00:00

Add a test for explicitly exercising the mc-relax-all flag.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169764 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eli Bendersky 2012-12-10 20:36:01 +00:00
parent f43e3fdb4f
commit e1dee8a06e

@ -0,0 +1,19 @@
// By default, the jmp here does not need relaxation (so the 0xeb opdoce can be
// used).
// However, with -mc-relax-all passed to MC, all jumps are relaxed and we
// expect to see a different instruction.
// RUN: llvm-mc -filetype=obj -mc-relax-all -triple x86_64-pc-linux-gnu %s -o - \
// RUN: | llvm-objdump -disassemble - | FileCheck -check-prefix=RELAXALL %s
// RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - \
// RUN: | llvm-objdump -disassemble - | FileCheck %s
.text
foo:
mov %rax, %rax
jmp foo
// RELAXALL: 3: e9
// CHECK: 3: eb