aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Disable Uninitialized Use Warnings for Broken gcc VersionsDavid Greene2013-01-152-3/+30
| | | | | | | | | | | | Some versions of gcc accept unsupported -W flags and run just fine if there are no warnings, but die with an unsupported flag error if a warning is encountered. gcc 4.3 and gcc 4.4 both exhibit this behavior for -Wno-maybe-uninitialized. Therefore, if the flag check for -Wno-maybe-uninitialized succeeds, only use -Wno-maybe-uninitialized if we are using gcc version 4.7 or greater. Use -Wno-uninitialized otherwise. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172543 91177308-0d34-0410-b5e6-96231b3b80d8
* [msan] Temporarily remove ICmpEQ tests.Evgeniy Stepanov2013-01-151-54/+0
| | | | | | | They are failing on the bots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172540 91177308-0d34-0410-b5e6-96231b3b80d8
* [msan] Fix handling of equality comparison of pointer vectors.Evgeniy Stepanov2013-01-152-6/+79
| | | | | | | Also improve test coveration of the handling of relational comparisons. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172539 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow vectors in CreatePointerCast.Evgeniy Stepanov2013-01-151-3/+3
| | | | | | | Both underlying IR operations support vectors of pointers already. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172538 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix operand type conditions in one of ICmpInst constructors.Evgeniy Stepanov2013-01-151-1/+1
| | | | | | | It was out of sync with the conditions in the other two constructors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172535 91177308-0d34-0410-b5e6-96231b3b80d8
* Pattern-matched variables in post-inc-icmpzero.llRenato Golin2013-01-151-4/+4
| | | | | | | | | | | Test was failing for clang-native-arm-cortex-a9 build-bot configuration. The reason for the failure was the test was using hardcoded names. The attached patch fixes this failure by replacing the hard-coded variables names with pattern-matched variable names. Patch by Manish Verma, ARM git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172534 91177308-0d34-0410-b5e6-96231b3b80d8
* Update CODE_OWNERS.TXT.Michael J. Spencer2013-01-151-0/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172525 91177308-0d34-0410-b5e6-96231b3b80d8
* [Object][ELF] Simplify ELFObjectFile by using ELFType.Michael J. Spencer2013-01-154-550/+476
| | | | | | | | | | | | | This simplifies the usage and implementation of ELFObjectFile by using ELFType to replace: <endianness target_endianness, std::size_t max_alignment, bool is64Bits> This does complicate the base ELF types as they must now use template template parameters to partially specialize for the 32 and 64bit cases. However these are only defined once. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172515 91177308-0d34-0410-b5e6-96231b3b80d8
* [Support] Add LLVM_CONSTEXPR.Michael J. Spencer2013-01-151-0/+6
| | | | | | Marks a decl as constexpr if the compiler supports it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172508 91177308-0d34-0410-b5e6-96231b3b80d8
* [ADT/StringMap] Follow-up to r172455, use the correct constructor for ↵Argyrios Kyrtzidis2013-01-151-1/+2
| | | | | | | | setting the InitialSize, previously it was calling the "StringMapImpl(unsigned itemSize)" constructor. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172500 91177308-0d34-0410-b5e6-96231b3b80d8
* LTO: Also init TTI for codegen passes.Nadav Rotem2013-01-151-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172499 91177308-0d34-0410-b5e6-96231b3b80d8
* [IR] Add verifier support for llvm.module.flags.Daniel Dunbar2013-01-153-20/+123
| | | | | | | - Also, update the LangRef documentation on module flags to match the implementation. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172498 91177308-0d34-0410-b5e6-96231b3b80d8
* This patch fixes a Mips specific bug where Jack Carter2013-01-152-1/+44
| | | | | | | | | | | | | we need to generate a N64 compound relocation R_MIPS_GPREL_32/R_MIPS_64/R_MIPS_NONE. The bug was exposed by the SingleSourcetest case DuffsDevice.c. Contributer: Jack Carter git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172496 91177308-0d34-0410-b5e6-96231b3b80d8
* Now GenericAsmParser and AsmParser are no longer friends, GenericAsmParser canEli Bendersky2013-01-141-4/+0
| | | | | | | | | | simply use the getParser method from MCAsmParserExtension, working through the MCAsmParser interface. There's no longer a need to overload that method to cast it to the concrete AsmParser. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172491 91177308-0d34-0410-b5e6-96231b3b80d8
* Properly encapsulate additional methods and data from AsmParser.Eli Bendersky2013-01-142-68/+115
| | | | | | | | | | | This finally allows AsmParser to no longer list GenericAsmParser as a friend. All member vars directly accessed by GenericAsmParser have been properly encapsulated and exposed through the MCAsmParser interface. This reduces the coupling between AsmParser and GenericAsmParser. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172490 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove trailing spaces.Jakub Staszak2013-01-143-78/+78
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172489 91177308-0d34-0410-b5e6-96231b3b80d8
* This change is to implement following rules under the condition C_A and/or C_RShuxin Yang2013-01-142-8/+223
| | | | | | | | | | | | | | | | | | | | | | --------------------------------------------------------------------------- C_A: reassociation is allowed C_R: reciprocal of a constant C is appropriate, which means - 1/C is exact, or - reciprocal is allowed and 1/C is neither a special value nor a denormal. ----------------------------------------------------------------------------- rule1: (X/C1) / C2 => X / (C2*C1) (if C_A) => X * (1/(C2*C1)) (if C_A && C_R) rule 2: X*C1 / C2 => X * (C1/C2) if C_A rule 3: (X/Y)/Z = > X/(Y*Z) (if C_A && at least one of Y and Z is symbolic value) rule 4: Z/(X/Y) = > (Z*Y)/X (similar to rule3) rule 5: C1/(X*C2) => (C1/C2) / X (if C_A) rule 6: C1/(X/C2) => (C1*C2) / X (if C_A) rule 7: C1/(C2/X) => (C1/C2) * X (if C_A) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172488 91177308-0d34-0410-b5e6-96231b3b80d8
* [ms-inline asm] Extend support for parsing Intel bracketed memory operands thatChad Rosier2013-01-142-95/+468
| | | | | | | | have an arbitrary ordering of the base register, index register and displacement. rdar://12527141 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172484 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve r172468: const_cast is not needed hereDmitri Gribenko2013-01-141-3/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172483 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve r172471: avoid all those extra casts on the lines nearbyDmitri Gribenko2013-01-141-4/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172481 91177308-0d34-0410-b5e6-96231b3b80d8
* This patch addresses an incorrect transformation in the DAG combiner.Bill Schmidt2013-01-142-5/+49
| | | | | | | | | | | | | | | | | | | | | | | | The included test case is derived from one of the GCC compatibility tests. The problem arises after the selection DAG has been converted to type-legalized form. The combiner first sees a 64-bit load that can be converted into a pre-increment form. The original load feeds into a SRL that isolates the upper 32 bits of the loaded doubleword. This looks like an opportunity for DAGCombiner::ReduceLoadWidth() to replace the 64-bit load with a 32-bit load. However, this transformation is not valid, as the replacement load is not a pre-increment load. The pre-increment load produces an extra result, which feeds a subsequent add instruction. The replacement load only has one result value, and this value is propagated to all uses of the pre- increment load, including the add. Because the add is looking for the second result value as its operand, it ends up attempting to add a constant to a token chain, resulting in a crash. So the patch simply disables this transformation for any load with more than two result values. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172480 91177308-0d34-0410-b5e6-96231b3b80d8
* Follow up of commit r172472.Quentin Colombet2013-01-141-28/+15
| | | | | | | Refactor the big if/else sequence into one string switch for ARM subtype selection. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172475 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve r172464: const_cast is not needed if the variable is not constDmitri Gribenko2013-01-141-3/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172474 91177308-0d34-0410-b5e6-96231b3b80d8
* Complete the existing support of ARM v6m, v7m, and v7em, i.e., respectively ↵Quentin Colombet2013-01-142-1/+13
| | | | | | | | | cortex-m0, cortex-m3, and cortex-m4 on the backend side. Adds new subtype values for the MachO format and use them when the related triple are set. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172472 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix CastingDavid Greene2013-01-141-1/+2
| | | | | | Fix a casting-away-const compiler warning. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172471 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix CastingDavid Greene2013-01-141-1/+2
| | | | | | Do proper casting to eliminate a const-away-cast compiler warning. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172470 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix More CastsDavid Greene2013-01-141-3/+8
| | | | | | Properly cast some more code that triggered cast-away-const errors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172469 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix Another CastDavid Greene2013-01-141-1/+2
| | | | | | Properly cast code to eliminate cast-away-const errors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172468 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix Casting BugDavid Greene2013-01-141-1/+3
| | | | | | Add a const version of getFpValPtr to avoid a cast-away-const warning. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172467 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix More CastsDavid Greene2013-01-141-1/+2
| | | | | | Fix another cast-away-const cast. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172466 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix CastingDavid Greene2013-01-141-1/+1
| | | | | | Stop a gcc warning about casting away const. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172465 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix CastsDavid Greene2013-01-141-1/+2
| | | | | | Use const_cast<> to avoid cast-away-const errors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172464 91177308-0d34-0410-b5e6-96231b3b80d8
* SCEVExpander fix. RAUW needs to update the InsertedExpressions cache.Andrew Trick2013-01-143-4/+89
| | | | | | | | Note that this bug is only exposed because LTO fails to use TTI. Fixes self-LTO of clang. rdar://13007381. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172462 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typo in comment.Nick Lewycky2013-01-141-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172460 91177308-0d34-0410-b5e6-96231b3b80d8
* [ADT/StringMap] Add a constructor in StringMap that accepts both anArgyrios Kyrtzidis2013-01-141-0/+3
| | | | | | initial size and an allocator. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172455 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix DenseMap when LLVM_HAS_RVALUE_REFERENCES is defined but equals 0.Joe Groff2013-01-141-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172454 91177308-0d34-0410-b5e6-96231b3b80d8
* Add DenseMap::insert(value_type&&) method.Joe Groff2013-01-141-0/+18
| | | | | | | | Use the existing move implementation of the internal DenseMap::InsertIntoBucket method to provide a user-facing move insert method. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172453 91177308-0d34-0410-b5e6-96231b3b80d8
* Changed SmallPtrSet.count guard + SmallPtrSet.insert to just SmallPtrSet.insert.Michael Gottesman2013-01-141-2/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172452 91177308-0d34-0410-b5e6-96231b3b80d8
* Move CheckForValidSection to the MCAsmParser interface.Eli Bendersky2013-01-142-1/+5
| | | | | | | | | | | | | | Now that it behaves itself in terms of streamer independence (r172450), this method can be moved to MCAsmParser to be available to all extensions, overriding, etc. -- -This line, and those below, will be ignored-- M lib/MC/MCParser/AsmParser.cpp M include/llvm/MC/MCParser/MCAsmParser.h git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172451 91177308-0d34-0410-b5e6-96231b3b80d8
* Expose an InitToTextSection through MCStreamer.Eli Bendersky2013-01-1410-11/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The aim of this patch is to fix the following piece of code in the platform-independent AsmParser: void AsmParser::CheckForValidSection() { if (!ParsingInlineAsm && !getStreamer().getCurrentSection()) { TokError("expected section directive before assembly directive"); Out.SwitchSection(Ctx.getMachOSection( "__TEXT", "__text", MCSectionMachO::S_ATTR_PURE_INSTRUCTIONS, 0, SectionKind::getText())); } } This was added for the "-n" option of llvm-mc. The proposed fix adds another virtual method to MCStreamer, called InitToTextSection. Conceptually, it's similar to the existing InitSections which initializes all common sections and switches to text. The new method is implemented by each platform streamer in a way that it sees fit. So AsmParser can now do this: void AsmParser::CheckForValidSection() { if (!ParsingInlineAsm && !getStreamer().getCurrentSection()) { TokError("expected section directive before assembly directive"); Out.InitToTextSection(); } } Which is much more reasonable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172450 91177308-0d34-0410-b5e6-96231b3b80d8
* Move ParseMacroArgument to the MCAsmParser interfance.Eli Bendersky2013-01-142-13/+20
| | | | | | | | | | | | | | Since it's used by extensions. One further step to fully decoupling GenericAsmParser from an intimate knowledge of the internals of AsmParser, pointing it to the MCASmParser interface instead (like all other parser extensions do). Since this change moves the MacroArgument type to the interface header, it's renamed to be a bit more descriptive in a general context. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172449 91177308-0d34-0410-b5e6-96231b3b80d8
* Encapsulate the MacroEnabled flag in AsmParser behind accessor methods.Eli Bendersky2013-01-142-4/+11
| | | | | | | | | | The methods are also exposed via the MCAsmParser interface, which allows more than one client to control them. Previously, GenericAsmParser was playing with a member var in AsmParser directly (by virtue of being its friend). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172440 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r171829 "Split changeset_ty using iterators instead of loops" as it ↵Timur Iskhodzhanov2013-01-141-8/+6
| | | | | | breaks the VS2008 build git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172411 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify nested strconcats in X86 td files since strconcat can take more ↵Craig Topper2013-01-142-32/+32
| | | | | | than 2 arguments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172379 91177308-0d34-0410-b5e6-96231b3b80d8
* Create a single multiclass for SSE and AVX version of MOVL/MOVH. Prevents ↵Craig Topper2013-01-141-23/+24
| | | | | | needing to specify everything twice. No functional change intended git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172378 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed some 80+ violations.Michael Gottesman2013-01-141-14/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172374 91177308-0d34-0410-b5e6-96231b3b80d8
* Updated the documentation in ObjCARC.cpp to fit the style guide better (i.e. ↵Michael Gottesman2013-01-141-232/+259
| | | | | | use doxygen). Still some work to do though. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172371 91177308-0d34-0410-b5e6-96231b3b80d8
* Added bugzilla PR number to test case.Michael Gottesman2013-01-131-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172369 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed an infinite loop in the block escape in analysis in ObjCARC caused by ↵Michael Gottesman2013-01-132-3/+100
| | | | | | | | 2x blocks each assigned a value via a phi-node causing each to depend on the other. A test case is provided as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172368 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typo in comment.Nick Lewycky2013-01-131-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172364 91177308-0d34-0410-b5e6-96231b3b80d8