[Bug rtl-optimization/66048] [i386] ICE in create_pre_exit when both AVX and MPX are used
ubizjak at gmail dot com
gcc-bugzilla@gcc.gnu.org
Thu May 7 13:26:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66048
--- Comment #1 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to Ilya Enkovich from comment #0)
> Created attachment 35485 [details]
> reproducer
>
> >gcc mode-switch.cc -march=corei7-avx -mmpx -fcheck-pointer-bounds -O2 -c
>
> mode-switch.cc: In function 'c1 test.chkp(c2, #'pointer_bounds_type' not
> supported by dump_type#<type error>, void, ...)':
> mode-switch.cc:13:1: internal compiler error: in create_pre_exit, at
> mode-switching.c:464
There is a *very* picky assert in mode-switching.c that otherwise allows
various exceptions when expected sequence:
(set (reg X) ...)
(use (reg X))
is NOT found. But... you'll have to explain why certain exception is allowed.
In your case, a multi_reg_return condition triggered, so:
--cut here--
Index: mode-switching.c
===================================================================
--- mode-switching.c (revision 222869)
+++ mode-switching.c (working copy)
@@ -461,7 +461,10 @@ create_pre_exit (int n_entities, int *entity_map,
This doesn't actually cause reload
failures, so let it pass. */
|| (GET_MODE_CLASS (GET_MODE (ret_reg)) != MODE_INT
- && nregs != 1));
+ && nregs != 1)
+ /* Comment here. */
+ || (multi_reg_return
+ && /* some tight condition */ 1));
if (!NOTE_INSN_BASIC_BLOCK_P (last_insn))
{
--cut here--
Please note that this part of the code can make a grown man cry...
More information about the Gcc-bugs
mailing list