[llvm-bugs] [Bug 43916] New: [X86] After r361815, Assertion failed: (isSimple() && "Expected a SimpleValueType!"), function getSimpleVT, file include/llvm/CodeGen/ValueTypes.h, line 253.

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Nov 6 04:19:45 PST 2019


https://bugs.llvm.org/show_bug.cgi?id=43916

            Bug ID: 43916
           Summary: [X86] After r361815, Assertion failed: (isSimple() &&
                    "Expected a SimpleValueType!"), function getSimpleVT,
                    file include/llvm/CodeGen/ValueTypes.h, line 253.
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: dimitry at andric.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org

As reported in https://bugs.freebsd.org/241747, building a recent version of
OpenSSL with clang 9.0.0 targeting sandybridge results in an assertion:

Assertion failed: (isSimple() && "Expected a SimpleValueType!"), function
getSimpleVT, file /usr/src/contrib/llvm/include/llvm/CodeGen/ValueTypes.h, line
253.
Stack dump:
0.      Program arguments: clang -cc1 -triple x86_64-unknown-freebsd13.0
-emit-obj -mnoexecstack -disable-free -main-file-name ecp_nistp521.c
-mrelocation-model pic -pic-level 2 -mthread-model posix -mdisable-fp-elim
-relaxed-aliasing -masm-verbose -mconstructor-aliases -munwind-tables
-fuse-init-array -target-cpu sandybridge -dwarf-column-info
-debugger-tuning=gdb -coverage-notes-file
/usr/ports/security/openssl111/work/openssl-1.1.1d/crypto/ec/ecp_nistp521.gcno
-D L_ENDIAN -D OPENSSL_PIC -D OPENSSL_CPUID_OBJ -D OPENSSL_IA32_SSE2 -D
OPENSSL_BN_ASM_MONT -D OPENSSL_BN_ASM_MONT5 -D OPENSSL_BN_ASM_GF2m -D SHA1_ASM
-D SHA256_ASM -D SHA512_ASM -D KECCAK1600_ASM -D RC4_ASM -D MD5_ASM -D
VPAES_ASM -D GHASH_ASM -D ECP_NISTZ256_ASM -D X25519_ASM -D POLY1305_ASM -D
OPENSSLDIR="/usr/local/openssl" -D ENGINESDIR="/usr/local/lib/engines-1.1" -D
_THREAD_SAFE -D _REENTRANT -D NDEBUG -O2 -ferror-limit 19 -fmessage-length 0
-pthread -stack-protector 2 -fobjc-runtime=gnustep -fdiagnostics-show-option
-fcolor-diagnostics -vectorize-loops -vectorize-slp -faddrsig -x c
ecp_nistp521-2ed9e6.c 
1.      <eof> parser at end of file
2.      Code generation
3.      Running pass 'Function Pass Manager' on module 'ecp_nistp521-2ed9e6.c'.
4.      Running pass 'X86 DAG->DAG Instruction Selection' on function
'@point_add'

Bisection shows this regressed with https://reviews.llvm.org/rL361815 ("[x86]
fix 256-bit vector store splitting to honor 'volatile'") by Sanjay Patel.

Minimized test case:

// clang -cc1 -triple x86_64-- -S -target-cpu sandybridge -O1 -w -vectorize-slp
ecp_nistp521-min.c
a() {
  b();
  __uint128_t *c = b;
  int *d = a;
  c[0] += -d[0];
  c[1] += -d[1];
}

It looks like it only asserts when CPUs are targeted which support AVX, but not
AVX2.  E.g. -target-cpu core-avx2 works, while core-avx-i, corei7-avx and
sandybridge all assert.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20191106/d249074d/attachment.html>


More information about the llvm-bugs mailing list