Skip to content

Commit

Permalink
Add support for MUSL AArch64 TLS (#95)
Browse files Browse the repository at this point in the history
This is the IR part of php/php-src#16902.
  • Loading branch information
nielsdos authored Nov 25, 2024
1 parent f51b8a8 commit ff7ee6c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions ir_aarch64.dasc
Original file line number Diff line number Diff line change
Expand Up @@ -5247,6 +5247,14 @@ static void ir_emit_tls(ir_ctx *ctx, ir_ref def, ir_insn *insn)
| ldr Rx(reg), [Rx(reg), #insn->op2]
| ldr Rx(reg), [Rx(reg), #insn->op3]
|| }
||# elif defined(__MUSL__)
|| if (insn->op3 == IR_NULL) {
| ldr Rx(reg), [Rx(reg), #insn->op2]
|| } else {
| ldr Rx(reg), [Rx(reg), #-8]
| ldr Rx(reg), [Rx(reg), #insn->op2]
| ldr Rx(reg), [Rx(reg), #insn->op3]
|| }
||# else
||//??? IR_ASSERT(insn->op2 <= LDR_STR_PIMM64);
| ldr Rx(reg), [Rx(reg), #insn->op2]
Expand Down

0 comments on commit ff7ee6c

Please sign in to comment.