LLVM backend for 6502
Go to file
Chandler Carruth e1361ec325 Teach the AllocaPromoter which is wrapped around the SSAUpdater
infrastructure to do promotion without a domtree the same smarts about
looking through GEPs, bitcasts, etc., that I just taught mem2reg about.
This way, if SROA chooses to promote an alloca which still has some
noisy instructions this code can cope with them.

I've not used as principled of an approach here for two reasons:
1) This code doesn't really need it as we were already set up to zip
   through the instructions used by the alloca.
2) I view the code here as more of a hack, and hopefully a temporary one.

The SSAUpdater path in SROA is a real sore point for me. It doesn't make
a lot of architectural sense for many reasons:
- We're likely to end up needing the domtree anyways in a subsequent
  pass, so why not compute it earlier and use it.
- In the future we'll likely end up needing the domtree for parts of the
  inliner itself.
- If we need to we could teach the inliner to preserve the domtree. Part
  of the re-work of the pass manager will allow this to be very powerful
  even in large SCCs with many functions.
- Ultimately, computing a domtree has gotten significantly faster since
  the original SSAUpdater-using code went into ScalarRepl. We no longer
  use domfrontiers, and much of domtree is lazily done based on queries
  rather than eagerly.
- At this point keeping the SSAUpdater-based promotion saves a total of
  0.7% on a build of the 'opt' tool for me. That's not a lot of
  performance given the complexity!

So I'm leaving this a bit ugly in the hope that eventually we just
remove all of this nonsense.

I can't even readily test this because this code isn't reachable except
through SROA. When I re-instate the patch that fast-tracks allocas
already suitable for promotion, I'll add a testcase there that failed
before this change. Before that, SROA will fix any test case I give it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187347 91177308-0d34-0410-b5e6-96231b3b80d8
2013-07-29 09:06:53 +00:00
autoconf Remove dead or useless header checks from cmake and autoconf 2013-07-26 16:54:23 +00:00
bindings
cmake Partial revert of 187310; it seems MSVC 10 still spits out this warning, but MSVC 11 does not. 2013-07-28 18:04:26 +00:00
docs Use pipefail when available. 2013-07-26 22:32:58 +00:00
examples Adding example source to support MCJIT/Kaleidoscope blog posts. 2013-07-22 18:47:24 +00:00
include Fix -Wdocumentation warnings. 2013-07-28 23:43:28 +00:00
lib Teach the AllocaPromoter which is wrapped around the SSAUpdater 2013-07-29 09:06:53 +00:00
projects [PowerPC] Support powerpc64le as a syntax-checking target. 2013-07-26 01:35:43 +00:00
runtime Remove dead code from the makefile build system. 2013-07-25 20:25:31 +00:00
test Don't vectorize when the attribute NoImplicitFloat is used. 2013-07-29 05:13:00 +00:00
tools SimplifyCFG: Use parallel-and and parallel-or mode to consolidate branch conditions 2013-07-27 00:01:07 +00:00
unittests [APFloat] Make all arithmetic operations with NaN produce positive NaNs. 2013-07-27 21:49:25 +00:00
utils Remove use of sprintf added to X86 disassembler tablegen code. Send message with instruction name to errs() instead and use a generic message for the llvm_unreachable. Consistent with other places in this file. 2013-07-28 21:28:02 +00:00
.arcconfig
.gitignore
CMakeLists.txt Remove the mblaze backend from llvm. 2013-07-25 18:55:05 +00:00
CODE_OWNERS.TXT
configure Regenerate. 2013-07-26 17:13:47 +00:00
CREDITS.TXT
LICENSE.TXT
llvm.spec.in
LLVMBuild.txt
Makefile
Makefile.common
Makefile.config.in
Makefile.rules Remove dead code from the makefile build system. 2013-07-25 20:25:31 +00:00
README.txt

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

This directory and its subdirectories contain source code for the Low Level
Virtual Machine, 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're writing a package for LLVM, see docs/Packaging.rst for our
suggestions.