aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix indentation. Extracted from a patch by Sami Liedes!Rafael Espindola2012-12-311-32/+32
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171300 91177308-0d34-0410-b5e6-96231b3b80d8
* Style fixes in llvm-readobj.cpp. Extracted from a patch by Sami Liedes!Rafael Espindola2012-12-311-28/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171299 91177308-0d34-0410-b5e6-96231b3b80d8
* add support for PHI nodes to ObjectSizeOffsetVisitorNuno Lopes2012-12-312-3/+68
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171298 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove dead method.Bill Wendling2012-12-311-6/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171295 91177308-0d34-0410-b5e6-96231b3b80d8
* Add some comparison operators to compare the Attribute object with the ↵Bill Wendling2012-12-312-3/+15
| | | | | | AttrKind value. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171294 91177308-0d34-0410-b5e6-96231b3b80d8
* docs: Fix FIXMESean Silva2012-12-312-4/+5
| | | | | | | I actually made a think-o when writing this FIXME since I wrote LangRef but it should actually have said WritingAnLLVMBackend. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171293 91177308-0d34-0410-b5e6-96231b3b80d8
* Switch this code to a more idiomatic double using namespace directive.Chandler Carruth2012-12-313-6/+3
| | | | | | | | Fix a truly odd namespace qualifier that was flat out wrong in the process. The fully qualified namespace would have been llvm::sys::TimeValue, llvm::TimeValue makes no sense. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171292 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete a cut/paste-o from r171290. Very sorry about the noise.Chandler Carruth2012-12-311-1/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171291 91177308-0d34-0410-b5e6-96231b3b80d8
* Suppress a MSVC warning complaining about the code working as intended.Chandler Carruth2012-12-311-0/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171290 91177308-0d34-0410-b5e6-96231b3b80d8
* Begin sketching out the process interface.Chandler Carruth2012-12-316-1/+130
| | | | | | | | | | | | | | | | | | | | | | | The coding style used here is not LLVM's style because this is modeled after a Boost interface and thus done in the style of a candidate C++ standard library interface. I'll probably end up proposing it as a standard C++ library if it proves to be reasonably portable and useful. This is just the most basic parts of the interface -- getting the process ID out of it. However, it helps sketch out some of the boiler plate such as the base class, derived class, shared code, and static factory function. It also introduces a unittest so that I can incrementally ensure this stuff works. However, I've not even compiled this code for Windows yet. I'll try to fix any Windows fallout from the bots, and if I can't fix it I'll revert and get someone on Windows to help out. There isn't a lot more that is mandatory, so soon I'll switch to just stubbing out the Windows side and get Michael Spencer to help with implementation as he can test it directly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171289 91177308-0d34-0410-b5e6-96231b3b80d8
* Start sketching out a roadmap for better subprocess management in theChandler Carruth2012-12-311-136/+140
| | | | | | | | | | | | | | | | | | | | | LLVM libraries. Also, clean up the doxygen and formatting of the existing interfaces. With this change I'm calling the existing interface "legacy" because I'd like to replace it with something much better. My end goal is to expose a common set of interfaces for inspecting various properties of a process, and implementations to expose those both for the current process and for child processes. This will also expose more rich interfaces for spawning and controling a subprocess, notably to use system calls like wait3 and wait4 where available and gather detailed resource usage stats about the subprocess. My plan (discussed with Michael Spencer on IRC) is to base this loosely around the proposed Boost.Process interface, but to implement a relatively small subset of that functionality based around the needs of LLVM, Clang, the Clang driver, etc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171285 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix LICM's memory promotion optimization to preserve TBAA tags whenChris Lattner2012-12-312-8/+58
| | | | | | | | promoting a store in a loop. This was noticed when working on PR14753, but isn't directly related. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171281 91177308-0d34-0410-b5e6-96231b3b80d8
* teach instcombine to preserve TBAA tag when merging two stores, part ofChris Lattner2012-12-312-0/+41
| | | | | | | PR14753 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171279 91177308-0d34-0410-b5e6-96231b3b80d8
* Grammo.Jakub Staszak2012-12-311-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171272 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the getAttributesAtIndex and getNumAttrs methods in favor of using ↵Bill Wendling2012-12-315-32/+9
| | | | | | the getAttrSomewhere predicate. This prevents the uses of 'Attribute' as a collection of attributes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171271 91177308-0d34-0410-b5e6-96231b3b80d8
* Transform (A == C1 || A == C2) into (A & ~(C1 ^ C2)) == C1Jakub Staszak2012-12-312-0/+23
| | | | | | | | if C1 and C2 differ only with one bit. Fixes PR14708. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171270 91177308-0d34-0410-b5e6-96231b3b80d8
* Support ppcf128 in SelectionDAG::getConstantFPHal Finkel2012-12-302-1/+17
| | | | | | | | Fixes pr14751. Patch by Kai; Thanks! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171261 91177308-0d34-0410-b5e6-96231b3b80d8
* convert a bunch of callers from DataLayout::getIndexedOffset() to ↵Nuno Lopes2012-12-308-83/+30
| | | | | | | | | GEP::accumulateConstantOffset(). The later API is nicer than the former, and is correct regarding wrap-around offsets (if anyone cares). There are a few more places left with duplicated code, which I'll remove soon. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171259 91177308-0d34-0410-b5e6-96231b3b80d8
* Documentation: add a section to prevent spurious test failures like the oneDmitri Gribenko2012-12-301-0/+37
| | | | | | | fixed in r171243. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171258 91177308-0d34-0410-b5e6-96231b3b80d8
* Use the predicate methods off of AttributeSet instead of Attribute.Bill Wendling2012-12-309-38/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171257 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the Function::getRetAttributes method in favor of using the ↵Bill Wendling2012-12-307-27/+19
| | | | | | AttributeSet accessor method. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171256 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove Function::getParamAttributes and use the AttributeSet accessor ↵Bill Wendling2012-12-306-34/+31
| | | | | | methods instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171255 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the Function::getFnAttributes method in favor of using the AttributeSetBill Wendling2012-12-3039-111/+186
| | | | | | | | | | directly. This is in preparation for removing the use of the 'Attribute' class as a collection of attributes. That will shift to the AttributeSet class instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171253 91177308-0d34-0410-b5e6-96231b3b80d8
* s/hasAttribute/contains/g to be more consistent with other method names.Bill Wendling2012-12-303-5/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171252 91177308-0d34-0410-b5e6-96231b3b80d8
* LoopVectorizer: Fix a bug in the code that updates the loop exiting block.Nadav Rotem2012-12-302-0/+42
| | | | | | | | | | | LCSSA PHIs may have undef values. The vectorizer updates values that are used by outside users such as PHIs. The bug happened because undefs are not loop values. This patch handles these PHIs. PR14725 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171251 91177308-0d34-0410-b5e6-96231b3b80d8
* Tests: rewrite 'opt ... %s' to 'opt ... < %s' so that opt does not emit a ↵Dmitri Gribenko2012-12-3027-30/+30
| | | | | | | | | ModuleID This is done to avoid odd test failures, like the one fixed in r171243. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171250 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a few more c'tors:Bill Wendling2012-12-302-5/+29
| | | | | | | | | | | | | | | | * One that accepts a single Attribute::AttrKind. * One that accepts an Attribute::AttrKind plus a list of values. This is for attributes defined like this: #1 = attributes { align = 4 } * One that accepts a string, for target-specific attributes like this: #2 = attributes { "cpu=cortex-a8" } git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171249 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a check to the test ↵Dmitri Gribenko2012-12-301-1/+3
| | | | | | | | | | Analysis/ScalarEvolution/2010-09-03-RequiredTransitive.ll This test did not test anything at all (except for opt crashing, but that was not the reason why it was added). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171248 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a few (as yet unused) query methods to determine if the attribute that'sBill Wendling2012-12-302-0/+31
| | | | | | | | stored here is of a certain kind. This is in preparation for when an Attribute object represents a single attribute, instead of a bitmask of attributes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171247 91177308-0d34-0410-b5e6-96231b3b80d8
* Tests: rewrite 'opt ... %s' to 'opt ... < %s' so that opt does not emit a ↵Dmitri Gribenko2012-12-3048-49/+49
| | | | | | | | | ModuleID This is done to avoid odd test failures, like the one fixed in r171243. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171246 91177308-0d34-0410-b5e6-96231b3b80d8
* Uniquify the AttributeImpl based on the Constant pointer, since those areBill Wendling2012-12-302-5/+3
| | | | | | | | | | already uniquified. Note: This will be expanded in the future to add more than just one pointer value. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171245 91177308-0d34-0410-b5e6-96231b3b80d8
* s/Raw/getBitMask/g to be more in line with current naming conventions. This ↵Bill Wendling2012-12-305-23/+24
| | | | | | method won't be sticking around. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171244 91177308-0d34-0410-b5e6-96231b3b80d8
* llvm/test/Transforms/GVN/null-aliases-nothing.ll: Fix a RUN line not to emit ↵NAKAMURA Takumi2012-12-301-1/+1
| | | | | | | | ModuleID. Larry Evans reported it fails if source tree contains "load", like "download". git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171243 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove intrinsic specific instructions for (V)SQRTPS/PD. Instead lower to ↵Craig Topper2012-12-293-26/+7
| | | | | | target-independent ISD nodes and use the existing patterns for those. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171237 91177308-0d34-0410-b5e6-96231b3b80d8
* Merge similar functionality using a nested switch.Craig Topper2012-12-291-8/+39
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171229 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove intrinsic specific instructions for SSE/SSE2/AVX floating point ↵Craig Topper2012-12-293-74/+29
| | | | | | max/min instructions. Lower them to target specific nodes and use those patterns instead. This also allows them to be commuted if UnsafeFPMath is enabled. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171227 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify code, no functionality change.Jakub Staszak2012-12-291-19/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171226 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete executive bit on ./lib/Target/Hexagon/HexagonAsmPrinter.h.Jakub Staszak2012-12-291-0/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171225 91177308-0d34-0410-b5e6-96231b3b80d8
* Use a 'Constant' object instead of a bit field to store the attribute data.Bill Wendling2012-12-292-8/+19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171221 91177308-0d34-0410-b5e6-96231b3b80d8
* Use the accessor method instead of the raw ivar to get the bits.Bill Wendling2012-12-291-5/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171220 91177308-0d34-0410-b5e6-96231b3b80d8
* Nuke some dead code that snuck in some how. I thought I had alreadyChandler Carruth2012-12-281-5/+0
| | | | | | | deleted this, but apparantly not. Charmingly, Clang didn't warn on it but GCC did. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171197 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a stunning oversight in the inline cost analysis. It was neverChandler Carruth2012-12-282-4/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | propagating one of the values it simplified to a constant across a myriad of instructions. Notably, ptrtoint instructions when we had a constant pointer (say, 0) didn't propagate that, blocking a massive number of down-stream optimizations. This was uncovered when investigating why we fail to inline and delete the boilerplate in: void f() { std::vector<int> v; v.push_back(1); } It turns out most of the efforts I've made thus far to improve the analysis weren't making it far purely because of this. After this is fixed, the store-to-load forwarding patch enables LLVM to optimize the above to an empty function. We still can't nuke a second push_back, but for different reasons. There is a very real chance this will cause somewhat noticable changes in inlining behavior, so please let me know if you see regressions (or improvements!) because of this patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171196 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach the inline cost analysis about calls that can be simplified andChandler Carruth2012-12-282-11/+125
| | | | | | | | | | | | | | | | | | | | | how to propagate constants through insert and extract value instructions. With the recent improvements to instsimplify, this allows inline cost analysis to constant fold through intrinsic functions, including notably the with.overflow intrinsic math routines which often show up inside of STL abstractions. This is yet another piece in the puzzle of breaking down the code for: void f() { std::vector<int> v; v.push_back(1); } But it still isn't enough. There are a pile of bugs in inline cost still blocking this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171195 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach instsimplify to use the constant folder where appropriate forChandler Carruth2012-12-283-10/+83
| | | | | | | | constant folding calls. Add the initial tests for this which show that now instsimplify can simplify blindingly obvious code patterns expressed with both intrinsics and library calls. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171194 91177308-0d34-0410-b5e6-96231b3b80d8
* Add entry points to instsimplify for simplifying calls. The entry pointsChandler Carruth2012-12-282-5/+50
| | | | | | | | | | are nice and decomposed so that we can simplify synthesized calls as easily as actually call instructions. The internal utility still has the same behavior, it just now operates on a more generic interface so that I can extend the set of call simplifications that instsimplify knows about. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171189 91177308-0d34-0410-b5e6-96231b3b80d8
* Add proper support for -fsanitize-blacklist= flag for TSan and MSan. LLVM part.Alexey Samsonov2012-12-283-20/+27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171183 91177308-0d34-0410-b5e6-96231b3b80d8
* CostModel: initial checkin for code that estimates the cost of special shuffles.Nadav Rotem2012-12-282-0/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171180 91177308-0d34-0410-b5e6-96231b3b80d8
* wrap 80-col lines.Nadav Rotem2012-12-281-2/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171179 91177308-0d34-0410-b5e6-96231b3b80d8
* AVX: Move the ZEXT/ANYEXT DAGCo optimizations to the lowering of these ↵Nadav Rotem2012-12-283-47/+72
| | | | | | optimizations. The old test cases still cover all of these lowering/optimizations. The single change that we have is that now anyext does not need to zero a register, because it does not use the exact code path as the zero_extend. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171178 91177308-0d34-0410-b5e6-96231b3b80d8
* Reverse the 'if' condition and reduce the indentation.Nadav Rotem2012-12-271-29/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171172 91177308-0d34-0410-b5e6-96231b3b80d8