emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master 89bb5a5f35: Speed up `=` on fixnums in bytecode


From: Mattias Engdegård
Subject: master 89bb5a5f35: Speed up `=` on fixnums in bytecode
Date: Sat, 12 Feb 2022 14:58:11 -0500 (EST)

branch: master
commit 89bb5a5f357e911aeb0b9f14e8b2f7c5a5fbabf7
Author: Mattias Engdegård <mattiase@acm.org>
Commit: Mattias Engdegård <mattiase@acm.org>

    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.
---
 src/bytecode.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bytecode.c b/src/bytecode.c
index 1018e81d24..bda9a39b7f 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;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]