1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00

[CodeGen] Do not allow opt-bisect-limit to skip ScalarizeMaskedMemIntrin.

Summary:
The pass is supposed to scalarize such intrinsics if the target does not support
them natively, so if the scalarization does not happen instruction selection
crashes due to inability to lower these intrinsics.

Reviewers: andrew.w.kaylor, craig.topper

Reviewed By: andrew.w.kaylor

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D45947

llvm-svn: 330700
This commit is contained in:
Andrei Elovikov 2018-04-24 09:24:29 +00:00
parent 26e820bc4d
commit ea1efd32d0
2 changed files with 5 additions and 3 deletions

View File

@ -586,9 +586,6 @@ static void scalarizeMaskedScatter(CallInst *CI) {
}
bool ScalarizeMaskedMemIntrin::runOnFunction(Function &F) {
if (skipFunction(F))
return false;
bool EverMadeChange = false;
TTI = &getAnalysis<TargetTransformInfoWrapperPass>().getTTI(F);

View File

@ -1,6 +1,11 @@
; RUN: llc -O0 -mtriple=x86_64-unknown-linux-gnu -mattr=+sse,+sse2 < %s -o /dev/null
; pr33001 - Check that llc doesn't crash when running with O0 option.
; RUN: llc -O2 -opt-bisect-limit=0 -mtriple=x86_64-unknown-linux-gnu -mattr=+sse,+sse2 < %s -o /dev/null
; Check that llc doesn't crash due to ScalarizeMaskedMemIntring not being run
; because of opt-bisect-limit that in turn causes crash in instruction selection
; for unsupported gather/scatter.
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"