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

Re: PCL benchmark

  Could you give me some reasons why PCL performance is bad in KCL?
I might be able to help improve KCL if I know where to look.

The following two forms allow iwmc-class-p to be expanded inline into
code that has no function calls (assuming safety is 0 or 1).
This works in both (unaltered) KCL and AKCL.

;in kcl-low
(si:define-compiler-macro iwmc-class-p (x)
  (once-only (x)
    `(and (si:structurep ,x)
          (do ((n (si:structure-name ,x)))
	      ((null n) nil)
	    (when (eq n 'iwmc-class-p) return t)
	    (setq n (get n 'si::structure-include))))))

(dolist (inline '((si:structurep ((t) compiler::boolean nil nil
		  (si:structure-name ((t) t nil nil "(#0)->str.str_name")
  (setf (get (first inline) (third inline)) (list (second inline))))

Rick Harris