summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAge
* Replace OwningPtr<T> with std::unique_ptr<T>.Ahmed Charles2014-03-06
| | | | | | | | | | This compiles with no changes to clang/lld/lldb with MSVC and includes overloads to various functions which are used by those projects and llvm which have OwningPtr's as parameters. This should allow out of tree projects some time to move. There are also no changes to libs/Target, which should help out of tree targets have time to move, if necessary. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203083 91177308-0d34-0410-b5e6-96231b3b80d8
* DebugInfo: Tag units as having been indexed in GNU pubnames by using a ↵David Blaikie2014-03-06
| | | | | | | | | | DW_AT_GNU_pubnames of DW_FORM_flag(_present) rather than sec_offsets to the pubnames/types sections This is consistent with GDB ToT and reduces the number of relocations in (type and compile) units, substantially reducing relocations and debug size in fission + type units builds. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203082 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow constant folding of copysignKarthik Bhat2014-03-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203076 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Move GVMaterializer.h into the IR library where itsChandler Carruth2014-03-06
| | | | | | | | | | | | | implementation already lived. After this commit, the only IR-library headers in include/llvm/* are ones related to the legacy pass infrastructure that I'm planning to leave there until the new one is farther along. The only other headers at the top level are linking and initialization aids that aren't really libraries but just headers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203069 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Sink Linker.h into a Linker subdirectory to make itChandler Carruth2014-03-06
| | | | | | consistent with every other sub-library header in LLVM. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203065 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Move InstVisitor.h into the IR library as it is prettyChandler Carruth2014-03-06
| | | | | | obviously coupled to the IR. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203064 91177308-0d34-0410-b5e6-96231b3b80d8
* DebugInfo: Shrink pubnames/pubtypes in the presence of type units by only ↵David Blaikie2014-03-06
| | | | | | emitting pub sections for compile units git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203057 91177308-0d34-0410-b5e6-96231b3b80d8
* Add some helpful comments on DIEValue types that we expect to hash.Eric Christopher2014-03-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203055 91177308-0d34-0410-b5e6-96231b3b80d8
* The PPC global base register cannot be r0Hal Finkel2014-03-06
| | | | | | | | | The global base register cannot be r0 because it might end up as the first argument to addi or addis. Fixes PR18316. I don't have a small stable test case. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203054 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Move DebugInfo.h into the IR library where its implementationChandler Carruth2014-03-06
| | | | | | already lives. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203046 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixup PPC Darwin i1 argument handlingHal Finkel2014-03-06
| | | | | | | Like on other targets, we need to zero_extend/truncate i1 args before copying them to GPRs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203045 91177308-0d34-0410-b5e6-96231b3b80d8
* Rewrite the attribute hashing algorithm to use the type of the valueEric Christopher2014-03-06
| | | | | | | | pointed to by the attribute, rather than the form as a first step to determining how to hash the values. No functional change intended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203044 91177308-0d34-0410-b5e6-96231b3b80d8
* When using CR bit registers on PPC32, handle the i1 vaarg caseHal Finkel2014-03-06
| | | | | | | | When copying an i1 value into a GPR for a vaarg call, we need to explicitly zero-extend the i1 value (otherwise an invalid CRBIT -> GPR copy will be generated). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203041 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Move DIBuilder.h into the IR library where its implementationChandler Carruth2014-03-06
| | | | | | already lives. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203038 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the last of the special case code for emitting attributes.Eric Christopher2014-03-06
| | | | | | | | This works by moving the existing code into the DIEValue hierarchy and using the DwarfDebug pointer off of the AsmPrinter to access any global information we need. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203033 91177308-0d34-0410-b5e6-96231b3b80d8
* constify a few accessors.Eric Christopher2014-03-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203032 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove special case in the DIEValue printing since it only existedEric Christopher2014-03-06
| | | | | | for verbose asm. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203031 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a DIELocList class to handle pointers into the location list.Eric Christopher2014-03-05
| | | | | | | | This enables us to figure out where in the debug_loc section our locations are so that we can eventually hash them. It also helps remove some special case code in emission. No functional change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203018 91177308-0d34-0410-b5e6-96231b3b80d8
* With PPC CR bit registers, handle int_to_fp on older coresHal Finkel2014-03-05
| | | | | | | | | On cores without fpcvt support, we cannot promote int_to_fp i1 operations, because there is nothing to promote them to. The most straightforward implementation of this uses a select to choose between the two possible resulting floating-point values (and that's what is done here). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203015 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typoMatt Arsenault2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203013 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve LinkModules warningsJF Bastien2014-03-05
| | | | | | | | Provide triple and data layout as well as module names (or empty string) when there's a mismatch. Differential Revision: http://llvm-reviews.chandlerc.com/D2971 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203009 91177308-0d34-0410-b5e6-96231b3b80d8
* LoopVectorizer: Preserve fast-math flagsArnold Schwaighofer2014-03-05
| | | | | | Fixes PR19045. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203008 91177308-0d34-0410-b5e6-96231b3b80d8
* Always print the implicit .text at the start of an asm file.Rafael Espindola2014-03-05
| | | | | | | | | | | | | | | | | Before llvm-mc would print it, but llc was assuming that it would produce another section changing directive before one was needed. That assumption is false with inline asm. Fixes PR19049. Another option would be to always create the section, but in the asm printer avoid printing sections changes during initialization. That would work, but * We do use the fact that llvm-mc prints it in testing. The tests can be changed if needed. * A quick poll on IRC suggest that most developers prefer the implicit .text to be printed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203001 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix an inconsistency in treatment of trailing / in path::const_iteratorBen Langmuir2014-03-05
| | | | | | | | | When using a //net/ path, we were transforming the trailing / into a '.' when the path was just the root path and we were iterating backwards. Forwards iteration and other kinds of root path (C:\, /) were already correct. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202999 91177308-0d34-0410-b5e6-96231b3b80d8
* ConstantFolding: Also fold the vector overloads of our math intrinsics.Benjamin Kramer2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202997 91177308-0d34-0410-b5e6-96231b3b80d8
* Lower AVX v4i64->v4i32 truncate to one shuffle.Cameron McInally2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202996 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix clang -Werror build break due to mismatched sign comparison.David Blaikie2014-03-05
| | | | | | Originally committed in r202985. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202992 91177308-0d34-0410-b5e6-96231b3b80d8
* ARM: Correctly align arguments after a byval struct is passed on the stackOliver Stannard2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202985 91177308-0d34-0410-b5e6-96231b3b80d8
* Enable integrated assembler on OpenBSD/PPC32 by default, too.Joerg Sonnenberger2014-03-05
| | | | | | | From Brad Smith. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202967 91177308-0d34-0410-b5e6-96231b3b80d8
* This patch implements .set dsp directive and sets appropriate feature ↵Vladimir Medic2014-03-05
| | | | | | bits.This directive is a counterpart of -mattr=dsp command line option with the exception that it does not influence elf header flags. The usage example is gives in test file. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202966 91177308-0d34-0410-b5e6-96231b3b80d8
* Add missing parenthesis in SCEV commentTobias Grosser2014-03-05
| | | | | | Contributed-by: Michael Zolutukin <mzolotukhin@apple.com> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202963 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Move AutoUpgrade.h into the IR library where itsChandler Carruth2014-03-05
| | | | | | implementation already lives. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202961 91177308-0d34-0410-b5e6-96231b3b80d8
* [Layering] Move DebugLoc.h into the IR library. The implementationChandler Carruth2014-03-05
| | | | | | | | | | | already lived there and it is where it belongs -- this is the in-memory debug location representation. This is just cleanup -- Modules can actually cope with this, but that doesn't make it right. After chatting with folks that have out-of-tree stuff, going ahead and moving the rest of the headers seems preferable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202960 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Add overloads for externally used OwningPtr functions.Ahmed Charles2014-03-05
| | | | | | | | This will allow external callers of these functions to switch over time rather than forcing a breaking change all a once. These particular functions were determined by building clang/lld/lldb. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202959 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Make this interface accept const Use pointers and use overrideChandler Carruth2014-03-05
| | | | | | | | to ensure we don't mess up any of the overrides. Necessary for cleaning up the Value use iterators and enabling range-based traversing of use lists. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202958 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Replace OwningPtr::take() with OwningPtr::release().Ahmed Charles2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202957 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-05
| | | | | | class. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202953 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-05
| | | | | | class. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202946 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-05
| | | | | | class. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202945 91177308-0d34-0410-b5e6-96231b3b80d8
* Make stackmap machineinstrs clobber the scratch regs too.Andrew Trick2014-03-05
| | | | | | | | | | | | | Patchpoints already did this. Doing it for stackmaps is a convenience for the runtime in the event that it needs to scratch register to patch or perform a runtime call thunk. Unlike patchpoints, we just assume the AnyRegCC calling convention. This is the only language and target independent calling convention specific to stackmaps so makes sense. Although the calling convention is not currently used to select the scratch registers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202943 91177308-0d34-0410-b5e6-96231b3b80d8
* [C++11] Add 'override' keyword to IR library.Craig Topper2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202939 91177308-0d34-0410-b5e6-96231b3b80d8
* [C API] Implement LLVM{Get,Set}Alignment for AllocaInst.Peter Zotov2014-03-05
| | | | | | Patch by Manuel Jacob. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202936 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove unnecessary variables.Ahmed Charles2014-03-05
| | | | | | Found self-hosting clang-cl on windows. :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202935 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix unused variable in FunctionLoweringInfo.cppHans Wennborg2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202932 91177308-0d34-0410-b5e6-96231b3b80d8
* Check for dynamic allocas and inline asm that clobbers sp before buildingHans Wennborg2014-03-05
| | | | | | | | | | | | | | | | | | | selection dag (PR19012) In X86SelectionDagInfo::EmitTargetCodeForMemcpy we check with MachineFrameInfo to make sure that ESI isn't used as a base pointer register before we choose to emit rep movs (which clobbers esi). The problem is that MachineFrameInfo wouldn't know about dynamic allocas or inline asm that clobbers the stack pointer until SelectionDAGBuilder has encountered them. This patch fixes the problem by checking for such things when building the FunctionLoweringInfo. Differential Revision: http://llvm-reviews.chandlerc.com/D2954 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202930 91177308-0d34-0410-b5e6-96231b3b80d8
* C API: Add functions to get or set a GlobalValue's DLLStorageClassReid Kleckner2014-03-05
| | | | | | Patch by Manuel Jacob! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202928 91177308-0d34-0410-b5e6-96231b3b80d8
* Make the DIEValue constructor even more explicit.Eric Christopher2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202926 91177308-0d34-0410-b5e6-96231b3b80d8
* Use a bool for whether or not an abbreviation has children rather thanEric Christopher2014-03-05
| | | | | | | using a full uint16_t with the flag value... which happens to be 0 or 1. Update the class for bool values and rename functions slightly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202921 91177308-0d34-0410-b5e6-96231b3b80d8
* Use dwarf::Attribute instead of a bare uint16_t.Eric Christopher2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202920 91177308-0d34-0410-b5e6-96231b3b80d8
* Expand slightly on comment.Eric Christopher2014-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202919 91177308-0d34-0410-b5e6-96231b3b80d8