summaryrefslogtreecommitdiffstats
path: root/llvm/include
Commit message (Collapse)AuthorAgeFilesLines
* Fix bug 19437 - Only add discriminators for DWARF 4 and above.Diego Novillo2014-04-171-0/+8
| | | | | | | | | | | | | | Summary: This prevents the discriminator generation pass from triggering if the DWARF version being used in the module is prior to 4. Reviewers: echristo, dblaikie CC: llvm-commits Differential Revision: http://reviews.llvm.org/D3413 llvm-svn: 206507
* ARM64: add acquire/release versions of the existing atomic intrinsics.Tim Northover2014-04-171-3/+9
| | | | | | | These will be needed to support IR-level lowering of atomic operations. llvm-svn: 206489
* Atomics: promote ARM's IR-based atomics pass to CodeGen.Tim Northover2014-04-173-0/+36
| | | | | | | | | | | | Still only 32-bit ARM using it at this stage, but the promotion allows direct testing via opt and is a reasonably self-contained patch on the way to switching ARM64. At this point, other targets should be able to make use of it without too much difficulty if they want. (See ARM64 commit coming soon for an example). llvm-svn: 206485
* Inliner::OptimizationRemark: Fix crash in ↵NAKAMURA Takumi2014-04-171-1/+2
| | | | | | | | clang/test/Frontend/optimization-remark.c on some hosts, including --vg. DebugLoc in Callsite would not live after Inliner. It should be copied before Inliner. llvm-svn: 206459
* [LCG] Remove a dead declaration. This stopped being used when I switchedChandler Carruth2014-04-171-3/+0
| | | | | | | to a more normal move operation on the graph itself. The definition already got removed, but I missed the declaration. llvm-svn: 206455
* [LCG] Move the call graph node class into the graph class's definition.Chandler Carruth2014-04-171-38/+38
| | | | | | | This will become necessary to build up the SCC iterators and SCC definitions. Moving it now so that subsequent diffs are incremental. llvm-svn: 206454
* Make the User::value_op_iterator a random access iterator. I had writtenChandler Carruth2014-04-171-12/+39
| | | | | | | | | this code ages ago and lost track of it. Seems worth doing though -- this thing can get called from places that would benefit from knowing that std::distance is O(1). Also add a very fledgeling unittest for Users and make sure various aspects of this seem to work reasonably. llvm-svn: 206453
* [LCG] Just move the allocator (now that we can) when moving a callChandler Carruth2014-04-171-6/+3
| | | | | | | | | graph. This simplifies the custom move constructor operation to one of walking the graph and updating the 'up' pointers to point to the new location of the graph. Switch the nodes from a reference to a pointer for the 'up' edge to facilitate this. llvm-svn: 206450
* [LCG] Remove the Module reference member which we weren't using forChandler Carruth2014-04-171-2/+0
| | | | | | anything and doesn't make sense if assigning. llvm-svn: 206449
* [Allocator] Make SpecificBumpPtrAllocator also movable and moveChandler Carruth2014-04-171-3/+7
| | | | | | assignable. llvm-svn: 206448
* Support: Move OnDiskHashTable from clang to llvmJustin Bogner2014-04-171-0/+544
| | | | | | | | | This introduces clang's Basic/OnDiskHashTable.h into llvm as Support/OnDiskHashTable.h. I've taken the opportunity to add doxygen comments and run the file through clang-format, but other than the namespace changing from clang:: to llvm:: the API is identical. llvm-svn: 206438
* [c++11] Tidy up AsmPrinter.cpp.Jim Grosbach2014-04-161-1/+1
| | | | | | | Range'ify loops and tidy up some by-reference handling. No functional change. llvm-svn: 206422
* iterator_range for machine block terminators.Jim Grosbach2014-04-161-0/+6
| | | | llvm-svn: 206421
* Added new functionality to LLVM C API to use DiagnosticInfo to handle errorsTom Stellard2014-04-162-0/+41
| | | | | | Patch by: Darren Powell llvm-svn: 206407
* [mips] Add initial support for NaN2008 in the back-end.Matheus Almeida2014-04-161-0/+1
| | | | | | | | | | | | This is so that EF_MIPS_NAN2008 is set if we are using IEEE 754-2008 NaN encoding (-mnan=2008). This patch also adds support for parsing '.nan legacy' and '.nan 2008' assembly directives. The handling of these directives should match GAS' behaviour i.e., the last directive in use sets the ELF header bit (EF_MIPS_NAN2008). Differential Revision: http://reviews.llvm.org/D3346 llvm-svn: 206396
* [LCG] Stop playing fast and loose with reference members and assignment.Chandler Carruth2014-04-161-11/+4
| | | | | | | | | It doesn't work. I'm still cleaning up all the places where I blindly followed this pattern. There are more to come in this code too. As a benefit, this lets the default copy and move operations Just Work. llvm-svn: 206375
* [Allocator] Make BumpPtrAllocator movable and move assignable.Chandler Carruth2014-04-161-3/+32
| | | | llvm-svn: 206372
* [Allocator] Nuke to useless functions. The implicit ones are sufficientChandler Carruth2014-04-161-3/+0
| | | | | | here (obviously). llvm-svn: 206369
* Convert SelectionDAG::getVTList to use ArrayRefCraig Topper2014-04-161-1/+1
| | | | llvm-svn: 206357
* [Allocator] Fold the two templated overloads into a single one withChandler Carruth2014-04-151-17/+4
| | | | | | | a default argument. The allocator interface we're modeling doesn't distinguish between array and non-array allocation. llvm-svn: 206327
* [Allocator] Remove a really problematic overload. This is very confusingChandler Carruth2014-04-151-8/+0
| | | | | | | | | because there is another (size_t, size_t) overload of Allocator, and the only distinguishing factor is that one is a tempalte and the other isn't. There was only one usage of this and that one was easily converted to carry the alignment constraint in the type itself. llvm-svn: 206325
* Use unique_ptr to manage ownership of child Regions within llvm::RegionDavid Blaikie2014-04-151-1/+2
| | | | llvm-svn: 206310
* verify-di: Implement DebugInfoVerifierDuncan P. N. Exon Smith2014-04-152-0/+14
| | | | | | | | | | | | | | | | | | | | | Implement DebugInfoVerifier, which steals verification relying on DebugInfoFinder from Verifier. - Adds LegacyDebugInfoVerifierPassPass, a ModulePass which wraps DebugInfoVerifier. Uses -verify-di command-line flag. - Change verifyModule() to invoke DebugInfoVerifier as well as Verifier. - Add a call to createDebugInfoVerifierPass() wherever there was a call to createVerifierPass(). This implementation as a module pass should sidestep efficiency issues, allowing us to turn debug info verification back on. <rdar://problem/15500563> llvm-svn: 206300
* FastISel: constrain the RegClass of operands when emitting instructions.Tim Northover2014-04-151-0/+6
| | | | | | | | | | | ARM64 suffered multiple -verify-machineinstr failures (principally over the xsp/xzr issue) because FastISel was completely ignoring which subset of the general-purpose registers each instruction required. More fixes are coming in ARM64 specific FastISel, but this should cover the generic problems. llvm-svn: 206283
* [Allocator] Finally, finish nuking the redundant code that led me hereChandler Carruth2014-04-151-17/+4
| | | | | | | | | | | | | | | | by removing the MallocSlabAllocator entirely and just using MallocAllocator directly. This makes all off these allocators expose and utilize the same core interface. The only ugly part of this is that it exposes the fact that the JIT allocator has no real handling of alignment, any more than the malloc allocator does. =/ It would be nice to fix both of these to support alignments, and then to leverage that in the BumpPtrAllocator to do less over allocation in order to manually align pointers. But, that's another patch for another day. This patch has no functional impact, it just removes the somewhat meaningless wrapper around MallocAllocator. llvm-svn: 206267
* [Allocator] Pass the size to the deallocation function. This, on someChandler Carruth2014-04-153-13/+17
| | | | | | | | | | | | allocation libraries, may allow more efficient allocation and deallocation. It at least makes the interface implementable by the JIT memory manager. However, this highlights problematic overloading between the void* and the T* deallocation functions. I'm looking into a better way to do this, but as it happens, it comes up rarely in the codebase. llvm-svn: 206265
* [Allocator] Fix r206256 which got the enabling case backwards on theseChandler Carruth2014-04-151-2/+2
| | | | | | | | | | overloads. This doesn't matter *that* much yet, but it will in a subsequent patch. I had tested the original pattern, but not my attempt to pacify MSVC. This at least appears to work. Still fixing the rest of the fallout in the final patch that uses these overloads, but it will follow shortly. llvm-svn: 206259
* Fix broken build of llvm using clang.Nick Lewycky2014-04-151-0/+2
| | | | llvm-svn: 206257
* [Allocator] MSVC apparantly has broken SFINAE context handling ofChandler Carruth2014-04-151-2/+5
| | | | | | | | | | 'sizeof(T)' for T == void and produces a hard error. I cannot fathom why this is OK. Oh well. switch to an explicit test for being the (potentially qualified) void type, which is the only specific case I was worried about. Hopefully this survives the libstdc++ build bots which have limited type traits implementations... llvm-svn: 206256
* Break PseudoSourceValue out of the Value hierarchy. It is now the root of ↵Nick Lewycky2014-04-155-32/+39
| | | | | | its own tree containing FixedStackPseudoSourceValue (which you can use isa/dyn_cast on) and MipsCallEntry (which you can't). Anything that needs to use either a PseudoSourceValue* and Value* is strongly encouraged to use a MachinePointerInfo instead. llvm-svn: 206255
* [C++11] More 'nullptr' conversion. In some cases just using a boolean check ↵Craig Topper2014-04-151-1/+1
| | | | | | instead of comparing to nullptr. llvm-svn: 206254
* Add a DenseMapInfo specialization for PointerUnion. In tree user to land ↵Nick Lewycky2014-04-151-0/+28
| | | | | | shortly. llvm-svn: 206253
* [C++11] More 'nullptr' conversion. In some cases just using a boolean check ↵Craig Topper2014-04-1524-92/+93
| | | | | | instead of comparing to nullptr. llvm-svn: 206252
* [Allocator] Constrain the Deallocate templated overloads to only applyChandler Carruth2014-04-151-2/+5
| | | | | | | | | | | to types which we can compute the size of. The comparison with zero isn't actually interesting here, it's mostly about putting sizeof into a sfinae context. This is particular important for Deallocate as otherwise the void* overload can quickly become ambiguous. llvm-svn: 206251
* Use unique_ptr to manage ownership of GCFunctionInfos in GCStrategyDavid Blaikie2014-04-151-2/+2
| | | | llvm-svn: 206249
* Use unique_ptr for the result of Registry entries.David Blaikie2014-04-151-4/+7
| | | | llvm-svn: 206248
* Use unique_ptr to manage ownership of GCStrategy objects in GCMetadataDavid Blaikie2014-04-152-3/+4
| | | | llvm-svn: 206246
* Use unique_ptr to own MCFunctions within MCModule.David Blaikie2014-04-151-2/+2
| | | | | | | | MCModule's ctor had to be moved out of line so the definition of MCFunction was available. (ctor requires the dtor of members (in case the ctor throws) which required access to the dtor of MCFunction) llvm-svn: 206244
* [C++11] More 'nullptr' conversion. In some cases just using a boolean check ↵Craig Topper2014-04-1520-58/+62
| | | | | | instead of comparing to nullptr. llvm-svn: 206243
* Use std::unique_ptr to manage MCBasicBlocks in MCFunction.David Blaikie2014-04-151-6/+6
| | | | llvm-svn: 206242
* [MC] Require an MCContext when constructing an MCDisassembler.Lang Hames2014-04-152-5/+11
| | | | | | | | | | | | | | | | This patch re-introduces the MCContext member that was removed from MCDisassembler in r206063, and requires that an MCContext be passed in at MCDisassembler construction time. (Previously the MCContext member had been initialized in an ad-hoc fashion after construction). The MCCContext member can be used by MCDisassembler sub-classes to construct constant or target-specific MCExprs. This patch updates disassemblers for in-tree targets, and provides the MCRegisterInfo instance that some disassemblers were using through the MCContext (previously those backends were constructing their own MCRegisterInfo instances). llvm-svn: 206241
* Add iterator_range for MachineInstr defs.Jim Grosbach2014-04-151-0/+16
| | | | llvm-svn: 206238
* [Allocator] Add Deallocate support to the AllocatorBase CRTP class,Chandler Carruth2014-04-151-0/+33
| | | | | | | | | | | | along with templated overloads much like we have for Allocate. These will facilitate switching the Deallocate interface of all the Allocator classes to accept the size by pre-filling it from the type size where we can do so. I plan to convert several uses to the template variants in subsequent patches prior to adding the Size parameter. No functionality changed, WIP. llvm-svn: 206230
* [Allocator] Hack around the fact that GCC can't compile theChandler Carruth2014-04-151-0/+2
| | | | | | | static_assert added in r206225. I'm looking into a proper fix, but wanted the bots back. llvm-svn: 206226
* [Allocator] Factor the Allocate template overloads into a base classChandler Carruth2014-04-151-29/+57
| | | | | | | | | | | | | | | | | | | | rather than defining them (differently!) in both allocators. This also serves as a basis for documenting and even enforcing some of the LLVM-style "allocator" concept methods which must exist with various signatures. I plan on extending and changing the signatures of these to further simplify our allocator model in subsequent commits, so I wanted to factor things as best as I could first. Notably, I'm working to add the 'Size' to the deallocation method of all allocators. This has several implications not the least of which are faster deallocation times on certain allocation libraries (tcmalloc). It also will allow the JIT allocator to fully model the existing allocation interfaces and allow sanitizer poisoning of deallocated regions. The list of advantages goes on. =] But by factoring things first I'll be able to make this easier by first introducing template helpers for the deallocation path. llvm-svn: 206225
* [cleanup] Run clang-format over most of YAMLParser.h to fix a bunch ofChandler Carruth2014-04-141-55/+41
| | | | | | | | small formatting inconsistencies with the rest of LLVM and even this file. I looked at all the changes and they seemed like just better formatting. llvm-svn: 206209
* [ARM64] Add big endian target arm64_be.James Molloy2014-04-141-1/+2
| | | | llvm-svn: 206197
* Teach llvm-lto to respect the given RelocModel.James Molloy2014-04-141-1/+2
| | | | | | Patch by Nick Tomlinson! llvm-svn: 206177
* [Allocator] Hoist the external helper function into a namespace scopeChandler Carruth2014-04-141-6/+10
| | | | | | | declaration. GCC 4.7 appears to get hopelessly confused by declaring this function within a member function of a class template. Go figure. llvm-svn: 206152
* [cleanup] Normalize YAMLParser.h's doxygen markers with '\foo' insteadChandler Carruth2014-04-141-33/+33
| | | | | | | of '@foo'. The slash variant is prefered in LLVM and the file was already using a mixture. =/ llvm-svn: 206151
OpenPOWER on IntegriCloud