public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* target/8870: ICE converting from unsigned short to MMX type
@ 2002-12-07 21:36 otaylor
0 siblings, 0 replies; only message in thread
From: otaylor @ 2002-12-07 21:36 UTC (permalink / raw)
To: gcc-gnats
>Number: 8870
>Category: target
>Synopsis: ICE converting from unsigned short to MMX type
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: ice-on-legal-code
>Submitter-Id: net
>Arrival-Date: Sat Dec 07 21:36:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: otaylor@redhat.com
>Release: CVS Head, 7 December 2002
>Organization:
>Environment:
Linux/ia32
>Description:
Conversions directly from a 16-bit unsigned integer
to a MMX type cause problems. (Conversion from
a 16-bit signed integer works fine, however.)
>How-To-Repeat:
When compiled with:
gcc -c -O1 -mmmx -march=i686 -mcpu=i686 truncate-bug.c
===
typedef int v4hi __attribute__ ((mode (V4HI)));
static inline v4hi
cvtsi_v4hi (int i)
{
long long tmp = (unsigned int)i;
return (v4hi) tmp;
}
v4hi
bar (unsigned short a)
{
return cvtsi_v4hi (a);
}
===
Produces:
===
truncate-bug.c: In function `bar':
truncate-bug.c:14: internal compiler error: in trunc_int_for_mode, at explow.c:54
===
This code compiles without error with the Red Hat 8
compiler, so probably with stock gcc-3.2 as well.
Changing 'unsigned short' to 'short' above, makes the
ICE go away.
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-12-08 5:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-07 21:36 target/8870: ICE converting from unsigned short to MMX type otaylor
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).