public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c/10201: [3.3/3.4] ICE in int_mode_for_mode, at stor-layout.c
@ 2003-03-24 17:56 zlomj9am
  0 siblings, 0 replies; only message in thread
From: zlomj9am @ 2003-03-24 17:56 UTC (permalink / raw)
  To: gcc-gnats; +Cc: aj


>Number:         10201
>Category:       c
>Synopsis:       [3.3/3.4] ICE in int_mode_for_mode, at stor-layout.c
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          ice-on-legal-code
>Submitter-Id:   net
>Arrival-Date:   Mon Mar 24 17:56:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     zlomj9am@artax.karlin.mff.cuni.cz
>Release:        3.3/3.4
>Organization:
>Environment:
ia64 linux
>Description:
When compiling a declaration of a structure (after its forward declaration and use) the DECL_RTL of the tree is VOIDmode and it is not updated to BLKmode.
This causes an ICE in int_mode_for_mode(VOIDmode), at stor-layout.c.
The testcase has to be compiled with optimization because then the functions are deferred and compiled after all global vars,  structs,...
Surprisingly I can reproduce it only on ia64 from the platforms I tested.

#0  fancy_abort (file=0x4000000000d0ca98 "../../gcc/stor-layout.c", line=306, function=0x4000000000d0cba8 "int_mode_for_mode") at ../../gcc/diagnostic.c:1367
#1  0x400000000091d790 in int_mode_for_mode (mode=VOIDmode) at ../../gcc/stor-layout.c:306
#2  0x40000000003865f0 in store_bit_field (str_rtx=0x2000000000327120, bitsize=32, bitnum=64, fieldmode=SImode, value=0x20000000003272c0, total_size=24)
    at ../../gcc/expmed.c:384
#3  0x40000000003d5af0 in store_field (target=0x2000000000327120, bitsize=32, bitpos=64, mode=SImode, exp=0x200000000036d080, value_mode=VOIDmode, unsignedp=0, 
    type=0x2000000000368000, alias_set=0) at ../../gcc/expr.c:5611
#4  0x40000000003c37a0 in expand_assignment (to=0x200000000036d050, from=0x200000000036d080, want_value=0, suggest_reg=1) at ../../gcc/expr.c:4186
#5  0x4000000000427c90 in expand_expr (exp=0x200000000036d0b0, target=0x0, tmode=VOIDmode, modifier=EXPAND_NORMAL) at ../../gcc/expr.c:9115
#6  0x40000000008ef2e0 in expand_expr_stmt_value (exp=0x200000000036d0b0, want_value=0, maybe_last=1) at ../../gcc/stmt.c:2197
#7  0x400000000017ace0 in genrtl_expr_stmt_value (expr=0x200000000036d0b0, want_value=0, maybe_last=1) at ../../gcc/c-semantics.c:358
#8  0x40000000001833a0 in expand_stmt (t=0x200000000036d110) at ../../gcc/c-semantics.c:814
#9  0x4000000000181cd0 in genrtl_compound_stmt (t=0x200000000036cea0) at ../../gcc/c-semantics.c:727
#10 0x40000000001834c0 in expand_stmt (t=0x200000000036cea0) at ../../gcc/c-semantics.c:841
#11 0x4000000000097600 in c_expand_body_1 (fndecl=0x2000000000368f70, nested_p=0) at ../../gcc/c-decl.c:6566
#12 0x4000000000098b80 in c_expand_body (fndecl=0x2000000000368f70) at ../../gcc/c-decl.c:6671
#13 0x4000000000096bc0 in c_expand_deferred_function (fndecl=0x2000000000368f70) at ../../gcc/c-decl.c:6513
#14 0x4000000000190fa0 in expand_deferred_fns () at ../../gcc/c-objc-common.c:304
#15 0x4000000000191d30 in c_objc_common_finish_file () at ../../gcc/c-objc-common.c:369
#16 0x4000000000022e70 in finish_file () at ../../gcc/c-lang.c:222
#17 0x40000000000043d0 in yyparse () at c-parse.y:341
#18 0x4000000000164d50 in c_common_parse_file (set_yydebug=0) at ../../gcc/c-opts.c:1630
#19 0x40000000009448c0 in compile_file () at ../../gcc/toplev.c:2197
#20 0x4000000000959530 in do_compile () at ../../gcc/toplev.c:5545
#21 0x40000000009596e0 in toplev_main (argc=3, argv=0x60000fffffffaf58) at ../../gcc/toplev.c:5580
#22 0x40000000001e5050 in main (argc=3, argv=0x60000fffffffaf58) at ../../gcc/main.c:37

>How-To-Repeat:
cc1 -O z.i
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="z.i"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="z.i"

ZXh0ZXJuIHN0cnVjdCBfemVuZF9jb21waWxlcl9nbG9iYWxzIGNvbXBpbGVyX2dsb2JhbHM7CnR5
cGVkZWYgc3RydWN0IF96ZW5kX2V4ZWN1dG9yX2dsb2JhbHMgemVuZF9leGVjdXRvcl9nbG9iYWxz
OwpleHRlcm4gemVuZF9leGVjdXRvcl9nbG9iYWxzIGV4ZWN1dG9yX2dsb2JhbHM7Cgp0eXBlZGVm
IHN0cnVjdCBfemVuZF9wdHJfc3RhY2sgewogICAgICAgIGludCB0b3A7CiAgICAgICAgdm9pZCAq
KnRvcF9lbGVtZW50Owp9IHplbmRfcHRyX3N0YWNrOwpzdHJ1Y3QgX3plbmRfY29tcGlsZXJfZ2xv
YmFscyB7Cn07CnN0cnVjdCBfemVuZF9leGVjdXRvcl9nbG9iYWxzIHsKICAgICAgICBpbnQgKnVu
aW5pdGlhbGl6ZWRfenZhbF9wdHI7CiAgICAgICAgemVuZF9wdHJfc3RhY2sgYXJndW1lbnRfc3Rh
Y2s7Cn07CgpzdGF0aWMgaW5saW5lIHZvaWQgc2FmZV9mcmVlX3p2YWxfcHRyKGludCAqcCkKewog
ICAgICAgIGlmIChwIT0oZXhlY3V0b3JfZ2xvYmFscy51bmluaXRpYWxpemVkX3p2YWxfcHRyKSkg
ewogICAgICAgIH0KfQp6ZW5kX2V4ZWN1dG9yX2dsb2JhbHMgZXhlY3V0b3JfZ2xvYmFsczsKc3Rh
dGljIGlubGluZSB2b2lkIHplbmRfcHRyX3N0YWNrX2NsZWFyX211bHRpcGxlKHZvaWQpCnsKICAg
ICAgICBleGVjdXRvcl9nbG9iYWxzLmFyZ3VtZW50X3N0YWNrLnRvcCAtPSAyOwp9Cg==


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-03-24 17:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-03-24 17:56 c/10201: [3.3/3.4] ICE in int_mode_for_mode, at stor-layout.c zlomj9am

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