This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/11226] New: ICE passing struct arg with two floats
- From: "janis187 at us dot ibm dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 17 Jun 2003 22:39:48 -0000
- Subject: [Bug target/11226] New: ICE passing struct arg with two floats
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11226
Summary: ICE passing struct arg with two floats
Product: gcc
Version: 3.3
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: target
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: janis187@us.ibm.com
CC: gcc-bugs@gcc.gnu.org
GCC build triplet: ia64-unknown-linux-gnu
GCC host triplet: ia64-unknown-linux-gnu
GCC target triplet: ia64-unknown-linux-gnu
GCC for ia64-linux gets an ICE compiling this test case, which is
extracted from gcc.dg/compat/struct-by-value-5_x.c:
-----------
typedef struct { float a; float b; } Sf2;
Sf2 g1, g2, g3, g4, g5, g6;
extern void testSf2 (Sf2, Sf2, Sf2, Sf2, Sf2, Sf2,
Sf2, Sf2, Sf2, Sf2, Sf2, Sf2);
void test2_Sf2 (Sf2 s1, Sf2 s2, Sf2 s3, Sf2 s4, Sf2 s5, Sf2 s6)
{
testSf2 (s1, g1, s2, g2, s3, g3, s4, g4, s5, g5, s6, g6);
}
-----------
Output from gcc version 3.4 20030617 (experimental):
bug1.c: In function `test2_Sf2':
bug1.c:10: internal compiler error: in emit_block_move, at expr.c:1793
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
The test case passes with 3.0.4 and 3.2 and fails with 3.3 and mainline.
It started failing with the following patch, which probably exposes some
latent target bug since the same test passes on several other platforms:
--- gcc/gcc/ChangeLog ---
2002-08-20 Richard Henderson <rth@redhat.com>
* expr.c (TARGET_MEM_FUNCTIONS): Transform to boolean.
(emit_block_move): Split out subroutines.
(emit_block_move_via_movstr): New.
(emit_block_move_via_libcall): New. Emit bcopy via normal call also.
(emit_block_move_libcall_fn): New. Construct function prototype for
bcopy as well.
(clear_storage): Split out subroutines.
(clear_storage_via_clrstr): New.
(clear_storage_via_libcall): New. Emit bzero as a normal call also.
(clear_storage_libcall_fn): New. Construct function prototype for
bzero as well.
(emit_push_insn): Use emit_block_move.
(expand_assignment): Booleanize TARGET_MEM_FUNCTIONS.
(store_constructor): Likewise.