public inbox for cgen@sourceware.org
 help / color / mirror / Atom feed
* play.cpu or parallel semantics broken
@ 2002-03-20 15:56 Hans-Peter Nilsson
  2002-03-20 16:15 ` Doug Evans
  0 siblings, 1 reply; 3+ messages in thread
From: Hans-Peter Nilsson @ 2002-03-20 15:56 UTC (permalink / raw)
  To: cgen

#guile
guile> (load "dev.scm")
[...]
guile> (load-sim)
[...]
guile> (cload #:arch "cpu/play")
[...]
guile> (cgen-sem-switch.c)
Generating cpuf sem-switch.c ...
Analyzing instruction set ...
[...]
Processing semantic switch case for "add $dr,$sr" ...
[ Note that this is actually addv2; they confusingly have the
same "syntax". ]

Backtrace:
32* [#<procedure (e)> (parallel () DFLT ...)]
33* [rtl-c-with-estate #(# #) #(# #) (parallel () DFLT () ...)]
34  [cx:c ...
35*  [rtl-c-get #(# #) #(# #) ...
36*   [rtx-eval-with-estate (parallel () DFLT () ...) #(# #) #(# #)]
37    (if (pair? expr) (let* (# #) (if fn # ...)) ...)
      ...
38    [s-parallel #(#("object" # #f ...) (# #f # ...)) (set () DFLT ...) ...]
39    (let* ((set-dests #) (temps #)) (set! -par-temp-list temps) ...)
40*   [string-map #<procedure (e)> ...
41*    [-par-replace-set-dests #(# #) (# # #)]
42     (let ((sets (list # # # #))) (letrec ((replace #)) (map replace exprs)))
       ...
43     [map #<procedure replace (expr)> (# # #)]
44*    [replace (set () DFLT ...)]
45*    (let (# # #) (if # # #))
46     (if (memq name sets) (list name options ...) ...)
47     [list set () DFLT ...
48*     [-par-new-temp! ...
49*      (if (mode:eq? # mode) (rtx-lvalue-mode-name estate #) mode)
50       [rtx-lvalue-mode-name #(# #) (local () DFLT tmp1)]
         ...
51       [error "rtx-lvalue-mode-name: not an operand or hardware reference:" $

./rtl.scm:437:6: In procedure error in expression (error "rtx-lvalue-mode-name: not an operand or hardware reference:" x):
./rtl.scm:437:6: rtx-lvalue-mode-name: not an operand or hardware reference: (local () DFLT tmp1)
ABORT: (misc-error)

Also happens with (cgen-semantics.c).  And this also happens
without my recent pmacros.scm patch. ;-)

It looks like a parallel does not inherit the variables of a
surrounding sequence; in this case tmp1.  Not that I need that
feature, but I think play.cpu shouldn't fail.  An easy way out
is to just remove addv2.

brgds, H-P

^ permalink raw reply	[flat|nested] 3+ messages in thread

* play.cpu or parallel semantics broken
  2002-03-20 15:56 play.cpu or parallel semantics broken Hans-Peter Nilsson
@ 2002-03-20 16:15 ` Doug Evans
  2002-03-20 16:31   ` Hans-Peter Nilsson
  0 siblings, 1 reply; 3+ messages in thread
From: Doug Evans @ 2002-03-20 16:15 UTC (permalink / raw)
  To: Hans-Peter Nilsson; +Cc: cgen

Hans-Peter Nilsson writes:
 > Processing semantic switch case for "add $dr,$sr" ...
 > [ Note that this is actually addv2; they confusingly have the
 > same "syntax". ]

NOTE: play.cpu was only ever a sandbox for playing in.
If someone wants to put in the time to clean it up, go for it.
It's not/wasn't intended to be something someone would base anything off of.

 > It looks like a parallel does not inherit the variables of a
 > surrounding sequence; in this case tmp1.

That's odd.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: play.cpu or parallel semantics broken
  2002-03-20 16:15 ` Doug Evans
@ 2002-03-20 16:31   ` Hans-Peter Nilsson
  0 siblings, 0 replies; 3+ messages in thread
From: Hans-Peter Nilsson @ 2002-03-20 16:31 UTC (permalink / raw)
  To: dje; +Cc: hans-peter.nilsson, cgen

> From: Doug Evans <dje@transmeta.com>
> Date: Wed, 20 Mar 2002 16:14:53 -0800 (PST)

> Hans-Peter Nilsson writes:
>  > Processing semantic switch case for "add $dr,$sr" ...
>  > [ Note that this is actually addv2; they confusingly have the
>  > same "syntax". ]
> 
> NOTE: play.cpu was only ever a sandbox for playing in.

I'm using it exactly as such.  Or trying to. :-)
See next message.

> If someone wants to put in the time to clean it up, go for it.

So, ok to clean it up by removing addv2?  That seems all that's
needed.

brgds, H-P

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2002-03-21  0:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-03-20 15:56 play.cpu or parallel semantics broken Hans-Peter Nilsson
2002-03-20 16:15 ` Doug Evans
2002-03-20 16:31   ` Hans-Peter Nilsson

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).