aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Add AsmPrinter comment flags to machine instructions so that AsmPrinterDavid Greene2009-11-121-0/+24
| | | | | | | can emit extra information in comments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87018 91177308-0d34-0410-b5e6-96231b3b80d8
* Add comment flags so AsmPrinter can output additional information whenDavid Greene2009-11-121-0/+8
| | | | | | | | emitting comments. These flags carry semantic information not otherwise easily derivable from the IR text. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87016 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename registers to break output dependencies in addition to anti-dependencies.David Goodwin2009-11-124-10/+30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87015 91177308-0d34-0410-b5e6-96231b3b80d8
* "Attach debug info with llvm instructions" mode was enabled a month ago. Now ↵Devang Patel2009-11-1210-456/+16
| | | | | | make it permanent and remove old way of inserting intrinsics to encode debug info for line number and scopes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87014 91177308-0d34-0410-b5e6-96231b3b80d8
* Mark DBG_LABEL, EH_LABEL, and GC_LABEL as not-duplicable, sinceDan Gohman2009-11-121-0/+3
| | | | | | | they really are not duplicable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87009 91177308-0d34-0410-b5e6-96231b3b80d8
* Silence a warning on targets with unsigned chars.Benjamin Kramer2009-11-121-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@87002 91177308-0d34-0410-b5e6-96231b3b80d8
* Update TB[BH] layout optimization. Add support for moving the target blockJim Grosbach2009-11-121-33/+115
| | | | | | | | | to directly follow the jump table. Move the layout changes to prior to any constant island handling. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86999 91177308-0d34-0410-b5e6-96231b3b80d8
* Clean up testcase a bit. Simplify case blocks and adjust switch instruction ↵Jim Grosbach2009-11-121-7/+3
| | | | | | to not take an undefined value as input. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86997 91177308-0d34-0410-b5e6-96231b3b80d8
* fix crash in my previous patchNuno Lopes2009-11-121-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86987 91177308-0d34-0410-b5e6-96231b3b80d8
* implement shl, ashr, and lshr methods. shl is not fully implemented as it is ↵Nuno Lopes2009-11-122-0/+49
| | | | | | quite tricky. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86986 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typo in run line.Benjamin Kramer2009-11-121-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86984 91177308-0d34-0410-b5e6-96231b3b80d8
* typoGabor Greif2009-11-121-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86980 91177308-0d34-0410-b5e6-96231b3b80d8
* implement a nice little efficiency hack in the inliner. Since we're nowChris Lattner2009-11-122-14/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | running IPSCCP early, and we run functionattrs interlaced with the inliner, we often (particularly for small or noop functions) completely propagate all of the information about a call to its call site in IPSSCP (making a call dead) and functionattrs is smart enough to realize that the function is readonly (because it is interlaced with inliner). To improve compile time and make the inliner threshold more accurate, realize that we don't have to inline dead readonly function calls. Instead, just delete the call. This happens all the time for C++ codes, here are some counters from opt/llvm-ld counting the number of times calls were deleted vs inlined on various apps: Tramp3d opt: 5033 inline - Number of call sites deleted, not inlined 24596 inline - Number of functions inlined llvm-ld: 667 inline - Number of functions deleted because all callers found 699 inline - Number of functions inlined 483.xalancbmk opt: 8096 inline - Number of call sites deleted, not inlined 62528 inline - Number of functions inlined llvm-ld: 217 inline - Number of allocas merged together 2158 inline - Number of functions inlined 471.omnetpp: 331 inline - Number of call sites deleted, not inlined 8981 inline - Number of functions inlined llvm-ld: 171 inline - Number of functions deleted because all callers found 629 inline - Number of functions inlined Deleting a call is much faster than inlining it, and is insensitive to the size of the callee. :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86975 91177308-0d34-0410-b5e6-96231b3b80d8
* RegScavenger::enterBasicBlock should always reset register state.Evan Cheng2009-11-122-5/+87
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86972 91177308-0d34-0410-b5e6-96231b3b80d8
* - Teach LSR to avoid changing cmp iv stride if it will create an immediate thatEvan Cheng2009-11-124-209/+411
| | | | | | | | | | | | | | | cannot be folded into target cmp instruction. - Avoid a phase ordering issue where early cmp optimization would prevent the later count-to-zero optimization. - Add missing checks which could cause LSR to reuse stride that does not have users. - Fix a bug in count-to-zero optimization code which failed to find the pre-inc iv's phi node. - Remove, tighten, loosen some incorrect checks disable valid transformations. - Quite a bit of code clean up. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86969 91177308-0d34-0410-b5e6-96231b3b80d8
* Use table to separate opcode from operands.Evan Cheng2009-11-121-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86965 91177308-0d34-0410-b5e6-96231b3b80d8
* isLegalICmpImmediate should take a signed integer; code clean up.Evan Cheng2009-11-123-33/+31
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86964 91177308-0d34-0410-b5e6-96231b3b80d8
* CMake: Hopefully unbreak the build by mimicking the changes on theOscar Fuentes2009-11-122-0/+6
| | | | | | | other build system about the new C_INCLUDE_DIRS configure option. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86960 91177308-0d34-0410-b5e6-96231b3b80d8
* Add the --with-c-include-dirs to llvm's configure.Rafael Espindola2009-11-124-24/+52
| | | | | | | | The clang patch is next. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86955 91177308-0d34-0410-b5e6-96231b3b80d8
* CMake: Pass -lm to check_symbol_exists for detecting several mathOscar Fuentes2009-11-122-1/+7
| | | | | | | | | functions like floorf, ceilf, ... Add test for detecting nearbyintf. This change was prompted by test/Transforms/SimplifyLibCalls/floor.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86954 91177308-0d34-0410-b5e6-96231b3b80d8
* use getPredicateOnEdge to fold comparisons through PHI nodes,Chris Lattner2009-11-122-1/+43
| | | | | | | | which implements GCC PR18046. This also gets us 360 more jump threads on 176.gcc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86953 91177308-0d34-0410-b5e6-96231b3b80d8
* various fixes to the lattice transfer functions.Chris Lattner2009-11-122-6/+33
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86952 91177308-0d34-0410-b5e6-96231b3b80d8
* switch jump threading to use getPredicateOnEdge in one placeChris Lattner2009-11-121-10/+13
| | | | | | | | | making the new LVI stuff smart enough to subsume some special cases in the old code. Disable them when LVI is around, the testcase still passes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86951 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new getPredicateOnEdge method which returns more rich information forChris Lattner2009-11-122-23/+93
| | | | | | | | constant constraints. Improve the LVI lattice to include inequality constraints. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86950 91177308-0d34-0410-b5e6-96231b3b80d8
* Move the utility function UpdateTerminator() from CodePlacementOpt() intoJim Grosbach2009-11-123-62/+63
| | | | | | | | MachineBasicBlock so other passes can utilize it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86947 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert 86857. It's causing consumer-typeset to fail, and there's a better ↵Jim Grosbach2009-11-121-7/+4
| | | | | | way to do it forthcoming anyway. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86945 91177308-0d34-0410-b5e6-96231b3b80d8
* Use stubs when we have them, otherwise use code we already have,Eric Christopher2009-11-122-65/+109
| | | | | | | | | otherwise create a stub. Add a test to make sure we don't create extraneous stubs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86941 91177308-0d34-0410-b5e6-96231b3b80d8
* Add the braces gcc suggested.Daniel Dunbar2009-11-121-5/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86933 91177308-0d34-0410-b5e6-96231b3b80d8
* Add CreateNUWAdd and CreateNUWSub to complement the existing CreateNSWAdd andNick Lewycky2009-11-121-0/+42
| | | | | | | CreateNSWSub functions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86930 91177308-0d34-0410-b5e6-96231b3b80d8
* should not commit when distracted.Chris Lattner2009-11-121-4/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86929 91177308-0d34-0410-b5e6-96231b3b80d8
* Make the BranchFolderPass class local to BranchFolding.cpp.Dan Gohman2009-11-122-14/+15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86928 91177308-0d34-0410-b5e6-96231b3b80d8
* We now thread some impossible condition information with LVI.Chris Lattner2009-11-121-2/+30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86927 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor code cleanups.Dan Gohman2009-11-121-9/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86926 91177308-0d34-0410-b5e6-96231b3b80d8
* with the new code we can thread non-instruction values. ThisChris Lattner2009-11-122-3/+46
| | | | | | | allows us to handle the test10 testcase. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86924 91177308-0d34-0410-b5e6-96231b3b80d8
* this argument can be an arbitrary value, it doesn't need to be an instruction.Chris Lattner2009-11-121-4/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86923 91177308-0d34-0410-b5e6-96231b3b80d8
* expose edge information and switch j-t to use it.Chris Lattner2009-11-123-2/+27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86920 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed an iteration condition in PreAllocSplitting. This should fix some ↵Lang Hames2009-11-121-1/+1
| | | | | | miscompilations casued by PreAllocSplitting. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86919 91177308-0d34-0410-b5e6-96231b3b80d8
* move some stuff into DEBUG's and turn on lazy-value-info forChris Lattner2009-11-122-4/+6
| | | | | | | the basic.ll testcase. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86918 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typo, cleanup whitespace.Eric Christopher2009-11-121-35/+35
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86917 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not use StringRef in DebugInfo interface. Devang Patel2009-11-124-34/+46
| | | | | | | | This allows StringRef to skip controversial if(str) check in constructor. Buildbots, wait for corresponding clang and llvm-gcc FE check-ins! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86914 91177308-0d34-0410-b5e6-96231b3b80d8
* Tail merge at any size when there are two potentials blocks and oneDan Gohman2009-11-122-10/+61
| | | | | | | can be made to fall through into the other. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86909 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't mark a call as potentially throwing if the function it's calling has theBill Wendling2009-11-111-1/+21
| | | | | | | "nounwind" attribute. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86897 91177308-0d34-0410-b5e6-96231b3b80d8
* A real solution for the first part of PR5445Bruno Cardoso Lopes2009-11-111-1/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86895 91177308-0d34-0410-b5e6-96231b3b80d8
* make LazyValueInfo actually to some stuff. This isn't very tested but improvesChris Lattner2009-11-111-8/+152
| | | | | | | strswitch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86889 91177308-0d34-0410-b5e6-96231b3b80d8
* pass TD into a SimplifyCmpInst call. Add another case thatChris Lattner2009-11-111-3/+24
| | | | | | | uses LVI info when -enable-jump-threading-lvi is passed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86886 91177308-0d34-0410-b5e6-96231b3b80d8
* Promote MergePotentialsElt and SameTailElt to be regular classesDan Gohman2009-11-112-58/+107
| | | | | | | | instead of typedefs for std::pair. This simplifies the type of SameTails, which previously was std::vector<std::pair<std::vector<std::pair<unsigned, MachineBasicBlock *> >::iterator, MachineBasicBlock::iterator> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86885 91177308-0d34-0410-b5e6-96231b3b80d8
* x86 users can now return arbitrary sized structs. Structs too large to fit ↵Kenneth Uildriks2009-11-113-67/+228
| | | | | | in return registers will be returned through a hidden sret parameter introduced during SelectionDAG construction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86876 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert this line of 86871.Dan Gohman2009-11-111-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86875 91177308-0d34-0410-b5e6-96231b3b80d8
* If doesSupportDebugInformation() is false then do not try to emit dwarf ↵Devang Patel2009-11-111-0/+3
| | | | | | debug info. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86874 91177308-0d34-0410-b5e6-96231b3b80d8
* Check in the changes to this file too.Dan Gohman2009-11-111-3/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86873 91177308-0d34-0410-b5e6-96231b3b80d8