aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Basic/VirtualFileSystem.cpp
diff options
context:
space:
mode:
authorAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2014-07-15 00:02:32 +0000
committerAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2014-07-15 00:02:32 +0000
commit2152a6c78b762e5bfcef4032067aa127b7ea385f (patch)
tree7c4a5b8b03930ea4cf260dfbc21382053c3aa16d /clang/lib/Basic/VirtualFileSystem.cpp
parent457f73eaeedd73b88f8eef0d3bcdca4185925b0b (diff)
downloadllvm-2152a6c78b762e5bfcef4032067aa127b7ea385f.zip
llvm-2152a6c78b762e5bfcef4032067aa127b7ea385f.tar.gz
llvm-2152a6c78b762e5bfcef4032067aa127b7ea385f.tar.bz2
[DAGCombiner] Avoid calling method 'isShuffleMaskLegal' on illegal vector types.
This patch fixes a crasher in method 'DAGCombiner::visitOR' due to an invalid call to method 'isShuffleMaskLegal'. On x86, method 'isShuffleMaskLegal' always expects a legal vector value type in input. With this patch, we immediately check if the input OR dag node has a legal vector type; we only try to fold a OR dag node into a single shufflevector if we know that the resulting shuffle will have a legal type. This is to avoid calling method 'isShuffleMaskLegal' on a potentially illegal vector value type. Added a new test-case to file 'CodeGen/X86/combine-or.ll' to verify that DAGCombiner doesn't crash in the attempt to check/combine an OR between shuffles with illegal types. llvm-svn: 213020
Diffstat (limited to 'clang/lib/Basic/VirtualFileSystem.cpp')
0 files changed, 0 insertions, 0 deletions