summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Revert revision 171524. Original message:Nadav Rotem2013-01-0511-282/+8
| | | | | | | | | | | | | | | | | | | | URL: http://llvm.org/viewvc/llvm-project?rev=171524&view=rev Log: The current Intel Atom microarchitecture has a feature whereby when a function returns early then it is slightly faster to execute a sequence of NOP instructions to wait until the return address is ready, as opposed to simply stalling on the ret instruction until the return address is ready. When compiling for X86 Atom only, this patch will run a pass, called "X86PadShortFunction" which will add NOP instructions where less than four cycles elapse between function entry and return. It includes tests. Patch by Andy Zhang. llvm-svn: 171603
* FileCheck-ize test/CodeGenCXX/debug-info-method.cppDavid Blaikie2013-01-051-1/+2
| | | | llvm-svn: 171602
* Whitespace.NAKAMURA Takumi2013-01-051-2/+2
| | | | llvm-svn: 171601
* DenseMap: Appease -fstrict-aliasing on g++-4.4.NAKAMURA Takumi2013-01-051-1/+2
| | | | | | | | | | | | With DenseMapInfo<Enum>, it is miscompiled on g++-4.4. static inline Enum getEmptyKey() { return Enum(<arbitrary int/unsigned value>); } isEauql(getEmptyKey(), ...) The compiler mis-assumes the return value is not aliased to Enum. llvm-svn: 171600
* Don't call destructors on MachineInstr and MachineOperand.Jakob Stoklund Olesen2013-01-054-32/+19
| | | | | | | | | | | | | | | | | | | | The series of patches leading up to this one makes llc -O0 run 8% faster. When deallocating a MachineFunction, there is no need to visit all MachineInstr and MachineOperand objects to deallocate them. All their memory come from a BumpPtrAllocator that is about to be purged, and they have empty destructors anyway. This only applies when deallocating the MachineFunction. DeleteMachineInstr() should still be used to recycle MI memory during the codegen passes. Remove the LeakDetector support for MachineInstr. I've never seen it used before, and now it definitely doesn't work. With this patch, leaked MachineInstrs would be much less of a problem since all of their memory will be reclaimed by ~MachineFunction(). llvm-svn: 171599
* Use ArrayRecycler for MachineInstr operand lists.Jakob Stoklund Olesen2013-01-055-83/+137
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of an std::vector<MachineOperand>, use MachineOperand arrays from an ArrayRecycler living in MachineFunction. This has several advantages: - MachineInstr now has a trivial destructor, making it possible to delete them in batches when destroying MachineFunction. This will be enabled in a later patch. - Bypassing malloc() and free() can be faster, depending on the system library. - MachineInstr objects and their operands are allocated from the same BumpPtrAllocator, so they will usually be next to each other in memory, providing better locality of reference. - Reduce MachineInstr footprint. A std::vector is 24 bytes, the new operand array representation only uses 8+4+1 bytes in MachineInstr. - Better control over operand array reallocations. In the old representation, the use-def chains would be reordered whenever a std::vector reached its capacity. The new implementation never changes the use-def chain order. Note that some decisions in the code generator depend on the use-def chain orders, so this patch may cause different assembly to be produced in a few cases. llvm-svn: 171598
* Add MachineRegisterInfo::moveOperands().Jakob Stoklund Olesen2013-01-052-0/+52
| | | | | | | | | | | | | This function works like memmove() for MachineOperands, except it also updates any use-def chains containing the moved operands. The use-def chains are updated without affecting the order of operands in the list. That isn't possible when using the removeRegOperandFromUseList() and addRegOperandToUseList() functions. Callers to follow soon. llvm-svn: 171597
* [CMake] Don't add flags this late and don't force libc++. Error if we know ↵Michael J. Spencer2013-01-051-20/+17
| | | | | | the compiler doesn't support c++11. llvm-svn: 171596
* Refactor the ScalarTargetTransformInfo API for querying about theChandler Carruth2013-01-053-4/+14
| | | | | | | | | | | | legality of an address mode to not use a struct of four values and instead to accept them as parameters. I'd love to have named parameters here as most callers only care about one or two of these, but the defaults aren't terribly scary to write out. That said, there is no real impact of this as the passes aren't yet using STTI for this and are still relying upon TargetLowering. llvm-svn: 171595
* Move common header files into a 'support' directory; make 'testit' include ↵Marshall Clow2013-01-05364-388/+389
| | | | | | -I to that directory; rename 'iterators.h' to 'iterator_test.h'; remove hard-coded paths to include files from more than 350 source files llvm-svn: 171594
* Add a namespace qualifier to the befriending statement forChandler Carruth2013-01-051-1/+1
| | | | | | | | RecusiveASTVisitor. With Clang and modern GCCs this was found through the injected class name of the base class but older GCCs don't properly implement the injected class name rules. llvm-svn: 171593
* Removes files for separate ReaderYAML.cpp and WriterYAML.cpp Nick Kledzik2013-01-0552-2693/+1667
| | | | | | | | and adds a new file ReaderWriterYAML.cpp that uses YAML I/O. Lots of tweaks to test suite for slightly different YAML encoding. llvm-svn: 171592
* Avoid MSVCRT assertion on comparing phdr iteratorsReid Kleckner2013-01-051-1/+3
| | | | llvm-svn: 171591
* Sink the AddressingModeMatcher helper class into an anonymous namespaceChandler Carruth2013-01-054-688/+623
| | | | | | | | | | | | next to its only user. This helper relies on TargetLowering information that shouldn't be generally used throughout the Transfoms library, and so it made little sense as a generic utility. This also consolidates the file where we need to remove the remaining uses of TargetLowering in favor of the IR-layer abstract interface in TargetTransformInfo. llvm-svn: 171590
* Rename the unittest from ArrayRecylerTest.cpp to ArrayRecyclerTest.cpp.Chandler Carruth2013-01-051-0/+0
| | | | | | | Fixes the CMake build. It took me cutting and pasting this before I managed to see the missing character. =] llvm-svn: 171589
* [mips] Fix data layout string. Add 64 to the list of native integer widthsAkira Hatanaka2013-01-052-6/+20
| | | | | | and add stack alignment information. llvm-svn: 171588
* [mips] Fix data layout string. Add 64 to the list of native integer widthsAkira Hatanaka2013-01-051-4/+6
| | | | | | and add stack alignment information. llvm-svn: 171587
* Add a method to create an AttributeSet from an AttrBuilder.Bill Wendling2013-01-053-6/+66
| | | | | | | | The Attribute class is eventually going to represent one attribute. So we need this class to create the set of attributes. Add some iterator methods to the builder to access its internal bits in a nice way. llvm-svn: 171586
* Assert that redeclarations have the same linkage.Rafael Espindola2013-01-052-3/+50
| | | | | | | It is somewhat hard to test linkage, so I decided to try to add an assert. This already found some interesting cases where there were different. llvm-svn: 171585
* Fix a typo. Remove the duplicated test.Nadav Rotem2013-01-051-25/+0
| | | | llvm-svn: 171584
* iLoopVectorize: Non commutative operators can be used as reduction variables ↵Nadav Rotem2013-01-053-7/+44
| | | | | | | | as long as the reduction chain is used in the LHS. PR14803. llvm-svn: 171583
* Force a fixed unroll count on the target independent tests.Nadav Rotem2013-01-0527-27/+27
| | | | | | This should fix clang-native-arm-cortex-a9. Thanks Renato. llvm-svn: 171582
* Add an ArrayRecycler class.Jakob Stoklund Olesen2013-01-053-0/+253
| | | | | | | | This is similar to the existing Recycler allocator, but instead of recycling individual objects from a BumpPtrAllocator, arrays of different sizes can be allocated. llvm-svn: 171581
* [CMake] Add lld to the list of test dependencies.Michael J. Spencer2013-01-051-0/+1
| | | | llvm-svn: 171580
* Target test fix.Michael J. Spencer2013-01-051-3/+1
| | | | llvm-svn: 171579
* [ELF] Add skeleton for X86-64 relocations.Michael J. Spencer2013-01-055-4/+105
| | | | llvm-svn: 171578
* [Driver] Add -flavor core support. This will be tested by other tests using ↵Michael J. Spencer2013-01-054-0/+24
| | | | | | -flavor core. llvm-svn: 171577
* [ELF][Writer] Don't infinite loop.Michael J. Spencer2013-01-051-1/+1
| | | | | | | This will be tested by a following committ that runs the linker with no inputs. llvm-svn: 171576
* StyleMichael J. Spencer2013-01-053-97/+62
| | | | llvm-svn: 171575
* Eric thought that Darwin was right to use -1 consistently rather thanChandler Carruth2013-01-051-1/+1
| | | | | | | | | | | leaving this undefined, and despite the sentence in the standard that seems to require it, I'll cede the point and assume its a bug in the wording. Other parts of POSIX regularly allow for things to be -1 instead of undefined, this should too. Makes things more consistent too. This should have to real impact for folks though. llvm-svn: 171574
* Fix a stray 'dnl' that my editor line-wrapped into this comment. ThanksChandler Carruth2013-01-051-2/+2
| | | | | | to filcab on IRC for spotting. llvm-svn: 171573
* In my last patch initialize the destination to null (with a simple store) ↵Fariborz Jahanian2013-01-052-0/+3
| | | | | | | | before doing a storeStrong to it. // rdar://12530881 llvm-svn: 171572
* Make this an integer so we have enumeral types in the conditionalEric Christopher2013-01-051-1/+1
| | | | | | expression. llvm-svn: 171571
* Finally, fix the autoconf setup to allow for a missing clock_gettime;Chandler Carruth2013-01-052-7/+4
| | | | | | the source code should now be set up to handle this. llvm-svn: 171570
* Mark TestPlatformCommand (test_status) as expected to fail on LinuxDaniel Malea2013-01-051-1/+2
| | | | | | - due to bugzilla 14806 (platform status command prints more information on Mac OS X than on Linux) llvm-svn: 171569
* Provide a default constructor for TimeValue. This was used, but only inChandler Carruth2013-01-051-0/+3
| | | | | | | if-ed out code paths and on Windows. Hopefully restores the Windows build. Thanks to Reid Kleckner for helping triage this. llvm-svn: 171568
* Fix warnings from llvm-gcc as seen on darwin10 (10.6).Alex Rosenberg2013-01-051-2/+2
| | | | llvm-svn: 171567
* Simplify build instructionsDaniel Malea2013-01-051-10/+10
| | | | | | | - setting PYTHONPATH is no longer needed to run the lldb CLI on Linux. - added instructions for setting PYTHONPATH correctly for running scripts in the native interpreter llvm-svn: 171566
* Try to suppress the use of clock_gettime on Darwin which apparantlyChandler Carruth2013-01-051-1/+1
| | | | | | | | | | | | | | | | | defines _POSIX_CPUTIME but doesn't support the clock_* functions. I don't test the value of _POSIX_CPUTIME because the spec merely says that if it is defined, the CPU-specific timers are available, whereas it says that _POSIX_TIMERS must be defined and defined to a value greater than zero. However, this may not work, as the POSIX spec clearly states: "If the symbolic constant _POSIX_CPUTIME is defined, then the symbolic constant _POSIX_TIMERS shall also be defined by the implementation to have the value 200112L." If this doesn't work, I'll add more hacks for Darwin. llvm-svn: 171565
* Fix testing case for Release build (r171493)Manman Ren2013-01-051-2/+3
| | | | | | rdar://11562117 llvm-svn: 171564
* <rdar://problem/12389806> Jason Molenda2013-01-041-1/+9
| | | | | | | | Have the disassembler's Instruction::Dump always insert at least one space character between an opcode and its arguments, don't let a long opcode name abut the arguments. llvm-svn: 171561
* Update checker build to checker-270Ted Kremenek2013-01-042-1/+10
| | | | llvm-svn: 171560
* Fix an obvious typo spotted by Reid Kleckner, and breaking windows builds.Chandler Carruth2013-01-041-1/+1
| | | | llvm-svn: 171559
* Fix lldb -P on LinuxDaniel Malea2013-01-042-8/+14
| | | | | | | | - now prints the correct PYTHONPATH - update dotest.py to use lldb -P result correctly - resolves TestPublicAPIHeaders test failure (on Linux) llvm-svn: 171558
* [Driver] Add x86-64 target.Michael J. Spencer2013-01-042-0/+59
| | | | llvm-svn: 171557
* Various fixes to clang-format's macro handling.Manuel Klimek2013-01-049-71/+232
| | | | | | | | | | | | | | | | | | | Some of this is still pretty rough (note the load of FIXMEs), but it is strictly an improvement and fixes various bugs that were related to macro processing but are also imporant in non-macro use cases. Specific fixes: - correctly puts espaced newlines at the end of the line - fixes counting of white space before a token when escaped newlines are present - fixes parsing of "trailing" tokens when eof() is hit - puts macro parsing orthogonal to parsing other structure - general support for parsing of macro definitions Due to the fix to format trailing tokens, this change also includes a bunch of fixes to the c-index tests. llvm-svn: 171556
* objective-C arc: in copy helper function for Fariborz Jahanian2013-01-042-0/+19
| | | | | | | | | __strong __block variables, perform objc_storeStrong on source and destination instead of direct move. This is done with -O0 and to improve some analysis. // rdar://12530881 llvm-svn: 171555
* Generalizing expected stop reason string checking in InferiorCrashing test case.Andrew Kaylor2013-01-041-2/+7
| | | | llvm-svn: 171554
* Get rid of the 'Bits' mask in the attribute builder.Bill Wendling2013-01-042-39/+131
| | | | | | | | The bit mask thing will be a thing of the past. It's not extensible enough. Get rid of its use here. Opt instead for using a vector to hold the attributes. Note: Some of this code will become obsolete once the rewrite is further along. llvm-svn: 171553
* Read bytes from zero-filled sections correctlySean Callanan2013-01-041-0/+13
| | | | | | | | instead of failing to read. <rdar://problem/12958589> llvm-svn: 171552
OpenPOWER on IntegriCloud