llvm-project/llvm
George Burgess IV 1b1fef30d0 [MemorySSA] Fix bugs in walker; refactor unittests a bit.
This patch fixes two somewhat related bugs in MemorySSA's caching
walker. These bugs were found because D19695 brought up the problem
that we'd have defs cached to themselves, which is incorrect.

The bugs this fixes are:

- We would sometimes skip the nearest clobber of a MemoryAccess, because
  we would query our cache for a given potential clobber before
  checking if the potential clobber is the clobber we're looking for.
  The cache entry for the potential clobber would point to the nearest
  clobber *of the potential clobber*, so if that was a cache hit, we'd
  ignore the potential clobber entirely.

- There are times (sometimes in DFS, sometimes in the getClobbering...
  functions) where we would insert cache entries that say a def
  clobbers itself.

There's a bit of common code between the fixes for the bugs, so they
aren't split out into multiple commits.

This patch also adds a few unit tests, and refactors existing tests a
bit to reduce the duplication of setup code.

llvm-svn: 268087
2016-04-29 18:42:55 +00:00
..
bindings Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
cmake Unify XDEBUG and EXPENSIVE_CHECKS (into the latter), and add an option to the cmake build to enable them. 2016-04-29 15:22:48 +00:00
docs Remove stale documentation on -no-aa 2016-04-29 03:01:49 +00:00
examples Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
include Put PDB parsing code into a pdb namespace. 2016-04-29 17:28:47 +00:00
lib [MemorySSA] Fix bugs in walker; refactor unittests a bit. 2016-04-29 18:42:55 +00:00
projects
resources
test [ValueTracking] matchSelectPattern needs to be more careful around FP 2016-04-29 18:40:34 +00:00
tools Put PDB parsing code into a pdb namespace. 2016-04-29 17:28:47 +00:00
unittests [MemorySSA] Fix bugs in walker; refactor unittests a bit. 2016-04-29 18:42:55 +00:00
utils TableGen: Produce CoveredBySubRegs summary for register classes 2016-04-28 03:07:11 +00:00
.arcconfig
.clang-format
.clang-tidy Don't use misc-unused-parameters check on LLVM. 2016-04-13 08:58:52 +00:00
.gitignore
CMakeLists.txt Unify XDEBUG and EXPENSIVE_CHECKS (into the latter), and add an option to the cmake build to enable them. 2016-04-29 15:22:48 +00:00
CODE_OWNERS.TXT Update owners to reflect recent changes 2016-04-01 20:40:49 +00:00
CREDITS.TXT Add credit [Test commit] 2016-04-29 14:52:12 +00:00
LICENSE.TXT Update copyright year to 2016. 2016-03-30 22:41:06 +00:00
LLVMBuild.txt
README.txt
configure
llvm.spec.in

README.txt

Low Level Virtual Machine (LLVM)
================================

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.