* [committed] Fix ICE in mem_loc_descriptor (PR debug/49567)
@ 2011-06-29 8:30 Jakub Jelinek
0 siblings, 0 replies; only message in thread
From: Jakub Jelinek @ 2011-06-29 8:30 UTC (permalink / raw)
To: gcc-patches
Hi!
My assumption that SIGN/ZERO_EXTEND will always have MODE_INT class mode
was provably wrong, as can be seen on the attached testcase where mode
is integer vector. Fixed thusly, bootstrapped/regtested on x86_64-linux
and i686-linux, committed as obvious.
2011-06-29 Jakub Jelinek <jakub@redhat.com>
PR debug/49567
* dwarf2out.c (mem_loc_descriptor) <case ZERO_EXTEND>: Give up
for non-MODE_INT modes instead of asserting the mode has MODE_INT
class.
* gcc.target/i386/pr49567.c: New test.
--- gcc/dwarf2out.c.jj 2011-06-23 10:13:58.000000000 +0200
+++ gcc/dwarf2out.c 2011-06-28 16:12:08.000000000 +0200
@@ -14762,7 +14762,8 @@ mem_loc_descriptor (rtx rtl, enum machin
case SIGN_EXTEND:
case ZERO_EXTEND:
- gcc_assert (GET_MODE_CLASS (mode) == MODE_INT);
+ if (GET_MODE_CLASS (mode) != MODE_INT)
+ break;
op0 = mem_loc_descriptor (XEXP (rtl, 0), GET_MODE (XEXP (rtl, 0)),
mem_mode, VAR_INIT_STATUS_INITIALIZED);
if (op0 == 0)
--- gcc/testsuite/gcc.target/i386/pr49567.c.jj 2011-06-28 19:02:11.000000000 +0200
+++ gcc/testsuite/gcc.target/i386/pr49567.c 2011-06-28 19:01:41.000000000 +0200
@@ -0,0 +1,13 @@
+/* PR debug/49567 */
+/* { dg-do compile } */
+/* { dg-options "-g -O2 -msse4" } */
+
+#include <x86intrin.h>
+
+__m128
+foo (__m128i x)
+{
+ __m128i y;
+ y = _mm_cvtepi16_epi32 (x);
+ return _mm_cvtepi32_ps (y);
+}
Jakub
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-06-29 8:18 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-29 8:30 [committed] Fix ICE in mem_loc_descriptor (PR debug/49567) Jakub Jelinek
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).