diff options
| author | Mattias EngdegÄrd | 2024-07-20 13:12:19 +0200 |
|---|---|---|
| committer | Mattias EngdegÄrd | 2024-07-27 12:04:09 +0200 |
| commit | 2fd38e5c496a2351a25e95df37a7900f6f80f22f (patch) | |
| tree | 8b4bb30916da084175a880e285ed8656e0641b70 /java/org/gnu | |
| parent | 156a3ba4f9ef9f7a401cfd3ca118152169f0ddcf (diff) | |
| download | emacs-2fd38e5c496a2351a25e95df37a7900f6f80f22f.tar.gz emacs-2fd38e5c496a2351a25e95df37a7900f6f80f22f.zip | |
Simplify and speed up numeric comparisons
This makes comparison functions (=, /=, <, <=, >, >=, min, max) quite
a bit faster (10-20 %). Bytecode ops on fixnums are not affected,
nor is `value<`.
* src/data.c (arithcompare): Simplify the code to reduce the number of
branches. Remove the comparison code argument; instead, return the
relation encoded as bits, which can be tested cheaply. All callers
adapted.
* src/lisp.h (enum Arith_Comparison): Remove.
(Cmp_Bit_*, cmp_bits_t): New.
Diffstat (limited to 'java/org/gnu')
0 files changed, 0 insertions, 0 deletions