public inbox for cgen@sourceware.org
 help / color / mirror / Atom feed
* Can't see what's wrong with my simulator semantics code....
@ 2001-06-30 10:20 Alan Lehotsky
  0 siblings, 0 replies; 6+ messages in thread
From: Alan Lehotsky @ 2001-06-30 10:20 UTC (permalink / raw)
  To: cgen

cgen claims

     ERROR: read:array unknown option  #\)

when processing the (set dest (if ...)) below.  If I comment out that
3 line "set", it compiles my simulator.
I'm sure I'm doing something really stupid, but this LOOKS like
expressions that compile....

-- Al

p.s.	The instruction basically takes one half of the 32 bit word
	and compares it against a 16 bit immediate.  The 'idx' is a 2 bit
	field where 00=> low 16 bits, 11=> high 16 bits....

=======================


(dni cmpwi "compare word immediate"
     ()
     "cmpwi $rd$idx,$imm16"
     (+ OP5_CMPWI rd idx imm16)
     (sequence ((SI dest))
	       (set dest (if SI (eq idx #3)
			        (and #xffff (srl rd #16))
			        (and #xffff rd)))
	       (set zbit (eq imm16 dest)))
     ()
)

===============
-- 
------------------------------------------------------------------------

		    Quality Software Management
		http://home.earthlink.net/users/~qsmgmt
			apl@alum.mit.edu
			(978)287-0435 Voice
			(978)808-6836 Cell
			(978)287-0436 Fax

	Software Process Improvement and Management Consulting
	     Language Design and Compiler Implementation

^ permalink raw reply	[flat|nested] 6+ messages in thread
[parent not found: <p04330101b763b6596543.cygnus.local.cgen@[192.168.1.254]>]

end of thread, other threads:[~2001-06-30 17:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-30 10:20 Can't see what's wrong with my simulator semantics code Alan Lehotsky
     [not found] <p04330101b763b6596543.cygnus.local.cgen@[192.168.1.254]>
2001-06-30 11:55 ` Geoff Keating
2001-06-30 12:10   ` Alan Lehotsky
2001-06-30 12:25     ` Geoff Keating
2001-06-30 12:35       ` Alan Lehotsky
2001-06-30 17:12     ` Ben Elliston

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).