[SystemZ] Check for presence of vector support in SystemZISelLowering
authorJonas Paulsson <paulsson@linux.vnet.ibm.com>
Fri, 7 Apr 2017 12:35:11 +0000 (12:35 +0000)
committerJonas Paulsson <paulsson@linux.vnet.ibm.com>
Fri, 7 Apr 2017 12:35:11 +0000 (12:35 +0000)
commitcad72efee66509040febd634088b1360dc428be3
treebba61fe1fa9e77823f08de1010f7a767a8c48df5
parent16100c637ee238b4a0372b379ac31374fd9c1e24
[SystemZ]  Check for presence of vector support in SystemZISelLowering

A test case was found with llvm-stress that caused DAGCombiner to crash
when compiling for an older subtarget without vector support.

SystemZTargetLowering::combineTruncateExtract() should do nothing for older
subtargets.

This check was placed in canTreatAsByteVector(), which also helps in a few
other places.

Review: Ulrich Weigand
llvm-svn: 299763
llvm/lib/Target/SystemZ/SystemZISelLowering.cpp
llvm/lib/Target/SystemZ/SystemZISelLowering.h
llvm/test/CodeGen/SystemZ/DAGCombine_trunc_extract.ll [new file with mode: 0644]