Add volatile XLOADs.
This commit is contained in:
@@ -206,7 +206,8 @@ IRFLDEF(FLENUM)
|
||||
|
||||
/* XLOAD mode, stored in op2. */
|
||||
#define IRXLOAD_READONLY 1 /* Load from read-only data. */
|
||||
#define IRXLOAD_UNALIGNED 2 /* Unaligned load. */
|
||||
#define IRXLOAD_VOLATILE 2 /* Load from volatile data. */
|
||||
#define IRXLOAD_UNALIGNED 4 /* Unaligned load. */
|
||||
|
||||
/* CONV mode, stored in op2. */
|
||||
#define IRCONV_SRCMASK 0x001f /* Source IRType. */
|
||||
|
||||
@@ -669,6 +669,8 @@ TRef LJ_FASTCALL lj_opt_fwd_xload(jit_State *J)
|
||||
|
||||
if ((fins->op2 & IRXLOAD_READONLY))
|
||||
goto cselim;
|
||||
if ((fins->op2 & IRXLOAD_VOLATILE))
|
||||
goto doemit;
|
||||
|
||||
/* Search for conflicting stores. */
|
||||
ref = J->chain[IR_XSTORE];
|
||||
@@ -721,7 +723,8 @@ cselim:
|
||||
xr = IR(xref);
|
||||
goto retry; /* Retry with the reassociated reference. */
|
||||
}
|
||||
return lj_ir_emit(J);
|
||||
doemit:
|
||||
return EMITFOLD;
|
||||
}
|
||||
|
||||
/* XSTORE elimination. */
|
||||
|
||||
Reference in New Issue
Block a user