15
15
blr
16
16
L..rust_psm_stack_direction_end:
17
17
# Following bytes form the traceback table on AIX.
18
- # See https://www.ibm.com/docs/en/aix/7.2?topic=processor-traceback-tables for more information.
19
- .vbyte 4 , 0x00000000
20
- .byte 0x00
21
- .byte 0x09
22
- .byte 0x20
23
- .byte 0x40
24
- .byte 0x80
25
- .byte 0x00
26
- .byte 0x00
27
- .byte 0x01
28
- .vbyte 4 , L..rust_psm_stack_direction_end-.rust_psm_stack_direction
29
- .vbyte 2 , 0x0018
30
- .byte "rust_psm_stack_direction"
18
+ # For specification, see https://www.ibm.com/docs/en/aix/7.2?topic=processor-traceback-tables.
19
+ # For implementation, see https://github.com/llvm/llvm-project/blob/main/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp,
20
+ # `PPCAIXAsmPrinter::emitTracebackTable`.
21
+ .vbyte 4 , 0x00000000 # Traceback table begin, for unwinder to search the table.
22
+ .byte 0x00 # Version = 0
23
+ .byte 0x09 # Language = CPlusPlus, since rust is using C++-like LSDA.
24
+ .byte 0x20 # -IsGlobaLinkage, -IsOutOfLineEpilogOrPrologue
25
+ # +HasTraceBackTableOffset, -IsInternalProcedure
26
+ # -HasControlledStorage, -IsTOCless
27
+ # -IsFloatingPointPresent
28
+ # -IsFloatingPointOperationLogOrAbortEnabled
29
+ .byte 0x40 # -IsInterruptHandler, +IsFunctionNamePresent, -IsAllocaUsed
30
+ # OnConditionDirective = 0, -IsCRSaved, -IsLRSaved
31
+ .byte 0x80 # +IsBackChainStored, -IsFixup, NumOfFPRsSaved = 0
32
+ .byte 0x00 # -HasExtensionTable, -HasVectorInfo, NumOfGPRsSaved = 0
33
+ .byte 0x00 # NumberOfFixedParms = 0
34
+ .byte 0x01 # NumberOfFPParms = 0, +HasParmsOnStack
35
+ .vbyte 4 , L..rust_psm_stack_direction_end-.rust_psm_stack_direction #Function size
36
+ .vbyte 2 , 0x0018 # Function name len = 24
37
+ .byte "rust_psm_stack_direction" # Function Name
31
38
32
39
.globl rust_psm_stack_pointer[DS ]
33
40
.globl .rust_psm_stack_pointer
@@ -79,9 +86,9 @@ L..rust_psm_replace_stack_end:
79
86
.byte 0x40
80
87
.byte 0x80
81
88
.byte 0x00
82
- .byte 0x02
89
+ .byte 0x03
83
90
.byte 0x01
84
- .vbyte 4 , 0x00000000
91
+ .vbyte 4 , 0x00000000 # Parameter type = i, i, i
85
92
.vbyte 4 , L..rust_psm_replace_stack_end-.rust_psm_replace_stack
86
93
.vbyte 2 , 0x0016
87
94
.byte "rust_psm_replace_stack"
@@ -95,7 +102,7 @@ L..rust_psm_replace_stack_end:
95
102
.vbyte 8 , 0
96
103
.csect .text [PR],2
97
104
.rust_psm_on_stack:
98
- # extern "C" fn(3: usize, 4: extern "C" fn(usize), 5 : *mut u8)
105
+ # extern "C" fn(3: usize, 4: usize, 5: extern "C" fn(usize, usize ), 6 : *mut u8)
99
106
mflr 0
100
107
std 2 , -72 (6 )
101
108
std 0 , -8 (6 )
@@ -116,11 +123,12 @@ L..rust_psm_on_stack_end:
116
123
.byte 0x00
117
124
.byte 0x09
118
125
.byte 0x20
119
- .byte 0x40
126
+ .byte 0x41
120
127
.byte 0x80
121
128
.byte 0x00
122
- .byte 0x00
129
+ .byte 0x04
123
130
.byte 0x01
131
+ .vbyte 4 , 0x00000000 # Parameter type = i, i, i, i
124
132
.vbyte 4 , L..rust_psm_on_stack_end-.rust_psm_on_stack
125
133
.vbyte 2 , 0x0011
126
134
.byte "rust_psm_on_stack"
0 commit comments