Fixed some bugs.
[llvm/zpu.git] / test / MC / COFF / simple-fixups.s
blobf86f4a9ff9e425e2fae86102bb9ebc15fdbb78be
1 // The purpose of this test is to verify that we do not produce unneeded
2 // relocations when symbols are in the same section and we know their offset.
4 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | coff-dump.py | FileCheck %s
5 // I WOULD RUN, BUT THIS FAILS: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | coff-dump.py | FileCheck %s
7 .def _foo;
8 .scl 2;
9 .type 32;
10 .endef
11 .text
12 .globl _foo
13 .align 16, 0x90
14 _foo: # @foo
15 # BB#0: # %e
16 .align 16, 0x90
17 LBB0_1: # %i
18 # =>This Inner Loop Header: Depth=1
19 jmp LBB0_1
21 .def _bar;
22 .scl 2;
23 .type 32;
24 .endef
25 .globl _bar
26 .align 16, 0x90
27 _bar: # @bar
28 # BB#0: # %e
29 .align 16, 0x90
30 LBB1_1: # %i
31 # =>This Inner Loop Header: Depth=1
32 jmp LBB1_1
34 .def _baz;
35 .scl 2;
36 .type 32;
37 .endef
38 .globl _baz
39 .align 16, 0x90
40 _baz: # @baz
41 # BB#0: # %e
42 subl $4, %esp
43 Ltmp0:
44 calll _baz
45 addl $4, %esp
46 ret
48 // CHECK: Sections = [
49 // CHECK-NOT: NumberOfRelocations = {{[^0]}}
50 // CHECK: Symbols = [