Go to file
Craig Topper 74c7d6be28 [X86] Rewrite to the vXi1 subvector insertion code to not rely on the value of bits that might be undef
The previous code tried to do a trick where we would extract the subvector from the location we were inserting. Then xor that with the new value. Take the xored value and clear out the bits above the subvector size. Then shift that xored subvector to the insert location. And finally xor that with the original vector. Since the old subvector was used in both xors, this would leave just the new subvector at the inserted location. Since the surrounding bits had been zeroed no other bits of the original vector would be modified.

Unfortunately, if the old subvector came from undef we might aggressively propagate the undef. Then we end up with the XORs not cancelling because they aren't using the same value for the two uses of the old subvector. @bkramer gave me a case that demonstrated this, but we haven't reduced it enough to make it easily readable to see what's happening.

This patch uses a safer, but more costly approach. It isolate the bits above the insertion and bits below the insert point and ORs those together leaving 0 for the insertion location. Then widens the subvector with 0s in the upper bits, shifts it into position with 0s in the lower bits. Then we do another OR.

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

llvm-svn: 373495
2019-10-02 17:47:09 +00:00
clang Type - silence static analyzer getAs<> null dereference warnings. NFCI. 2019-10-02 16:03:36 +00:00
clang-tools-extra Add the misc-init-local-variables check. 2019-10-02 17:18:57 +00:00
compiler-rt [CMake] Fix the value of `config.target_cflags` for non-macOS Apple platforms. Attempt #3. 2019-10-01 23:08:18 +00:00
debuginfo-tests Make nrvo-string test more robust. 2019-06-27 20:38:37 +00:00
libc Add a director, along with README.txt and LICENSE.txt, for libc. 2019-09-16 21:39:08 +00:00
libclc travis: Add LLVM 9 build 2019-09-27 05:58:15 +00:00
libcxx [libc++] Use PRIVATE instead of PUBLIC when linking against system libs 2019-10-02 16:51:42 +00:00
libcxxabi [libc++abi] Remove uses of C++ headers when possible 2019-10-01 18:43:02 +00:00
libunwind Unwind: avoid warning about unused typedef 2019-09-20 20:46:33 +00:00
lld Add missing REQUIRES: arm. 2019-10-01 17:35:56 +00:00
lldb [lldb] Fix evaluation of nested classes with parent from other CU 2019-10-02 13:46:17 +00:00
llgo IR: Support parsing numeric block ids, and emit them in textual output. 2019-03-22 18:27:13 +00:00
llvm [X86] Rewrite to the vXi1 subvector insertion code to not rely on the value of bits that might be undef 2019-10-02 17:47:09 +00:00
openmp [OpenMP] FreeBSD address check if mapped more native 2019-09-28 19:01:59 +00:00
parallel-libs Fix typos throughout the license files that somehow I and my reviewers 2019-01-21 09:52:34 +00:00
polly [Alignment][NFC] Remove AllocaInst::setAlignment(unsigned) 2019-09-30 13:34:44 +00:00
pstl [pstl] Allow customizing whether per-TU insulation is provided 2019-08-13 12:49:00 +00:00
.arcconfig Update monorepo .arcconfig with new project callsign. 2019-01-31 14:34:59 +00:00
.clang-format Add .clang-tidy and .clang-format files to the toplevel of the 2019-01-29 16:43:16 +00:00
.clang-tidy Disable tidy checks with too many hits 2019-02-01 11:20:13 +00:00
.git-blame-ignore-revs Add LLDB reformatting to .git-blame-ignore-revs 2019-09-04 09:31:55 +00:00
.gitignore Add a newline at the end of the file 2019-09-04 06:33:46 +00:00
README.md

README.md

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.