Overview
Comment: | forwardingTargetForSelector: for PowerPC 64/ELF v1 |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
d7797ded66828e791885e3a0f45991e1 |
User & Date: | js on 2024-08-20 21:55:03 |
Other Links: | manifest | tags |
References
2024-08-20
| ||
21:58 | • Fixed ticket [769aec5298]: Write assembly for forwardingTargetForSelector: on PowerPC 64 plus 4 other changes artifact: 1a14c873d1 user: js | |
Context
2024-08-20
| ||
22:09 | Improve compatibility with old glibc check-in: fb069cf2ae user: js tags: trunk | |
21:55 | forwardingTargetForSelector: for PowerPC 64/ELF v1 check-in: d7797ded66 user: js tags: trunk | |
20:44 | Improve compatibility with old evdev headers check-in: 27d64d775a user: js tags: trunk | |
Changes
Name change from src/forwarding/forwarding-powerpc64-elf.S to src/forwarding/forwarding-powerpc64-elf-v2.S.
︙ | ︙ |
Modified src/forwarding/forwarding-powerpc64-elf.S from [3dd02eb036] to [e2c8cdce62].
︙ | ︙ | |||
17 18 19 20 21 22 23 | * <https://www.gnu.org/licenses/>. */ #include "config.h" #include "platform.h" | < < > > > > > > > < < < | | | | | | | | | | | | | | | | | | | | | | > > > | | | | | | | | | | | | | | | | | | | | | > > | | | | > < > | | > > | > | | | | | | | | | | | | | | | | | | | | | | > > > | | | | | | | | | | | | | | | | | | | | | > > | | | | | > > | | > > | | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 | * <https://www.gnu.org/licenses/>. */ #include "config.h" #include "platform.h" .globl OFForward .globl OFForward_stret .section .text .section .opd, "aw", @progbits OFForward: .p2align 3 .quad .Lbegin_OFForward .quad .TOC.@tocbase .quad 0 .previous .Lbegin_OFForward: .cfi_startproc mflr %r0 std %r0, 16(%r1) stdu %r1, -256(%r1) .cfi_def_cfa_offset 256 .cfi_offset lr, 16 std %r2, 40(%r1) /* Save all arguments */ std %r3, 128(%r1) std %r4, 136(%r1) std %r5, 144(%r1) std %r6, 152(%r1) std %r7, 160(%r1) std %r8, 168(%r1) std %r9, 176(%r1) std %r10, 184(%r1) /* Save all floating point arguments */ stfd %f1, 192(%r1) stfd %f2, 200(%r1) stfd %f3, 208(%r1) stfd %f4, 216(%r1) stfd %f5, 224(%r1) stfd %f6, 232(%r1) stfd %f7, 240(%r1) stfd %f8, 248(%r1) bl object_getClass nop addis %r4, %r2, .Lsel_forwardingTargetForSelector_@toc@ha addi %r4, %r4, .Lsel_forwardingTargetForSelector_@toc@l bl class_respondsToSelector nop cmpdi %r3, 0 beq- 0f ld %r3, 128(%r1) addis %r4, %r2, .Lsel_forwardingTargetForSelector_@toc@ha addi %r4, %r4, .Lsel_forwardingTargetForSelector_@toc@l bl objc_msg_lookup nop mr %r12, %r3 ld %r3, 128(%r1) addis %r4, %r2, .Lsel_forwardingTargetForSelector_@toc@ha addi %r4, %r4, .Lsel_forwardingTargetForSelector_@toc@l ld %r5, 136(%r1) ld %r2, 8(%r12) ld %r12, 0(%r12) mtctr %r12 bctrl ld %r2, 40(%r1) cmpdi %r3, 0 beq- 0f ld %r4, 128(%r1) cmpw %r3, %r4 beq- 0f std %r3, 128(%r1) ld %r4, 136(%r1) bl objc_msg_lookup nop mr %r12, %r3 /* Restore all arguments */ ld %r3, 128(%r1) ld %r4, 136(%r1) ld %r5, 144(%r1) ld %r6, 152(%r1) ld %r7, 160(%r1) ld %r8, 168(%r1) ld %r9, 176(%r1) ld %r10, 184(%r1) /* Restore all floating point arguments */ lfd %f1, 192(%r1) lfd %f2, 200(%r1) lfd %f3, 208(%r1) lfd %f4, 216(%r1) lfd %f5, 224(%r1) lfd %f6, 232(%r1) lfd %f7, 240(%r1) lfd %f8, 248(%r1) addi %r1, %r1, 256 ld %r0, 16(%r1) mtlr %r0 ld %r2, 8(%r12) ld %r12, 0(%r12) mtctr %r12 bctr 0: ld %r3, 128(%r1) ld %r4, 136(%r1) bl OFMethodNotFound nop addi %r1, %r1, 256 lwz %r0, 16(%r1) mtlr %r0 blr .cfi_endproc .type OFForward, @function .size OFForward, .-.Lbegin_OFForward .section .opd, "aw", @progbits OFForward_stret: .p2align 3 .quad .Lbegin_OFForward_stret .quad .TOC.@tocbase .quad 0 .previous .Lbegin_OFForward_stret: .cfi_startproc mflr %r0 std %r0, 16(%r1) stdu %r1, -256(%r1) .cfi_def_cfa_offset 256 .cfi_offset lr, 16 std %r2, 40(%r1) /* Save all arguments */ std %r3, 128(%r1) std %r4, 136(%r1) std %r5, 144(%r1) std %r6, 152(%r1) std %r7, 160(%r1) std %r8, 168(%r1) std %r9, 176(%r1) std %r10, 184(%r1) /* Save all floating point arguments */ stfd %f1, 192(%r1) stfd %f2, 200(%r1) stfd %f3, 208(%r1) stfd %f4, 216(%r1) stfd %f5, 224(%r1) stfd %f6, 232(%r1) stfd %f7, 240(%r1) stfd %f8, 248(%r1) mr %r3, %r4 bl object_getClass nop addis %r4, %r2, .Lsel_forwardingTargetForSelector_@toc@ha addi %r4, %r4, .Lsel_forwardingTargetForSelector_@toc@l bl class_respondsToSelector nop cmpdi %r3, 0 beq- 0f ld %r3, 136(%r1) addis %r4, %r2, .Lsel_forwardingTargetForSelector_@toc@ha addi %r4, %r4, .Lsel_forwardingTargetForSelector_@toc@l bl objc_msg_lookup nop mr %r12, %r3 ld %r3, 136(%r1) addis %r4, %r2, .Lsel_forwardingTargetForSelector_@toc@ha addi %r4, %r4, .Lsel_forwardingTargetForSelector_@toc@l ld %r5, 144(%r1) ld %r2, 8(%r12) ld %r12, 0(%r12) mtctr %r12 bctrl ld %r2, 40(%r1) cmpdi %r3, 0 beq- 0f ld %r4, 136(%r1) cmpw %r3, %r4 beq- 0f std %r3, 136(%r1) ld %r4, 144(%r1) bl objc_msg_lookup_stret nop mr %r12, %r3 /* Restore all arguments */ ld %r3, 128(%r1) ld %r4, 136(%r1) ld %r5, 144(%r1) ld %r6, 152(%r1) ld %r7, 160(%r1) ld %r8, 168(%r1) ld %r9, 176(%r1) ld %r10, 184(%r1) /* Restore all floating point arguments */ lfd %f1, 192(%r1) lfd %f2, 200(%r1) lfd %f3, 208(%r1) lfd %f4, 216(%r1) lfd %f5, 224(%r1) lfd %f6, 232(%r1) lfd %f7, 240(%r1) lfd %f8, 248(%r1) addi %r1, %r1, 256 ld %r0, 16(%r1) mtlr %r0 ld %r2, 8(%r12) ld %r12, 0(%r12) mtctr %r12 bctr 0: ld %r3, 128(%r1) ld %r4, 136(%r1) ld %r5, 144(%r1) bl OFMethodNotFound_stret nop addi %r1, %r1, 256 lwz %r0, 16(%r1) mtlr %r0 blr .cfi_endproc .type OFForward_stret, @function .size OFForward_stret, .-.Lbegin_OFForward_stret .section .opd, "aw", @progbits .Linit: .p2align 3 .quad .Lbegin_.Linit .quad .TOC.@tocbase .quad 0 .previous .Lbegin_.Linit: mflr %r0 std %r0, 16(%r1) stdu %r1, -32(%r1) addis %r3, %r2, .Lmodule@toc@ha addi %r3, %r3, .Lmodule@toc@l bl __objc_exec_class |
︙ | ︙ |
Modified src/forwarding/forwarding.S from [e8275219ea] to [4426e69e90].
︙ | ︙ | |||
41 42 43 44 45 46 47 | # include "forwarding-x86-elf.S" # elif defined(OF_ARM64) # include "forwarding-arm64-elf.S" # elif defined(OF_ARM) # include "forwarding-arm-elf.S" # elif defined(OF_POWERPC) # include "forwarding-powerpc-elf.S" | | > > > | > | 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | # include "forwarding-x86-elf.S" # elif defined(OF_ARM64) # include "forwarding-arm64-elf.S" # elif defined(OF_ARM) # include "forwarding-arm-elf.S" # elif defined(OF_POWERPC) # include "forwarding-powerpc-elf.S" # elif defined(OF_POWERPC64) # if defined(_CALL_ELF) && _CALL_ELF == 2 # include "forwarding-powerpc64-elf-v2.S" # else # include "forwarding-powerpc64-elf.S" # endif # elif defined(OF_MIPS64_N64) # include "forwarding-mips64-n64-elf.S" # elif defined(OF_MIPS) # include "forwarding-mips-elf.S" # elif defined(OF_SPARC64) # include "forwarding-sparc64-elf.S" # elif defined(OF_SPARC) |
︙ | ︙ |
Modified src/runtime/lookup-asm/lookup-asm-powerpc64-elf.S from [b56b04edc7] to [0ad675fd51].
︙ | ︙ | |||
40 41 42 43 44 45 46 | #else .section .opd, "aw", @progbits \name: .p2align 3 .quad .Lbegin_\name .quad .TOC.@tocbase .quad 0 | | | 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 | #else .section .opd, "aw", @progbits \name: .p2align 3 .quad .Lbegin_\name .quad .TOC.@tocbase .quad 0 .previous #endif .Lbegin_\name: cmpdi %r3, 0 beq- .LreturnNilMethod andi. %r0, %r3, 1 bne- .LtaggedPointer_\name |
︙ | ︙ | |||
112 113 114 115 116 117 118 | #else .section .opd, "aw", @progbits \name: .p2align 3 .quad .Lbegin_\name .quad .TOC.@tocbase .quad 0 | | | 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 | #else .section .opd, "aw", @progbits \name: .p2align 3 .quad .Lbegin_\name .quad .TOC.@tocbase .quad 0 .previous #endif .Lbegin_\name: mr %r5, %r3 ld %r3, 0(%r3) cmpdi %r3, 0 beq- .LreturnNilMethod |
︙ | ︙ | |||
150 151 152 153 154 155 156 | #else .section .opd, "aw", @progbits .LnilMethod: .p2align 3 .quad .Lbegin_nilMethod .quad .TOC.@tocbase .quad 0 | | | 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 | #else .section .opd, "aw", @progbits .LnilMethod: .p2align 3 .quad .Lbegin_nilMethod .quad .TOC.@tocbase .quad 0 .previous #endif .Lbegin_nilMethod: li %r3, 0 blr .type .LnilMethod, @function .size .LnilMethod, .-.Lbegin_nilMethod #if defined(OF_LINUX) || defined(OF_HAIKU) || defined(OF_HURD) .section .note.GNU-stack, "", @progbits #endif |