summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* do not store wchar/char16/char32/intmax width/alignment infoChris Lattner2009-11-126-33/+14
| | | | | | | into TargetInfo, just derive this based on the underlying type. This prevents them from getting out of synch, patch by Ken Dyck! llvm-svn: 86976
* 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. :) llvm-svn: 86975
* RegScavenger::enterBasicBlock should always reset register state.Evan Cheng2009-11-122-5/+87
| | | | llvm-svn: 86972
* - 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. llvm-svn: 86969
* Move warning options into DiagnosticOptions.Daniel Dunbar2009-11-125-43/+51
| | | | llvm-svn: 86968
* Avoid comparing string literals.Daniel Dunbar2009-11-121-3/+3
| | | | llvm-svn: 86967
* Move dump-build-information option into DiagnosticOptions.Daniel Dunbar2009-11-123-21/+24
| | | | llvm-svn: 86966
* Use table to separate opcode from operands.Evan Cheng2009-11-121-2/+2
| | | | llvm-svn: 86965
* isLegalICmpImmediate should take a signed integer; code clean up.Evan Cheng2009-11-123-33/+31
| | | | llvm-svn: 86964
* clang-cc: Factor CreateDiagnosticEngine out of main.Daniel Dunbar2009-11-121-36/+50
| | | | llvm-svn: 86963
* clang-cc: -fixit is actually option, not an action, although its use with nonDaniel Dunbar2009-11-121-5/+5
| | | | | | -fsyntax-only is probably untested. llvm-svn: 86962
* Simplify.Daniel Dunbar2009-11-121-9/+0
| | | | llvm-svn: 86961
* 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. llvm-svn: 86960
* PthreadLockChecker doesn't need PreVisitCallExpr() yet. All the current ↵Ted Kremenek2009-11-121-20/+6
| | | | | | logic should be done in PostVisitCallExpr() llvm-svn: 86959
* Add most of the boilerplate logic for a simple pthread_mutux_lock() -> ↵Ted Kremenek2009-11-123-1/+181
| | | | | | pthread_mutex_unlock() checker. We need to add a visitor method to Checker for handling dead symbols in order to detect locks that are not unlocked. llvm-svn: 86958
* Remove obsolete 'struct NullDerefTag'.Ted Kremenek2009-11-122-12/+0
| | | | llvm-svn: 86957
* Use the --with-c-include-dirs configure option.Rafael Espindola2009-11-121-0/+9
| | | | llvm-svn: 86956
* Add the --with-c-include-dirs to llvm's configure.Rafael Espindola2009-11-124-24/+52
| | | | | | The clang patch is next. llvm-svn: 86955
* 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 llvm-svn: 86954
* 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. llvm-svn: 86953
* various fixes to the lattice transfer functions.Chris Lattner2009-11-122-6/+33
| | | | llvm-svn: 86952
* 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. llvm-svn: 86951
* 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. llvm-svn: 86950
* Enhance Checker class (and GRExprEngine) to support PostVisitation for ↵Ted Kremenek2009-11-124-17/+48
| | | | | | CallExprs. No clients (yet). llvm-svn: 86949
* Remove GRExprEngine::EvalCall(). It had a single callsite in GRExprEngine, ↵Ted Kremenek2009-11-122-15/+10
| | | | | | and was easily inlined. llvm-svn: 86948
* Move the utility function UpdateTerminator() from CodePlacementOpt() intoJim Grosbach2009-11-123-62/+63
| | | | | | MachineBasicBlock so other passes can utilize it. llvm-svn: 86947
* 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. llvm-svn: 86945
* Random const correctness, and incidentally use computeDeclContext when buildingJohn McCall2009-11-125-41/+44
| | | | | | a using declaration. llvm-svn: 86942
* 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. llvm-svn: 86941
* Move TokenCache option to PreprocessorOptions.Daniel Dunbar2009-11-123-16/+31
| | | | llvm-svn: 86940
* Switch PTHManager to using diagnostics for most errors.Daniel Dunbar2009-11-124-29/+25
| | | | | | Also, always give errors on a token-cache PTH failure. llvm-svn: 86939
* Simplify.Daniel Dunbar2009-11-121-31/+9
| | | | llvm-svn: 86938
* clang-cc: Refactor ParseInputFollow to clearly split on the two primary cases,Daniel Dunbar2009-11-121-100/+110
| | | | | | | when we are running an AST consumer and when we are just running the preprocessor or parser alone. llvm-svn: 86937
* clang-cc: Factor ReadPCHFile out of ProcessInputFile.Daniel Dunbar2009-11-121-32/+40
| | | | llvm-svn: 86936
* Simplify.Daniel Dunbar2009-11-121-10/+6
| | | | llvm-svn: 86935
* clang-cc: Unify InitializeSourceManager calls.Daniel Dunbar2009-11-121-29/+10
| | | | llvm-svn: 86934
* Add the braces gcc suggested.Daniel Dunbar2009-11-121-5/+8
| | | | llvm-svn: 86933
* Make StoreManager::getSizeInElements() always return DefinedOrUnknownSVal.Zhongxing Xu2009-11-124-10/+10
| | | | llvm-svn: 86932
* Note to self: don't leave debugging statements in the code for four hours.John McCall2009-11-121-2/+0
| | | | llvm-svn: 86931
* Add CreateNUWAdd and CreateNUWSub to complement the existing CreateNSWAdd andNick Lewycky2009-11-121-0/+42
| | | | | | CreateNSWSub functions. llvm-svn: 86930
* should not commit when distracted.Chris Lattner2009-11-121-4/+3
| | | | llvm-svn: 86929
* Make the BranchFolderPass class local to BranchFolding.cpp.Dan Gohman2009-11-122-14/+15
| | | | llvm-svn: 86928
* We now thread some impossible condition information with LVI.Chris Lattner2009-11-121-2/+30
| | | | llvm-svn: 86927
* Minor code cleanups.Dan Gohman2009-11-121-9/+9
| | | | llvm-svn: 86926
* with the new code we can thread non-instruction values. ThisChris Lattner2009-11-122-3/+46
| | | | | | allows us to handle the test10 testcase. llvm-svn: 86924
* this argument can be an arbitrary value, it doesn't need to be an instruction.Chris Lattner2009-11-121-4/+3
| | | | llvm-svn: 86923
* clang-cc: Move non-Consumer action handling to common location, to expose ↵Daniel Dunbar2009-11-121-58/+70
| | | | | | the massive amount of redundancy we have introduced through blind copy-and-paste. llvm-svn: 86922
* Fix PCH/preprocess test to be more useful, and unbreak -E mode with implicitDaniel Dunbar2009-11-122-4/+19
| | | | | | PCH, which I broke. llvm-svn: 86921
* expose edge information and switch j-t to use it.Chris Lattner2009-11-123-2/+27
| | | | llvm-svn: 86920
* Fixed an iteration condition in PreAllocSplitting. This should fix some ↵Lang Hames2009-11-121-1/+1
| | | | | | miscompilations casued by PreAllocSplitting. llvm-svn: 86919
OpenPOWER on IntegriCloud