]> git.eshelyaron.com Git - emacs.git/commitdiff
* src/comp.c (emit_FIXNUMP): Don't emit a shift when unnecessary.
authorAndrea Corallo <akrl@sdf.org>
Mon, 6 Apr 2020 18:04:43 +0000 (19:04 +0100)
committerAndrea Corallo <akrl@sdf.org>
Mon, 6 Apr 2020 18:04:43 +0000 (19:04 +0100)
src/comp.c

index 0a803545e59ac231948d387beb619947da90de3f..32fc7f23c4e610c2cf4539a0c617d0d66f919270 100644 (file)
@@ -936,13 +936,14 @@ emit_FIXNUMP (gcc_jit_rvalue *obj)
   emit_comment ("FIXNUMP");
 
   gcc_jit_rvalue *sh_res =
-    emit_binary_op (
-      GCC_JIT_BINARY_OP_RSHIFT,
-      comp.emacs_int_type,
-      emit_XLI (obj),
-      gcc_jit_context_new_rvalue_from_int (comp.ctxt,
-                                          comp.emacs_int_type,
-                                          (USE_LSB_TAG ? 0 : FIXNUM_BITS)));
+    USE_LSB_TAG ? obj
+    : emit_binary_op (GCC_JIT_BINARY_OP_RSHIFT,
+                     comp.emacs_int_type,
+                     emit_XLI (obj),
+                     gcc_jit_context_new_rvalue_from_int (
+                       comp.ctxt,
+                       comp.emacs_int_type,
+                       FIXNUM_BITS));
 
   gcc_jit_rvalue *minus_res =
     emit_binary_op (