@@ -275,13 +275,15 @@ namespace randomx {
275
275
emit (REX_MOV_RR64);
276
276
emitByte (0xd8 + prog.getAddressRegister ());
277
277
emit (codeShhPrefetch, codeSshPrefetchSize);
278
+ #ifdef RANDOMX_ALIGN
278
279
int align = (codePos % 16 );
279
280
while (align != 0 ) {
280
281
int nopSize = 16 - align;
281
282
if (nopSize > 8 ) nopSize = 8 ;
282
283
emit (NOPX[nopSize - 1 ], nopSize);
283
284
align = (codePos % 16 );
284
285
}
286
+ #endif
285
287
}
286
288
}
287
289
emitByte (RET);
@@ -378,25 +380,33 @@ namespace randomx {
378
380
emit (REX_81);
379
381
emitByte (0xc0 + instr.dst );
380
382
emit32 (instr.getImm32 ());
383
+ #ifdef RANDOMX_ALIGN
381
384
emit (NOP1);
385
+ #endif
382
386
break ;
383
387
case randomx::SuperscalarInstructionType::IXOR_C8:
384
388
emit (REX_XOR_RI);
385
389
emitByte (0xf0 + instr.dst );
386
390
emit32 (instr.getImm32 ());
391
+ #ifdef RANDOMX_ALIGN
387
392
emit (NOP1);
393
+ #endif
388
394
break ;
389
395
case randomx::SuperscalarInstructionType::IADD_C9:
390
396
emit (REX_81);
391
397
emitByte (0xc0 + instr.dst );
392
398
emit32 (instr.getImm32 ());
399
+ #ifdef RANDOMX_ALIGN
393
400
emit (NOP2);
401
+ #endif
394
402
break ;
395
403
case randomx::SuperscalarInstructionType::IXOR_C9:
396
404
emit (REX_XOR_RI);
397
405
emitByte (0xf0 + instr.dst );
398
406
emit32 (instr.getImm32 ());
407
+ #ifdef RANDOMX_ALIGN
399
408
emit (NOP2);
409
+ #endif
400
410
break ;
401
411
case randomx::SuperscalarInstructionType::IMULH_R:
402
412
emit (REX_MOV_RR64);
@@ -853,6 +863,7 @@ namespace randomx {
853
863
emitByte (0xc1 );
854
864
emit (REX_ADD_RM);
855
865
emitByte (0xc1 + 8 * instr.dst );
866
+
856
867
}
857
868
858
869
void JitCompilerX86::h_ISTORE (Instruction& instr, int i) {
0 commit comments