llvm-project/llvm
Roman Lebedev fde8eb00e1
[InstCombine] visitMaskedMerge(): when unfolding, sanitize undef constants (PR45955)
We can't leave undef vector element constants as-is,
it is a miscompile, so we need to sanitize them.

We have two vectors (C and ~C):
* We can't replace undef with 0 in both of them
* We can't replace undef with 0 in only one of them
* We could replace undef with -1 in both of them
* We could replace undef with -1 in only one(!) of them
* We could replace undef with -1 in one and 0 in another one of them.

Therefore, it seems best to go with the last option, since otherwise
we'd loose knowledge that C and ~C have no common bits set,
which seems more important than preserving partial undef knowledge.

Fixes https://bugs.llvm.org/show_bug.cgi?id=45955
2020-05-17 22:53:03 +03:00
..
benchmarks
bindings Fix go bindings after FixedVectorType -> VectorType change. 2020-05-15 16:37:57 -07:00
cmake [CMake][AIX] Add `-bcdtors:mbr` option when building with IBM XL 2020-05-15 17:34:00 -04:00
docs [AMDGPU] Enable base pointer. 2020-05-17 16:13:55 +05:30
examples StoreInst should store Align, not MaybeAlign 2020-05-15 12:26:58 -07:00
include Revert rGca18ce1a00cd8b7cb7ce0e130440f5ae1ffe86ee "GlobPattern.h - remove unnecessary BitVector.h/StringRef.h includes. NFC" 2020-05-17 18:51:21 +01:00
lib [InstCombine] visitMaskedMerge(): when unfolding, sanitize undef constants (PR45955) 2020-05-17 22:53:03 +03:00
projects
resources
runtimes
test [InstCombine] visitMaskedMerge(): when unfolding, sanitize undef constants (PR45955) 2020-05-17 22:53:03 +03:00
tools Add missing include Host.h in llvm-mc-* fuzzers. NFC. 2020-05-18 02:21:22 +07:00
unittests Revert rGca18ce1a00cd8b7cb7ce0e130440f5ae1ffe86ee "GlobPattern.h - remove unnecessary BitVector.h/StringRef.h includes. NFC" 2020-05-17 18:51:21 +01:00
utils [gn build] Put HAVE_LIBZ and HAVE_ZLIB_H behind llvm_enable_zlib too. 2020-05-15 16:18:56 -04:00
.clang-format
.clang-tidy
.gitattributes
.gitignore
CMakeLists.txt [AIX] Make sure we use export lists for plugins 2020-05-08 14:00:25 -04:00
CODE_OWNERS.TXT
CREDITS.TXT
LICENSE.TXT
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT
configure
llvm.spec.in

README.txt

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.