Browse Source

[Jit] Fix F32 NaN detection with x != x (#750)

Yuxiao Mao 7 months ago
parent
commit
0c5d35fdba
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/jit.c

+ 1 - 1
src/jit.c

@@ -1879,7 +1879,7 @@ static preg *op_binop( jit_ctx *ctx, vreg *dst, vreg *a, vreg *b, hl_op bop ) {
 		switch( ID2(pa->kind, pb->kind) ) {
 		case ID2(RFPU,RFPU):
 			op64(ctx,o,pa,pb);
-			if( o == COMISD && bop != OJSGt ) {
+			if( (o == COMISD || o == COMISS) && bop != OJSGt ) {
 				int jnotnan;
 				XJump_small(JNParity,jnotnan);
 				switch( bop ) {