summaryrefslogtreecommitdiffstats
path: root/llvm
Commit message (Collapse)AuthorAgeFilesLines
* No need to call functions which do the same thing as the default.Bill Wendling2012-10-031-4/+0
| | | | llvm-svn: 165135
* Remove assert that's too restrictive.Bill Wendling2012-10-031-1/+4
| | | | llvm-svn: 165134
* Add methods which query for the specific attribute instead of using theBill Wendling2012-10-035-16/+148
| | | | | | enums. This allows for better encapsulation of the Attributes class. llvm-svn: 165132
* Implement .rel relocation for R_ARM_ABS32 in MCJIT.Tim Northover2012-10-032-2/+26
| | | | | | Patch by Amara Emerson. llvm-svn: 165128
* This Patch corrects a problem whereby the optimization to use a faster dividePreston Gurd2012-10-031-5/+15
| | | | | | | | | | | | | | instruction (for Intel Atom) was not being done by Clang, because the type context used by Clang is not the default context. It fixes the problem by getting the global context types for each div/rem instruction in order to compare them against the types in the BypassTypeMap. Tests for this will be done as a separate patch to Clang. Patch by Tyler Nowicki. llvm-svn: 165126
* A DAGCombine optimization for mergeing consecutive stores to memory. The ↵Nadav Rotem2012-10-032-0/+668
| | | | | | | | | | | | | | | | | | | | | optimization is not profitable in many cases because modern processors perform multiple stores in parallel and merging stores prior to merging requires extra work. We handle two main cases: 1. Store of multiple consecutive constants: q->a = 3; q->4 = 5; In this case we store a single legal wide integer. 2. Store of multiple consecutive loads: int a = p->a; int b = p->b; q->a = a; q->b = b; In this case we load/store either ilegal vector registers or legal wide integer registers. llvm-svn: 165125
* Set up MCSchedModel after detecting the CPU type in X86SubTarget.Preston Gurd2012-10-031-0/+4
| | | | | | | | | Corrects a problem whereby MCSchedModel was not being set up when the CPU type was auto-detected. Patch by Andy Zhang. llvm-svn: 165122
* tsan: update the test for new atomic enumsDmitry Vyukov2012-10-031-80/+80
| | | | llvm-svn: 165109
* tsan: update the test for new atomic enumsDmitry Vyukov2012-10-031-40/+40
| | | | llvm-svn: 165108
* tsan: prepare for migration to new memory_order enum values (ABI compatible)Dmitry Vyukov2012-10-031-1/+2
| | | | llvm-svn: 165107
* Fixed a bug in the ExecutionDependencyFix pass that caused dependencies to ↵Silviu Baranga2012-10-032-3/+28
| | | | | | not propagate through implicit defs. llvm-svn: 165102
* Fix an issue where we failed to adjust the alignment constraint onChandler Carruth2012-10-032-0/+37
| | | | | | | | a memcpy to reflect that '0' has a different meaning when applied to a load or store. Now we correctly use underaligned loads and stores for the test case added. llvm-svn: 165101
* Try to use a better set of abstractions for computing the alignmentChandler Carruth2012-10-032-20/+87
| | | | | | | | | | | | | | | | | | | | necessary during rewriting. As part of this, fix a real think-o here where we might have left off an alignment specification when the address is in fact underaligned. I haven't come up with any way to trigger this, as there is always some other factor that reduces the alignment, but it certainly might have been an observable bug in some way I can't think of. This also slightly changes the strategy for placing explicit alignments on loads and stores to only do so when the alignment does not match that required by the ABI. This causes a few redundant alignments to go away from test cases. I've also added a couple of tests that really push on the alignment that we end up with on loads and stores. More to come here as I try to fix an underlying bug I have conjectured and produced test cases for, although it's not clear if this bug is the one currently hitting dragonegg's gcc47 bootstrap. llvm-svn: 165100
* Revert 165051-165049 while looking into the foreach.m failure inEric Christopher2012-10-035-95/+27
| | | | | | more detail. llvm-svn: 165099
* Fix doxygen comment to match function name.Craig Topper2012-10-031-1/+1
| | | | llvm-svn: 165094
* Remove unused function that used to get itineraries from SubTargetFeatures. ↵Craig Topper2012-10-032-28/+0
| | | | | | This is done from MCSubTargetInfo these days. llvm-svn: 165092
* Fix 80-column violationCraig Topper2012-10-031-2/+2
| | | | llvm-svn: 165089
* test/ExecutionEngine/MCJIT: MCJIT should work also on mingw.NAKAMURA Takumi2012-10-032-2/+2
| | | | | FIXME: Also cygwin? llvm-svn: 165081
* Third try at fixing this. ;] Go back to using std::remove_if, which hasChandler Carruth2012-10-031-8/+28
| | | | | | | | | | most of the behavior we want, but wrap the predicate in one which erases elements from the set if they pass the predicate. Oh what I wouldn't give for a lambda here. Let me know if the predicate wrapping is too much magic. ;] llvm-svn: 165076
* The early if conversion pass is ready to be used as an opt-in.Jakob Stoklund Olesen2012-10-033-5/+11
| | | | | | | | | | | Enable the pass by default for targets that request it, and change the -enable-early-ifcvt to the opposite -disable-early-ifcvt. There are still some x86 regressions when enabling early if-conversion because of the missing machine models. Disable the pass for x86 until machine models are added. llvm-svn: 165075
* Switch the SetVector::remove_if implementation to use partition whichChandler Carruth2012-10-032-3/+6
| | | | | | | | | | | | | | preserves the values of the relocated entries, unlikely remove_if. This allows walking them and erasing them. Also flesh out the predicate we are using for this to support the various constraints actually imposed on a UnaryPredicate -- without this we can't compose it with std::not1. Thanks to Sean Silva for the review here and noticing the issue with std::remove_if. llvm-svn: 165073
* Fix a serious X86 instruction selection bug. InEvan Cheng2012-10-022-3/+30
| | | | | | | | | | | | | X86DAGToDAGISel::PreprocessISelDAG(), isel is moving load inside callseq_start / callseq_end so it can be folded into a call. This can create a cycle in the DAG when the call is glued to a copytoreg. We have been lucky this hasn't caused too many issues because the pre-ra scheduler has special handling of call sequences. However, it has caused a crash in a specific tailcall case. rdar://12393897 llvm-svn: 165072
* Revert "Don't use a debug location for frame setup instructions in the"Eric Christopher2012-10-023-39/+5
| | | | | | | This reverts 165055 and 165052 temporarily while I look at debugger failures. llvm-svn: 165071
* Revert 165057, per Jim's request. This requires further discussion.Chad Rosier2012-10-022-33/+8
| | | | llvm-svn: 165069
* The mips 64bit instructions DSLL, DSRA, DSRL, DEXT and DINS get transformed ↵Jack Carter2012-10-026-56/+54
| | | | | | | | | | | | by the assembler or through codegen direct object output to other variants based on the value of the immediate values of the operands. If the code is generated as assembler, this transformation does not occur assuming that it will occur later in the assembler. This code was originally called from MipsAsmPrinter.cpp and we needed to check for OutStreamer.hasRawTextSupport(). This was not a good place for it and has been moved to MCTargetDesc/MipsMCCodeEmitter.cpp where both direct object and the assembler use it it automagically. The test cases have been checked in for a number of weeks now. llvm-svn: 165067
* Teach the new SROA to handle cases where an alloca that has already beenChandler Carruth2012-10-023-0/+59
| | | | | | | | | | | | | | | | scheduled for processing on the worklist eventually gets deleted while we are processing another alloca, fixing the original test case in PR13990. To facilitate this, add a remove_if helper to the SetVector abstraction. It's not easy to use the standard abstractions for this because of the specifics of SetVectors types and implementation. Finally, a nice small test case is included. Thanks to Benjamin for the fantastic reduced test case here! All I had to do was delete some empty basic blocks! llvm-svn: 165065
* Clean up these doxygen comments to follow the proposed new style. ThisChandler Carruth2012-10-021-21/+22
| | | | | | | also makes it more consistent with Clang and several passes' doxygen style. llvm-svn: 165064
* Make sure to put our sret argument into %rax on x86-64. Fixes PR13563!Nick Lewycky2012-10-022-2/+29
| | | | llvm-svn: 165063
* Remove the old coalescer algorithm.Jakob Stoklund Olesen2012-10-021-344/+1
| | | | | | | The new algorithm has been enabled by default for almost a week now and seems to be stable. llvm-svn: 165062
* Handle reserved registers more accurately in handleMove().Jakob Stoklund Olesen2012-10-021-8/+7
| | | | | | | | | | | | Reserved register live ranges look like a set of dead defs - any uses of reserved registers are ignored. Instead of skipping the updating of reserved register operands entirely, just ignore the use operands and treat the def operands normally. No test case, handleMove() is not commonly used yet. llvm-svn: 165060
* [ms-inline asm] Add basic support for wildcard MCParsedAsmOperands. This typeChad Rosier2012-10-022-8/+33
| | | | | | | | | | | | | of operand is specific to MS-style inline assembly and should not be generated when parsing normal assembly. The purpose of the wildcard operands are to allow the AsmParser to match multiple instructions (i.e., MCInsts) to a given ms-style asm statement. For the time being the matcher just returns the first match. This patch only implements wildcard matches for memory operands. Support for register wildcards will be added in the near future. llvm-svn: 165057
* Make sure the whole live range is covered when values are pruned twice.Jakob Stoklund Olesen2012-10-022-2/+31
| | | | | | | | | | | | | | | | | | | | | | | | JoinVals::pruneValues() calls LIS->pruneValue() to avoid conflicts when overlapping two different values. This produces a set of live range end points that are used to reconstruct the live range (with SSA update) after joining the two registers. When a value is pruned twice, the set of end points was insufficient: v1 = DEF v1 = REPLACE1 v1 = REPLACE2 KILL v1 The end point at KILL would only reconstruct the live range from REPLACE2 to KILL, leaving the range REPLACE1-REPLACE2 dead. Add REPLACE2 as an end point in this case so the full live range is reconstructed. This fixes PR13999. llvm-svn: 165056
* Allow alternate instructions to silence bot.Eric Christopher2012-10-021-1/+1
| | | | llvm-svn: 165055
* 80-col.Eric Christopher2012-10-021-2/+2
| | | | llvm-svn: 165054
* Clean-up of memory buffer and object ownership model in MCJITAndrew Kaylor2012-10-0215-163/+311
| | | | llvm-svn: 165053
* Don't use a debug location for frame setup instructions in theEric Christopher2012-10-023-5/+39
| | | | | | | prologue. Also skip frame setup instructions when looking for the first location. llvm-svn: 165052
* Use the existing DebugLoc.Eric Christopher2012-10-021-1/+1
| | | | llvm-svn: 165051
* Make the location a parameter since we may not want the next oneEric Christopher2012-10-021-7/+10
| | | | | | in the block. llvm-svn: 165050
* Remove the SavePoint infrastructure from fast isel, replaceEric Christopher2012-10-024-20/+85
| | | | | | | with just an insert point from the MachineBasicBlock and let the location be updated as we access it. llvm-svn: 165049
* Set the 'build clang only' flag when we're building only clang.Bill Wendling2012-10-021-0/+1
| | | | llvm-svn: 165042
* Improve overflow detection in StringRef::getAsUnsignedInteger().Nick Kledzik2012-10-021-2/+2
| | | | llvm-svn: 165038
* Fix another crasher in SROA, reported by Joel.Chandler Carruth2012-10-021-9/+32
| | | | | | | | | | | | | | | | | | We require that the indices into the use lists are stable in order to build fast lookup tables to locate a particular partition use from an operand of a PHI or select. This is (obviously in hind sight) incompatible with erasing elements from the array. Really, we don't want to erase anyways. It is expensive, and a rare operation. Instead, simply weaken the contract of the PartitionUse structure to allow null Use pointers to represent dead uses. Now we can clear out the pointer to mark things as dead, and all it requires is adding some 'continue' checks to the various loops. I'm still reducing a test case for this, as the test case I have is huge. I think this one I can get a nice test case for though, as it was much more deterministic. llvm-svn: 165032
* Support for generating ELF objects on Windows.Andrew Kaylor2012-10-0257-59/+84
| | | | | | This adds 'elf' as a recognized target triple environment value and overrides the default generated object format on Windows platforms if that value is present. This patch also enables MCJIT tests on Windows using the new environment value. llvm-svn: 165030
* Fix a silly coding error on my part. The whole point of the speculatorChandler Carruth2012-10-021-16/+28
| | | | | | | | | | | | | | | being separate was that it can grow the use list. As a consequence, we can't use the iterator-pair interface, we need an index based interface. Expose such an interface from the AllocaPartitioning, and use it in the speculator. This should at least fix a use-after-free bug found by Duncan, and may fix some of the other crashers. I don't have a nice deterministic test case yet, but if I get a good one, I'll add it. llvm-svn: 165027
* Fix broken tests.Benjamin Kramer2012-10-024-5/+6
| | | | llvm-svn: 165019
* Fix PR13991: legalizing an overflowing multiplication operation is harder thanDuncan Sands2012-10-022-7/+29
| | | | | | | the add/sub case since in the case of multiplication you also have to check that the operation in the larger type did not overflow. llvm-svn: 165017
* Add default JIT LIT variable.James Molloy2012-10-024-3/+8
| | | | | | Patch by David Tweed! llvm-svn: 164996
* Turn the new SROA pass back on. Let's see if it sticks this time. =]Chandler Carruth2012-10-021-1/+1
| | | | | | Again, let me know if anything breaks due to this! llvm-svn: 164986
* Fix 80-column violations. Cleanup whitespace in generated code.Chad Rosier2012-10-021-15/+23
| | | | llvm-svn: 164983
* [ms-inline asm] Add the convertToMapAndConstraints() function that is used toChad Rosier2012-10-016-87/+91
| | | | | | | | | | | map constraints and MCInst operands to inline asm operands. This replaces the getMCInstOperandNum() function. The logic to determine the constraints are not in place, so we still default to a register constraint (i.e., "r"). Also, we no longer build the MCInst but rather return just the opcode to get the MCInstrDesc. llvm-svn: 164979
OpenPOWER on IntegriCloud