Differences From Artifact [a6501f118e]:
- File
src/forwarding/apple-forwarding-arm64.S
— part of check-in
[07d8ae8c34]
at
2014-01-14 00:56:13
on branch trunk
— apple-forwarding-arm64.S: Fix two bugs.
The offset for the stored x0 was wrong so that comparing the result of
the call to -[forwardingTargetForSelector:] with self did not work. The
other bug was that x19 was not restored before jumping to
of_method_not_found. (user: js, size: 2153) [annotate] [blame] [check-ins using]
To Artifact [d1e540726b]:
- File src/forwarding/apple-forwarding-arm64.S — part of check-in [271bfb18b3] at 2014-01-15 19:04:43 on branch trunk — forwarding: Clean up local labels. (user: js, size: 2134) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
14 15 16 17 18 19 20 | * file. */ .globl _of_forward .globl _of_forward_stret .section __TEXT, __objc_methname, cstring_literals | | | | | 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | * file. */ .globl _of_forward .globl _of_forward_stret .section __TEXT, __objc_methname, cstring_literals str_forwardingTargetForSelector_: .asciz "forwardingTargetForSelector:" .section __DATA, __objc_selrefs, literal_pointers, no_dead_strip sel_forwardingTargetForSelector_: .quad str_forwardingTargetForSelector_ .section __DATA, __objc_imageinfo, regular, no_dead_strip .long 0, 0 .section __TEXT, __text, regular, pure_instructions _of_forward: _of_forward_stret: |
︙ | ︙ | |||
46 47 48 49 50 51 52 | stp q0, q1, [sp, #80] stp q2, q3, [sp, #112] stp q4, q5, [sp, #144] stp q6, q7, [sp, #176] bl _object_getClass | | | | | | < > | 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 | stp q0, q1, [sp, #80] stp q2, q3, [sp, #112] stp q4, q5, [sp, #144] stp q6, q7, [sp, #176] bl _object_getClass adrp x19, sel_forwardingTargetForSelector_@PAGE add x19, x19, sel_forwardingTargetForSelector_@PAGEOFF ldr x19, [x19] mov x1, x19 bl _class_respondsToSelector cbz x0, 0f ldp x0, x2, [sp] mov x1, x19 bl _objc_msgSend cbz x0, 0f ldr x1, [sp] cmp x0, x1 b.eq 0f /* Restore all arguments, x8 and x19, but not x0 */ ldr x1, [sp, #8] ldp x2, x3, [sp, #16] ldp x4, x5, [sp, #32] ldp x6, x7, [sp, #48] ldp x8, x19, [sp, #64] /* Restore all foating point arguments */ ldp q0, q1, [sp, #80] ldp q2, q3, [sp, #112] ldp q4, q5, [sp, #144] ldp q6, q7, [sp, #176] mov sp, fp ldp fp, lr, [sp], #208 b _objc_msgSend 0: ldp x0, x1, [sp] ldr x19, [sp, #72] mov sp, fp ldp fp, lr, [sp], #208 b _of_method_not_found |