This is the mail archive of the cgen@sourceware.org mailing list for the CGEN project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA:] Fix breakage of manually building SID CPU


> Date: Mon, 30 Jan 2006 12:21:20 -0500
> From: Dave Brolley <brolley@redhat.com>

> The patch looks ok to me. Please go ahead and commit it.

Finally done.

I must mention at least for the record that I see further errors
stopping generation of a SID cgen-cpu description with sources
as of today, for example the guile command sequence:

(load "dev.scm")
(load-sid)
(cload #:arch "../../cpu/cris" #:options "with-scache" #:machs "crisv32")
(cgen-semantics.cxx)

Gets:
... (seemingly successfully output C++ semantic translations.)
  return status;
#undef FLD
}

Processing semantics for bcc-b: "b${cc} ${o-pcrel}" ...

Backtrace:
In ./rtl-c.scm:
1400:  0* [string-append "(delay ...) rtx applied to wrong type of operand '" ...]
1398:  1  [context-error #f ...
1393:  2* (if (let # #) (context-error # #))
1387:  3  (let* (# # #) (if # #) (if # #) ...)
1385:  4  (case APPLICATION ((SID-SIMULATOR) (let* (# # #) (if # #) ...)) ...)
In unknown file:
   ?:  5  [#<procedure #f (estate options mode num-node ...)> #(# #) () DFLT ...]
In ./rtl-traverse.scm:
1019:  6  [apply #<procedure #f (estate options mode ...)> (#(# #) () DFLT ...)]
1018:  7  (if (procedure? fn) (apply fn (cons estate (cdr expr))) fn)
1017:  8  (if fn (if (procedure? fn) (apply fn (cons estate #)) fn) expr)
1015:  9  (let* ((rtx-obj #) (fn #)) (if fn (if # # fn) expr))
1013: 10  (if (pair? expr) (let* ((rtx-obj #) (fn #)) (if fn (if # # ...) ...)) ...)
In ./rtl-c.scm:
 434: 11* [rtx-eval-with-estate (delay () DFLT # ...) #(# #) #(# #)]
 434: 12  (let ((evald-src #)) (if (not #) (error assert-fail-msg #)) ...)
 417: 13  (cond ((c-expr? src) (cond # # ...)) ((rtx? src) (let # # ...)) ...)
 415: 14  (let ((mode #)) (cond (# #) (# #) (# #) ...))
 488: 15* [-rtl-c-get #(#("object" # #f ...) (# #f # ...)) DFLT ...]
 488: 16  (let (#) (if # #) result)
 870: 17* [rtl-c-get #(#("object" # #f ...) (# #f # ...)) DFLT ...]
 870: 18* [cx:c ...
 869: 19* [string-append "if (" "tmp_truthval" ")" " { " ...
 868: 20  [cx:make DFLT ...
    ...
In unknown file:
   ?: 21  [s-if #(#("object" # #f ...) (# #f # ...)) DFLT ...]
In ./rtl-c.scm:
1725: 22  [apply #<procedure s-if (estate mode cond then . else)> (# DFLT # #)]
In unknown file:
   ?: 23  [#<procedure #f (estate options mode cond ...)> #(# #) () DFLT ...]
In ./rtl-traverse.scm:
1019: 24  [apply #<procedure #f (estate options mode ...)> (#(# #) () DFLT ...)]
1018: 25  (if (procedure? fn) (apply fn (cons estate (cdr expr))) fn)
1017: 26  (if fn (if (procedure? fn) (apply fn (cons estate #)) fn) expr)
1015: 27  (let* ((rtx-obj #) (fn #)) (if fn (if # # fn) expr))
1013: 28  (if (pair? expr) (let* ((rtx-obj #) (fn #)) (if fn (if # # ...) ...)) ...)
In ./rtl-c.scm:
 307: 29* [rtx-eval-with-estate (if () DFLT # ...) #(# #) #(# #)]
 307: 30* [rtl-c-get #(# #) #(# #) ...
 307: 31  [cx:c ...
1206: 32* [rtl-c-with-estate #(# #) #(# #) (if () DFLT # ...)]
In unknown file:
   ?: 33* [#<procedure #f (e)> (if () DFLT ...)]
   ?: 34* [map #<procedure #f (e)> (# # # #)]
   ?: 35  [apply #<primitive-procedure map> (#<procedure #f (e)> (# # # #))]
In ./utils.scm:
  96: 36* [apply #<primitive-procedure map> (#<procedure #f (e)> (# # # #))]
  96: 37  [apply #<primitive-procedure string-append> ...
In ./rtl-c.scm:
1205: 38* [string-map #<procedure #f (e)> (# # # #)]
1197: 39* [string-append "{ " "  BI tmp_truthval; " ...
1196: 40  [cx:make DFLT ...
    ...
In unknown file:
   ?: 41  [s-sequence #(#("object" # #f ...) (# #f # ...)) DFLT ...]
In ./rtl-c.scm:
1741: 42  [apply #<procedure s-sequence (estate mode env . exprs)> (# DFLT # # ...)]
In unknown file:
   ?: 43  [#<procedure #f (estate options mode locals ...)> #(# #) () DFLT ...]
In ./rtl-traverse.scm:
1019: 44  [apply #<procedure #f (estate options mode ...)> (#(# #) () DFLT ...)]
1018: 45  (if (procedure? fn) (apply fn (cons estate (cdr expr))) fn)
1017: 46  (if fn (if (procedure? fn) (apply fn (cons estate #)) fn) expr)
1015: 47  (let* ((rtx-obj #) (fn #)) (if fn (if # # fn) expr))
1013: 48  (if (pair? expr) (let* ((rtx-obj #) (fn #)) (if fn (if # # ...) ...)) ...)
In ./rtl-c.scm:
 307: 49* [rtx-eval-with-estate (sequence () DFLT # ...) #(# #) #(# #)]
 307: 50* [rtl-c-get #(# #) #(# #) ...
 307: 51  [cx:c ...
 383: 52  [rtl-c-with-estate #(# #) #(# #) (sequence () DFLT # ...)]
 382: 53  (let ((estate #)) (rtl-c-with-estate estate mode x))
In ./sid-cpu.scm:
 707: 54  [rtl-c++-parsed #(# #) (sequence () DFLT # ...) () ...]
 706: 55* (if (insn-compiled-semantics insn) (rtl-c++-parsed VOID # ...) ...)
 705: 56  (let ((sem-c-code (if # # #))) sem-c-code)
 749: 57* [gen-semantic-code #(#("object" # bcc-b ...) (# #f # ...))]
 725: 58  [list "// ********** " bcc-b ... ...
 723: 59  (let (# #) (string-list "// ********** " # ": " ...))
In ./utils.scm:
 425: 60* [-gen-scache-semantic-fn #(#("object" # bcc-b ...) (# #f # ...))]
 425: 61* [-string-write #(print-state 0) ...
In unknown file:
   ?: 62* [#<procedure #f (arg)> #(#("object" # bcc-b ...) (# #f # ...))]
In ./utils.scm:
 425: 63  [for-each #<procedure #f (arg)> (#(# #) #(# #) #(# #) #(# #) ...)]
 424: 64* (let ((pstate -current-print-state)) (for-each (lambda # #) arglist))
In ./sid-cpu.scm:
 766: 65  [string-write-map #<procedure -gen-scache-semantic-fn (insn)> (# # # ...)]
 765: 66  (if (with-scache?) (string-write-map -gen-scache-semantic-fn insns) ...)
 764: 67  (let (#) (if # # #))
In ./utils.scm:
 414: 68* [-gen-all-semantic-fns]
 414: 69  [-string-write #(print-state 0) ...
 412: 70* (cond ((string? expr) (display expr)) ((symbol? expr) (display expr)) ...)
 403: 71* [-string-write #(print-state 0) #<procedure -gen-all-semantic-fns ()>]
In unknown file:
   ?: 72* [#<procedure #f (elm)> #<procedure -gen-all-semantic-fns ()>]
In ./utils.scm:
 403: 73* [for-each #<procedure #f #> #]
 401: 74  (let ((pstate (make-print-state))) (set! -current-print-state pstate) ...)
In ./sid-cpu.scm:
 802: 75  [string-write "#define GET_ATTR(name) GET_ATTR_##name ()   " ...]
In standard input:
   4: 76* [cgen-semantics.cxx]

./rtl-c.scm:1400:15: In procedure string-append in expression (string-append "(delay ...) rtx applied to wrong type of operand '"\
 (car rtx) ...):
./rtl-c.scm:1400:15: Wrong type argument (expecting STRINGP): set
ABORT: (wrong-type-arg)

Similar error when substituting #:machs "crisv10" on the cload
line, but then the first line reads:

Processing semantics for ret-type: "ret/reti/retb" ...

(i.e. the earliest occurrence of "delay" for the enabled mach).
I guessed this could be related to some change in delay
semantics, but the usage in cris.cpu seems no different to other
*.cpu.  Except that some *.cpu use (delay (const 1) ...) instead
of (delay 1 ...) but unfortunately that doesn't help; changing
that doesn't affect the behavior.

brgds, H-P


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]