Speedup overload resolution and some other stuff for faster C++ method calling.
src/objects/type.lisp
Wed Jul 8 22:41:19 CEST 2009 Tobias Rautenkranz <tobias@rautenkranz.ch>
* Speedup overload resolution and some other stuff for faster C++ method calling.
--- old-smoke/src/objects/type.lisp 2014-10-30 08:13:02.000000000 +0100
+++ new-smoke/src/objects/type.lisp 2014-10-30 08:13:02.000000000 +0100
@@ -120,10 +120,11 @@
;; For efficiency just check if the first byte is a null byte;
;; No need to convert the entire C string to lisp like in:
;; (null (name type)))
+ (declare (optimize (speed 3)))
(= 0 (mem-ref (mem-aref (smoke-array-pointer
(smoke-module-types (smoke type)))
'smoke-type
- (id type))
+ (the smoke-index (id type)))
:char)))