Removed unused location types and replaced CAR/CDR uses with C inline functions in src/cmp

This commit is contained in:
Juan Jose Garcia Ripoll 2011-12-03 22:43:48 +01:00
parent fd9d8be539
commit f26a13885e
4 changed files with 10 additions and 22 deletions

View file

@ -33,9 +33,6 @@
;;; ( CALL-INDIRECT fun narg args) similar as CALL, but unknown function
;;; ( C-INLINE output-type fun/string locs side-effects output-var )
;;; ( COERCE-LOC representation-type location)
;;; ( CAR lcl )
;;; ( CDR lcl )
;;; ( CADR lcl )
;;; ( FDEFINITION vv-index )
;;; ( MAKE-CCLOSURE cfun )
;;; ( FIXNUM-VALUE fixnum-value )
@ -151,12 +148,6 @@
'(RETURN RETURN-FIXNUM RETURN-CHARACTER RETURN-SINGLE-FLOAT
RETURN-DOUBLE-FLOAT RETURN-LONG-FLOAT RETURN-OBJECT)))
(defun wt-car (loc) (wt "CAR(" loc ")"))
(defun wt-cdr (loc) (wt "CDR(" loc ")"))
(defun wt-cadr (loc) (wt "CADR(" loc ")"))
(defun lcl-name (lcl) (format nil "V~D" lcl))
(defun wt-lcl (lcl) (unless (numberp lcl) (baboon)) (wt "V" lcl))

View file

@ -110,9 +110,6 @@
(temp . wt-temp)
(lcl . wt-lcl-loc)
(car . wt-car)
(cdr . wt-cdr)
(cadr . wt-cadr)
(fixnum-value . wt-number)
(long-float-value . wt-number)
(double-float-value . wt-number)

View file

@ -736,7 +736,7 @@
(wt-nl "CLV" n)
(if first
(progn (wt "=env0;") (setf first nil))
(wt "=CDR(CLV" (1+ n) ");"))
(wt "=_ecl_cdr(CLV" (1+ n) ");"))
(when (= n (var-loc (first bs)))
(wt-comment (var-name (first clv-used)))
(pop clv-used)))

View file

@ -275,15 +275,15 @@
;; file list.d
(def-inline car :unsafe (cons) t "ECL_CONS_CAR(#0)")
(def-inline car :unsafe (t) t "CAR(#0)")
(def-inline car :unsafe (t) t "_ecl_car(#0)")
(def-inline si::cons-car :always (t) t "CAR(#0)")
(def-inline si::cons-car :always (t) t "_ecl_car(#0)")
(def-inline si::cons-car :unsafe (t) t "ECL_CONS_CAR(#0)")
(def-inline cdr :unsafe (cons) t "ECL_CONS_CDR(#0)")
(def-inline cdr :unsafe (t) t "CDR(#0)")
(def-inline cdr :unsafe (t) t "_ecl_cdr(#0)")
(def-inline si::cons-cdr :always (t) t "CDR(#0)")
(def-inline si::cons-cdr :always (t) t "_ecl_cdr(#0)")
(def-inline si::cons-cdr :unsafe (t) t "ECL_CONS_CDR(#0)")
;; BEGIN-GENERATED (gen-cons-sysfun)
@ -366,14 +366,14 @@
(def-inline fourth :always (t) t "ecl_cadddr(#0)")
(def-inline first :unsafe (cons) t "ECL_CONS_CAR(#0)")
(def-inline first :unsafe (t) t "CAR(#0)")
(def-inline second :unsafe (t) t "CADR(#0)")
(def-inline third :unsafe (t) t "CADDR(#0)")
(def-inline fourth :unsafe (t) t "CADDDR(#0)")
(def-inline first :unsafe (t) t "_ecl_car(#0)")
(def-inline second :unsafe (t) t "_ecl_cadr(#0)")
(def-inline third :unsafe (t) t "_ecl_caddr(#0)")
(def-inline fourth :unsafe (t) t "_ecl_cadddr(#0)")
(def-inline rest :always (t) t "ecl_cdr(#0)")
(def-inline rest :unsafe (cons) t "ECL_CONS_CDR(#0)")
(def-inline rest :unsafe (t) t "CDR(#0)")
(def-inline rest :unsafe (t) t "_ecl_cdr(#0)")
(def-inline nthcdr :always (t t) t "ecl_nthcdr(fixint(#0),#1)")
(def-inline nthcdr :always (fixnum t) t "ecl_nthcdr(#0,#1)")