gcc 5.4.0-6ubuntu1~16.04.4 internal compiler error: in simplify_binary_operation_1, at simplify-rtx.c:3619

Bug #1673434 reported by Colin Ian King
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gcc
Fix Released
Medium
gcc-5 (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

When building stress-ng (from git://kernel.ubuntu.com/cking/stress-ng) the PPA builder for Xenial with gcc 5.4.0-6ubuntu1~16.04.4 on ppc64el breaks with an internal compiler error when building vector math code with __int128_t types.

cc -g -O3 -fstack-protector-strong -Wformat -Werror=format-security -Wall -Wextra -DVERSION="0.07.25" -O2 -std=gnu99 -DHAVE_APPARMOR -DHAVE_LIB_BSD -DHAVE_LIB_Z -DHAVE_LIB_CRYPT -DHAVE_LIB_RT -DHAVE_LIB_PTHREAD -DHAVE_LIB_SCTP -DHAVE_LIB_AIO -DHAVE_KEYUTILS_H -DHAVE_XATTR_H -DHAVE_SECCOMP_H -DHAVE_SYS_CAP_H -DHAVE_FLOAT_DECIMAL -DHAVE_VECMATH -DHAVE_ATOMIC -DHAVE_ASM_NOP -fno-builtin -c -o stress-vecmath.o stress-vecmath.c
stress-vecmath.c: In function ‘stress_vecmath’:
stress-vecmath.c:181:1: internal compiler error: in simplify_binary_operation_1, at simplify-rtx.c:3619
 }
 ^

The source code that trips this issue: http://kernel.ubuntu.com/git/cking/stress-ng.git/tree/stress-vecmath.c

This builds OK on Yakkety upwards.

Attached is the full build log from the PPA.

Revision history for this message
Colin Ian King (colin-king) wrote :
Revision history for this message
Anton Blanchard (anton-samba) wrote :

Reduced test case:

typedef __uint128_t vint128_t __attribute__((vector_size(16)));
vint128_t z;
int x, y;

void fn2(void);

void fn1(void)
{
        vint128_t c;
        y = 1000;
        for (; y; y--) {
                c = c ^ x;
                z -= c;
                z ^= x;
                c = c ^ x;
        }

        fn2();
}

Revision history for this message
Anton Blanchard (anton-samba) wrote :

Build with gcc -g -O2

Revision history for this message
Matthias Klose (doko) wrote :

work around is to build with -O1

Matthias Klose (doko)
Changed in gcc-5 (Ubuntu):
importance: Undecided → Medium
status: New → Confirmed
Changed in gcc:
importance: Unknown → Medium
status: Unknown → New
Changed in gcc:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.