Bug 55403 - [4.8 Regression] ICE building libitm
Summary: [4.8 Regression] ICE building libitm
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: middle-end (show other bugs)
Version: 4.8.0
: P3 normal
Target Milestone: 4.8.0
Assignee: Not yet assigned to anyone
URL:
Keywords: build, ice-on-valid-code
Depends on: 55391
Blocks:
  Show dependency treegraph
 
Reported: 2012-11-19 23:45 UTC by Richard Henderson
Modified: 2012-11-20 19:51 UTC (History)
2 users (show)

See Also:
Host:
Target: alphaev67-linux
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments
preprocessed source (23.33 KB, application/x-gzip)
2012-11-19 23:52 UTC, Richard Henderson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Henderson 2012-11-19 23:45:49 UTC
../../../git-master/libitm/method-serial.cc: In member function ‘virtual _ITM_TYPE_CE {anonymous}::serialirr_dispatch::ITM_RCE(const _ITM_TYPE_CE*)’:
../../../git-master/libitm/method-serial.cc:92:6212: internal compiler error: in adjust_address_1, at emit-rtl.c:2180
0x8d4501 adjust_address_1(rtx_def*, machine_mode, long, int, int, int, long)
	../../git-master/gcc/emit-rtl.c:2180
0x8eb94c extract_bit_field_1
	../../git-master/gcc/expmed.c:1383
0x8ec540 extract_bit_field(rtx_def*, unsigned long, unsigned long, int, bool, rtx_def*, machine_mode, machine_mode)
	../../git-master/gcc/expmed.c:1655
0x9166f3 expand_expr_real_1(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**)
	../../git-master/gcc/expr.c:9568
0x90ef0b expand_expr_real(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**)
	../../git-master/gcc/expr.c:7816
0x91477d expand_expr_real_1(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**)
	../../git-master/gcc/expr.c:9179
0x90ef0b expand_expr_real(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**)
	../../git-master/gcc/expr.c:7816
0x905781 store_expr(tree_node*, rtx_def*, int, bool)
	../../git-master/gcc/expr.c:5192
0x90472d expand_assignment(tree_node*, tree_node*, bool)
	../../git-master/gcc/expr.c:4978
0x81fb69 expand_gimple_stmt_1
	../../git-master/gcc/cfgexpand.c:2209
0x81ff6c expand_gimple_stmt
	../../git-master/gcc/cfgexpand.c:2305
Comment 1 Richard Henderson 2012-11-19 23:49:46 UTC
Richard S, I suspect your bit field changes.  I'll have a look at it
myself tomorrow if you don't find it first.
Comment 2 Richard Henderson 2012-11-19 23:52:51 UTC
Created attachment 28739 [details]
preprocessed source

Compile with ./cc1plus -quiet -std=c++11 -O2 method-serial.ii
Comment 3 Andrew Pinski 2012-11-20 03:00:36 UTC
Most likely the same issue as reported on sparc, PR 55391.
Comment 4 Richard Sandiford 2012-11-20 08:26:25 UTC
(In reply to comment #1)
> Richard S, I suspect your bit field changes.  I'll have a look at it
> myself tomorrow if you don't find it first.

Yeah, I expect it is, sorry.  'Fraid I couldn't get the testcase to fail
in a cross compiler though.  At first I was getting a load of warnings
about visiblity not being supported, etc., so I built cross binutils
and pointed configure at them.  That silenced all the warnings but the
cc1plus command still succeeded.  I suspect something important is
still configured out, but I couldn't tell what from a scan of auto-host.h.
Comment 5 Richard Henderson 2012-11-20 16:34:20 UTC
I now suspect you're missing --with-long-double-128, which would have been
auto-detected given alpha glibc headers in --with-sysroot, as I have.

Proposed patch here:
http://gcc.gnu.org/ml/gcc-patches/2012-11/msg01681.html
Comment 6 Richard Sandiford 2012-11-20 19:49:38 UTC
Author: rsandifo
Date: Tue Nov 20 19:49:26 2012
New Revision: 193674

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193674
Log:
gcc/
	PR middle-end/55403
	PR middle-end/55391
	* expmed.c (store_bit_field_1): Use adjust_bitfield_address_size
	rather than adjust_bitfield_address to change the mode of a reference.
	(extract_bit_field_1): Likewise.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/expmed.c
Comment 7 Richard Sandiford 2012-11-20 19:51:06 UTC
Patch applied to trunk.  Thanks for the help.