Skip to content
Snippets Groups Projects
Commit 3df2616c authored by dtc's avatar dtc
Browse files

Fix for the CMP instruction which was intended to have accepted a

constant TN as an argument, but which failed when comparing a constant TN
and integer arguments. For example this can occur when the integer is the
static symbol Nil. Noted by Andy Freeman.
parent ef5f3a18
No related branches found
No related tags found
No related merge requests found
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
;;; Scott Fahlman or slisp-group@cs.cmu.edu. ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
;;; ;;;
(ext:file-comment (ext:file-comment
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/x86/insts.lisp,v 1.16 1998/02/24 09:59:21 dtc Exp $") "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/x86/insts.lisp,v 1.17 1999/09/28 16:07:50 dtc Exp $")
;;; ;;;
;;; ********************************************************************** ;;; **********************************************************************
;;; ;;;
...@@ -1152,7 +1152,7 @@ ...@@ -1152,7 +1152,7 @@
((integerp src) ((integerp src)
(cond ((and (not (eq size :byte)) (<= -128 src 127)) (cond ((and (not (eq size :byte)) (<= -128 src 127))
(emit-byte segment #b10000011) (emit-byte segment #b10000011)
(emit-ea segment dst opcode) (emit-ea segment dst opcode allow-constants)
(emit-byte segment src)) (emit-byte segment src))
((accumulator-p dst) ((accumulator-p dst)
(emit-byte segment (emit-byte segment
...@@ -1164,7 +1164,7 @@ ...@@ -1164,7 +1164,7 @@
(emit-sized-immediate segment size src)) (emit-sized-immediate segment size src))
(t (t
(emit-byte segment (if (eq size :byte) #b10000000 #b10000001)) (emit-byte segment (if (eq size :byte) #b10000000 #b10000001))
(emit-ea segment dst opcode) (emit-ea segment dst opcode allow-constants)
(emit-sized-immediate segment size src)))) (emit-sized-immediate segment size src))))
((register-p src) ((register-p src)
(emit-byte segment (emit-byte segment
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment