VirtualBox

source: vbox/trunk/src/VBox/Runtime/testcase/tstRTLdrMachORelocs-1.S@ 79325

Last change on this file since 79325 was 74845, checked in by vboxsync, 6 years ago

tstRTLdrMachORelocs-1.S: update

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.2 KB
Line 
1/*
2 * as -arch x86_64 -mmacosx-version-min=10.7-o tstRTLdrMachORelocs-1-as.o tstRTLdrMachORelocs-1.S
3 * ld -arch x86_64 -r -o tstRTLdrMachORelocs-1.o tstRTLdrMachORelocs-1-as.o
4 * tstLdr-3 0x2000 tstRTLdrMachORelocs-1.o 0x2000 > tmp.disas
5 * diff tmp.disas tstRTLdrMachORelocs-1.disas
6 */
7 .section __TEXT,__text,regular,pure_instructions
8 .globl _myfunc6
9 .align 4, 0x90
10_myfunc6:
11Leh_func_begin6:
12 .byte 0x90
13 .byte 0x48, 0xb8 /* movabsq */
14 .quad Lg_LocalData
15 movb Lg_LocalData(%rip), %al
16 cmpb $0x7f, Lg_LocalData(%rip)
17 cmpw $0x117f, Lg_LocalData(%rip)
18 cmpl $0x9988117f, Lg_LocalData(%rip)
19 jmp Lg_LocalData
20
21 .byte 0x90
22 .byte 0x48, 0xb8 /* movabsq */
23 .quad Leh_func_end6
24 movb Leh_func_end6(%rip), %al
25 cmpb $0x7e, Leh_func_end6(%rip)
26 cmpw $0x117e, Leh_func_end6(%rip)
27 cmpl $0x9988117e, Leh_func_end6(%rip)
28 jmp Leh_func_end6
29
30 .byte 0x90
31 .byte 0x48, 0xb8 /* movabsq */
32 .quad _g_Data.3-3
33 movb _g_Data.3-3(%rip), %al
34 cmpb $4, _g_Data.3-3(%rip)
35 jmp _g_Data.3-3
36
37 .byte 0x90
38 .byte 0x48, 0xb8 /* movabsq */
39 .quad _g_Data.3
40 movb _g_Data.3(%rip), %al
41 cmpb $5, _g_Data.3(%rip)
42 cmpw $1105, _g_Data.3(%rip)
43 cmpl $99881105, _g_Data.3(%rip)
44 jmp _g_Data.3
45
46 .byte 0x90
47 .byte 0x48, 0xb8 /* movabsq */
48 .quad abssym
49 movb abssym(%rip), %al
50 cmpb $6, abssym(%rip)
51 cmpw $1106, abssym(%rip)
52 cmpl $99881106, abssym(%rip)
53 jmp abssym
54
55 .byte 0x90
56 cmpb $1, _g_Data.4.1(%rip)
57 cmpb $2, _g_Data.4.2(%rip)
58 cmpb $3, _g_Data.4.3(%rip)
59
60 /* X86_64_RELOC_SUBTRACTOR */
61 .byte 0x90
62 .byte 0x48, 0xb8 /* movabsq */
63 .quad Leh_func_end6 - _g_Data.0
64 .byte 0x48, 0xb8 /* movabsq */
65 .quad Leh_func_end6 - _g_Data.0 + 0x80 /* buggy assembler here? (clang-900.0.39.2) */
66 .byte 0x48, 0xb8 /* movabsq */
67 .quad _myfunc6_end - _g_Data.0
68 .byte 0x48, 0xb8 /* movabsq */
69 .quad _myfunc6_end - _g_Data.0 + 0x80
70 .align 4, 0xcc
71_myfunc6_end:
72
73 .section __TEXT,__othertext,regular,pure_instructions
74 .align 3, 0xcc
75Leh_func_end6:
76 .byte 0x90
77 .byte 0x90
78 .byte 0xcc
79 .byte 0xcc
80 .byte 0x90
81 .byte 0x90
82 .byte 0xcc
83 .byte 0xcc
84
85 .section __DATA,__data //,regular,pure_instructions
86 .align 3, 0xcc
87_g_Data.0:
88 .byte 0x90
89_g_Data.1:
90 .byte 0xcc
91_g_Data.2:
92 .byte 0x90
93_g_Data.3:
94 .byte 0xcc
95_g_Data.4.0:
96 .byte 0x90
97_g_Data.4.1:
98 .byte 0xcc
99_g_Data.4.2:
100 .byte 0x90
101_g_Data.4.3:
102 .byte 0xcc
103_g_EndOfData:
104
105 .section __GROG,__foobar,regular,pure_instructions
106 .align 3, 0xcc
107 .byte 0x90
108Lg_LocalDataMinus3:
109 .byte 0x90
110Lg_LocalDataMinus2:
111 .byte 0x90
112Lg_LocalDataMinus1:
113 .byte 0x90
114Lg_LocalData:
115 .byte 0xcc
116 .byte 0xcc
117 .byte 0xcc
118 .byte 0xcc
119 .byte 0xcc
120 .byte 0xcc
121
122.set abssym, 0x123456
123.globl abssym
124
125.subsections_via_symbols
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette