Stack Coloring: We have code that checks that all of the uses of allocas
authorNadav Rotem <nrotem@apple.com>
Thu, 13 Sep 2012 12:38:37 +0000 (12:38 +0000)
committerNadav Rotem <nrotem@apple.com>
Thu, 13 Sep 2012 12:38:37 +0000 (12:38 +0000)
commit0cd19b93017fcaba737b15ea4da39c460feb5670
treec617b980559e63ac861c6ae97eaccc43fc89ddd9
parent2d9eb72178af8e79dc6432cd1b7d29bde16da1b9
Stack Coloring: We have code that checks that all of the uses of allocas
are within the lifetime zone. Sometime legitimate usages of allocas are
hoisted outside of the lifetime zone. For example, GEPS may calculate the
address of a member of an allocated struct. This commit makes sure that
we only check (abort regions or assert) for instructions that read and write
memory using stack frames directly. Notice that by allowing legitimate
usages outside the lifetime zone we also stop checking for instructions
which use derivatives of allocas. We will catch less bugs in user code
and in the compiler itself.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163791 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/StackColoring.cpp
test/CodeGen/X86/StackColoring.ll