From: Mattias EngdegÄrd Date: Thu, 3 Feb 2022 09:26:27 +0000 (+0100) Subject: Speed up `=` on fixnums in bytecode X-Git-Tag: emacs-29.0.90~2355 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=89bb5a5f357e911aeb0b9f14e8b2f7c5a5fbabf7;p=emacs.git Speed up `=` on fixnums in bytecode Now that EQ has become expensive, use BASE_EQ where possible. * src/bytecode.c (exec_byte_code): Use cheaper operation for Beqlsign. --- diff --git a/src/bytecode.c b/src/bytecode.c index 1018e81d24c..bda9a39b7f3 100644 --- a/src/bytecode.c +++ b/src/bytecode.c @@ -1060,7 +1060,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth, Lisp_Object v2 = POP; Lisp_Object v1 = TOP; if (FIXNUMP (v1) && FIXNUMP (v2)) - TOP = EQ (v1, v2) ? Qt : Qnil; + TOP = BASE_EQ(v1, v2) ? Qt : Qnil; else TOP = arithcompare (v1, v2, ARITH_EQUAL); NEXT;