Mercurial > pub > dyncall > dyncall
diff dyncallback/dyncall_thunk_arm64.c @ 552:61c485f8cc06
cosmetics & c-comments for consistency
author | Tassilo Philipp |
---|---|
date | Mon, 20 Jun 2022 15:11:52 +0200 |
parents | f5577f6bf97a |
children |
line wrap: on
line diff
--- a/dyncallback/dyncall_thunk_arm64.c Mon Jun 20 14:57:49 2022 +0200 +++ b/dyncallback/dyncall_thunk_arm64.c Mon Jun 20 15:11:52 2022 +0200 @@ -32,33 +32,33 @@ Thunk Register: x9 Thunk: - adr x9, Thunk - ldr x10, .target - br x10 - nop + adr x9, Thunk + ldr x10, .target + br x10 + nop .target: - .xword 0 + .xword 0 -- Encoded in: 0000000000000000 <Thunk>: - 0: 10000009 adr x9, 0 <Thunk> - 4: 5800006a ldr x10, 10 <.target> - 8: d61f0140 br x10 - c: d503201f nop + 0: 10000009 adr x9, 0 <Thunk> + 4: 5800006a ldr x10, 10 <.target> + 8: d61f0140 br x10 + c: d503201f nop 0000000000000010 <.target>: - 10: 76543210 .word 0x76543210 - 14: fedcba98 .word 0xfedcba98 + 10: 76543210 .word 0x76543210 + 14: fedcba98 .word 0xfedcba98 */ void dcbInitThunk(DCThunk* p, void (*entry)()) { - p->code[0] = 0x10000009; // adr x9, 0 - p->code[1] = 0x5800006a; // ldr x9, entry - p->code[2] = 0xd61f0140; // br x9 - p->code[3] = 0xd503201f; // nop - p->entry = entry; // entry: - // .xword 0 + p->code[0] = 0x10000009; /* adr x9, 0 */ + p->code[1] = 0x5800006a; /* ldr x9, entry */ + p->code[2] = 0xd61f0140; /* br x9 */ + p->code[3] = 0xd503201f; /* nop */ + p->entry = entry; /* entry: */ + /* .xword 0 */ }