Skip to content
Snippets Groups Projects
Commit 7fb35585 authored by wlott's avatar wlott
Browse files

Optimized CHECK-STRUCTURE to use the conditional trap sequence a la

CHECK-LIST instead of branching off to elsewhere code that does an
unconditional break.  This should help reduce the size of SPARC cores.
parent 7d41b8fb
No related branches found
No related tags found
No related merge requests found
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
;;; Scott Fahlman (FAHLMAN@CMUC). ;;; Scott Fahlman (FAHLMAN@CMUC).
;;; ********************************************************************** ;;; **********************************************************************
;;; ;;;
;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/type-vops.lisp,v 1.6 1991/08/04 11:38:08 wlott Exp $ ;;; $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/type-vops.lisp,v 1.7 1991/10/31 16:19:55 wlott Exp $
;;; ;;;
;;; This file contains the VM definition of type testing and checking VOPs ;;; This file contains the VM definition of type testing and checking VOPs
;;; for the SPARC. ;;; for the SPARC.
...@@ -84,8 +84,14 @@ ...@@ -84,8 +84,14 @@
(move result value))) (move result value)))
(primitive-type-vop check-list (:check) list) (primitive-type-vop check-list (:check) list)
(def-type-vops structurep check-structure structure (def-type-vops structurep nil nil nil vm:structure-pointer-type)
object-not-structure-error vm:structure-pointer-type) (define-vop (check-structure check-type)
(:generator 3
(inst and temp value lowtag-mask)
(inst cmp temp structure-pointer-type)
(inst t :ne (logior (ash (tn-offset value) 8) object-not-structure-trap))
(move result value)))
(primitive-type-vop check-structure (:check) structure)
(def-type-vops bignump check-bigunm bignum (def-type-vops bignump check-bigunm bignum
object-not-bignum-error vm:bignum-type) object-not-bignum-error vm:bignum-type)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment