diff options
Diffstat (limited to '')
-rw-r--r-- | src/lj_asm_arm64.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/lj_asm_arm64.h b/src/lj_asm_arm64.h index 5bd4e0d5..dde52347 100644 --- a/src/lj_asm_arm64.h +++ b/src/lj_asm_arm64.h | |||
@@ -522,6 +522,21 @@ static void asm_retf(ASMState *as, IRIns *ir) | |||
522 | emit_lso(as, A64I_LDRx, RID_TMP, base, -8); | 522 | emit_lso(as, A64I_LDRx, RID_TMP, base, -8); |
523 | } | 523 | } |
524 | 524 | ||
525 | /* -- Buffer operations --------------------------------------------------- */ | ||
526 | |||
527 | #if LJ_HASBUFFER | ||
528 | static void asm_bufhdr_write(ASMState *as, Reg sb) | ||
529 | { | ||
530 | Reg tmp = ra_scratch(as, rset_exclude(RSET_GPR, sb)); | ||
531 | IRIns irgc; | ||
532 | irgc.ot = IRT(0, IRT_PGC); /* GC type. */ | ||
533 | emit_storeofs(as, &irgc, RID_TMP, sb, offsetof(SBuf, L)); | ||
534 | emit_dn(as, A64I_BFMx | A64F_IMMS(lj_fls(SBUF_MASK_FLAG)) | A64F_IMMR(0), RID_TMP, tmp); | ||
535 | emit_getgl(as, RID_TMP, cur_L); | ||
536 | emit_loadofs(as, &irgc, tmp, sb, offsetof(SBuf, L)); | ||
537 | } | ||
538 | #endif | ||
539 | |||
525 | /* -- Type conversions ---------------------------------------------------- */ | 540 | /* -- Type conversions ---------------------------------------------------- */ |
526 | 541 | ||
527 | static void asm_tointg(ASMState *as, IRIns *ir, Reg left) | 542 | static void asm_tointg(ASMState *as, IRIns *ir, Reg left) |