summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* IfConverter: Use TargetSchedule for instruction latenciesArnold Schwaighofer2013-09-309-10/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For targets that have instruction itineraries this means no change. Targets that move over to the new schedule model will use be able the new schedule module for instruction latencies in the if-converter (the logic is such that if there is no itineary we will use the new sched model for the latencies). Before, we queried "TTI->getInstructionLatency()" for the instruction latency and the extra prediction cost. Now, we query the TargetSchedule abstraction for the instruction latency and TargetInstrInfo for the extra predictation cost. The TargetSchedule abstraction will internally call "TTI->getInstructionLatency" if an itinerary exists, otherwise it will use the new schedule model. ATTENTION: Out of tree targets! (I will also send out an email later to LLVMDev) This means, if your target implements unsigned getInstrLatency(const InstrItineraryData *ItinData, const MachineInstr *MI, unsigned *PredCost); and returns a value for "PredCost", you now also need to implement unsigned getPredictationCost(const MachineInstr *MI); (if your target uses the IfConversion.cpp pass) radar://15077010 llvm-svn: 191671
* Enable building LTO on WIN32.Rafael Espindola2013-09-304-5/+16
| | | | | | | | | Enable building the LTO library (.lib and.dll) and llvm-lto.exe on Windows with MSVC and Mingw as well as re-enabling the associated test. Patch by Greg Bedwell! llvm-svn: 191670
* Fix build by adding dep on TransformUtilsEdwin Vane2013-09-301-1/+2
| | | | | | clang-apply-replacements unittest Makefile wasn't linking in TransformUtils. llvm-svn: 191669
* Fix a bug in InstCombine where it attempted to cast a Value* to an Instruction*Joey Gouly2013-09-302-2/+25
| | | | | | | | | when it was actually a Constant*. There are quite a few other casts to Instruction that might have the same problem, but this is the only one I have a test case for. llvm-svn: 191668
* clang-apply-replacements: Add code formatting functionalityEdwin Vane2013-09-3022-15/+422
| | | | | | | | | | | | | | The tool now supports a collection of arguments to turn on and provide settings for the formatting of code affected by applying replacements: * --format turns on formatting (default style is LLVM) * --style controls code style settings * --style-config allows one to explicitly indicate where a style config file lives. The libclangApplyReplacements interface has a new function to turn Replacements into Ranges to be used with tooling::reformat(). llvm-svn: 191667
* Moving style option formatting to libFormatEdwin Vane2013-09-303-78/+108
| | | | | | | | | The help text for clang-format's -style option and the function that processes its value is moved to libFormat in this patch. The goal is to enable other tools that use libFormat and also have a -style option to behave consistently with clang-format. llvm-svn: 191666
* Fix use-after-free.Manuel Klimek2013-09-301-3/+3
| | | | | | | | TemplateDeclInstantiator takes the MultiLevelArgumentList by const-ref and stores a const-ref member. Thus, we must not pass a temporary into the constructor. llvm-svn: 191665
* [ARM] Assembler: Add more negative tests for ARM LDRD.Tilmann Scheller2013-09-301-0/+8
| | | | llvm-svn: 191664
* [SystemZ] Revert r191661: Add definitions of LFH and STFHRichard Sandiford2013-09-305-134/+0
| | | | | | | | For some reason, adding definitions for these load and store instructions changed whether some of the build bots matched comparisons as signed or unsigned. llvm-svn: 191663
* [LSan] Rework r191522 - treat allocations with short stack traces as liveAlexey Samsonov2013-09-302-8/+8
| | | | llvm-svn: 191662
* [SystemZ] Add definitions of LFH and STFHRichard Sandiford2013-09-305-0/+134
| | | | llvm-svn: 191661
* [SystemZ] Add GRH32 for the high word of a GR64Richard Sandiford2013-09-306-14/+38
| | | | | | | | | The only thing this does on its own is make the definitions of RISB[HL]G a bit more precise. Those instructions are only used by the MC layer at the moment, so no behavioral change is intended. The class is needed by later patches though. llvm-svn: 191660
* [SystemZ] Rename subregs and add subreg_h32Richard Sandiford2013-09-309-60/+61
| | | | | | | | | | | | | Use subreg_hNN and subreg_lNN for the high and low NN bits of a register. List the low registers first, so that subreg_l32 also means the low 32 bits of a 128-bit register. Floats are stored in the upper 32 bits of a 64-bit register, so they should use subreg_h32 rather than subreg_l32. No behavioral change intended. llvm-svn: 191659
* [mips] Fix a broken link to mips.com in the documentation.Daniel Sanders2013-09-301-1/+1
| | | | | | It now points to the equivalent page on imgtec.com llvm-svn: 191658
* [CMake] Put libcxx-specific module directories to the front of ↵Alexey Samsonov2013-09-301-1/+1
| | | | | | | | | | CMAKE_MODULE_PATH. Otherwise if libcxx is built as an LLVM external project (after r191624), "include(config-ix)" will include config-ix.cmake from LLVM, not from libcxx, which will result in misconfigured build tree. llvm-svn: 191657
* [SystemZ] Add change missing from previous commitRichard Sandiford2013-09-301-1/+1
| | | | llvm-svn: 191656
* [SystemZ] Rename 32-bit GPR registersRichard Sandiford2013-09-306-20/+20
| | | | | | | | I'm about to add support for high-word operations, so it seemed better for the low-word registers to have names like R0L rather than R0W. No behavioral change intended. llvm-svn: 191655
* clang-format: Improve alignment after 'return'.Daniel Jasper2013-09-303-9/+17
| | | | | | | | | | | | | | | | | Previously, comments, could totally confuse it. Before: return // true if code is one of a or b. code == a || code == b; After: return // true if code is one of a or b. code == a || code == b; llvm-svn: 191654
* Add a bunch of other GCC '-f' options and ignore them. This covers everyChandler Carruth2013-09-301-1/+18
| | | | | | | | | | such option I've been able to find in the wild in our build system. Note that I haven't added test cases for this. I can do so if folks want, but they're *really* boring considering that this is all generated code to parse and ignore unsued options. llvm-svn: 191653
* Filter out repeated sections from the X86 disassembler modRMTable. Saves ↵Craig Topper2013-09-302-87/+67
| | | | | | about ~43K from a released build. Unfortunately the disassembler tables are still upwards of 800K. llvm-svn: 191652
* Switch one of the ignored boolean flag multiclasses to not have an 'f'Chandler Carruth2013-09-301-13/+13
| | | | | | | prefix. Sort the ignored boolean 'f' flags at the bottom of this file. No functionality changed. llvm-svn: 191651
* Add a few more FMA4 disassembler test cases to match the scalar set with ↵Craig Topper2013-09-301-0/+12
| | | | | | regards to combinations of L and W-bits. llvm-svn: 191650
* Various x86 disassembler fixes.Craig Topper2013-09-305-53/+66
| | | | | | | | | | | Add VEX_LIG to scalar FMA4 instructions. Use VEX_LIG in some of the inheriting checks in disassembler table generator. Make use of VEX_L_W, VEX_L_W_XS, VEX_L_W_XD contexts. Don't let VEX_L_W, VEX_L_W_XS, VEX_L_W_XD, VEX_L_W_OPSIZE inherit from their non-L forms unless VEX_LIG is set. Let VEX_L_W, VEX_L_W_XS, VEX_L_W_XD, VEX_L_W_OPSIZE inherit from all of their non-L or non-W cases. Increase ranking on VEX_L_W, VEX_L_W_XS, VEX_L_W_XD, VEX_L_W_OPSIZE so they get chosen over non-L/non-W forms. llvm-svn: 191649
* SemaTemplateDeduction.cpp: Suppress a warning. [-Wunused-variable]NAKAMURA Takumi2013-09-301-1/+1
| | | | llvm-svn: 191648
* Revert the linkage fix.Faisal Vali2013-09-293-102/+5
| | | | | | I got a bunch of buildbot failures that i don't understand - sorry. llvm-svn: 191647
* Remove an unnecessary overload from ASTLambda.h Faisal Vali2013-09-292-7/+1
| | | | | | | As Richard pointed out to me, dyn_cast is very cheap - there is no real benefit from adding cluttery overloads to only avoid that cast. No functionality change. llvm-svn: 191646
* Fix computation of linkage within nested lambdas.Faisal Vali2013-09-293-5/+102
| | | | | | | | | | When nested lambdas are used in NSDMI's - this prevents infinite recursion. See http://llvm-reviews.chandlerc.com/D1783 for Doug's approval regarding the code, and then request for some tests. [On a related note, I need this patch so as to pass tests of transformations of nested lambdas returned from member functions] llvm-svn: 191645
* ObjectSizeOffsetEvaluator: Don't run into infinite recursion if we have a ↵Benjamin Kramer2013-09-292-5/+24
| | | | | | | | cyclic GEP. Those can occur in dead code. PR17402. llvm-svn: 191644
* Remove an old workaround for a compiler that EOL'd years ago.Benjamin Kramer2013-09-291-6/+0
| | | | llvm-svn: 191643
* Add section on VS integration to the ClangFormat documentation.Manuel Klimek2013-09-291-0/+7
| | | | llvm-svn: 191642
* Fix windows newlines :(Faisal Vali2013-09-293-153/+153
| | | | llvm-svn: 191641
* Fix misspelling of -fmodules-decluse.Daniel Jasper2013-09-291-2/+2
| | | | llvm-svn: 191640
* clang-format: Fix assertion on incomplete string literals.Daniel Jasper2013-09-292-1/+10
| | | | | | | | Before, this could would lead to an assert: llvm::errs() << " << a; llvm-svn: 191639
* Plug a memory leak in a unit test. Stack allocation is sufficient here.Benjamin Kramer2013-09-291-5/+4
| | | | llvm-svn: 191638
* Deallocate type units when destroying a DWARFContext.Benjamin Kramer2013-09-291-0/+1
| | | | llvm-svn: 191637
* Allocate AtomicSDNode operands in SelectionDAG's allocator to stop leakage.Benjamin Kramer2013-09-292-12/+17
| | | | | | | SDNode destructors are never called. As an optimization use AtomicSDNode's internal storage if we have a small number of operands. llvm-svn: 191636
* Update the build documentation for Debian & UbuntuSylvestre Ledru2013-09-291-3/+5
| | | | llvm-svn: 191635
* Implement conversion to function pointer for generic lambdas without captures.Faisal Vali2013-09-299-98/+478
| | | | | | | | | | | | | | | | The general strategy is to create template versions of the conversion function and static invoker and then during template argument deduction of the conversion function, create the corresponding call-operator and static invoker specializations, and when the conversion function is marked referenced generate the body of the conversion function using the corresponding static-invoker specialization. Similarly, Codegen does something similar - when asked to emit the IR for a specialized static invoker of a generic lambda, it forwards emission to the corresponding call operator. This patch has been reviewed in person both by Doug and Richard. Richard gave me the LGTM. A few minor changes: - per Richard's request i added a simple check to gracefully inform that captures (init, explicit or default) have not been added to generic lambdas just yet (instead of the assertion violation). - I removed a few lines of code that added the call operators instantiated parameters to the currentinstantiationscope. Not only did it not handle parameter packs, but it is more relevant in the patch for nested lambdas which will follow this one, and fix that problem more comprehensively. - Doug had commented that the original implementation strategy of using the TypeSourceInfo of the call operator to create the static-invoker was flawed and allowed const as a member qualifier to creep into the type of the static-invoker. I currently kludge around it - but after my initial discussion with Doug, with a follow up session with Richard, I have added a FIXME so that a more elegant solution that involves the use of TrivialTypeSourceInfo call followed by the correct wiring of the template parameters to the functionprototypeloc is forthcoming. Thanks! llvm-svn: 191634
* Revert accidental commit.Craig Topper2013-09-291-1/+41
| | | | llvm-svn: 191633
* Change type of XOP flag in code emitters to a bool. Remove a some unneeded ↵Craig Topper2013-09-293-55/+9
| | | | | | cases from switch. llvm-svn: 191632
* Add character set related __STDC_* definitions.Ed Schouten2013-09-293-0/+27
| | | | | | | | | | | | | Clang uses UTF-16 and UTF-32 for its char16_t's and char32_t's exclusively. This means that we can define __STDC_UTF_16__ and __STDC_UTF_32__ unconditionally. While there, define __STDC_MB_MIGHT_NEQ_WC__ for FreeBSD. FreeBSD's wchar_t's don't encode characters as ISO-10646; the encoding depends on the locale used. Because the character set used might not be a superset of ASCII, we must define __STDC_MB_MIGHT_NEQ_WC__. llvm-svn: 191631
* Add comments for XOPA map introduced with TBM instructions.aCraig Topper2013-09-292-2/+4
| | | | llvm-svn: 191630
* Implement C++1y sized deallocation (n3778). This is not enabled by -std=c++1y;Richard Smith2013-09-2910-58/+260
| | | | | | | instead, it's enabled by the -cc1 flag -fsized-deallocation, until we sort out the backward-compatibility issues. llvm-svn: 191629
* Add a test that large offsets on GEPs on 32 bits targets are handled correctly.Benjamin Kramer2013-09-281-0/+10
| | | | llvm-svn: 191628
* Remove commented-out entry for ARBs, they're not in C++1y any more.Richard Smith2013-09-281-7/+0
| | | | llvm-svn: 191627
* Implement n3789; constexpr support in named function objectsMarshall Clow2013-09-2821-45/+201
| | | | llvm-svn: 191626
* Add a set of macros for using the new '[[[deprecated]]' attribute. No code ↵Marshall Clow2013-09-281-0/+8
| | | | | | changes (yet) llvm-svn: 191625
* Enable libcxx as part of the top level CMake build when it is checkedChandler Carruth2013-09-281-2/+3
| | | | | | | out in projects. This appears to be working on my system, and I will be watching build bots to see if there are any issues on other platforms. llvm-svn: 191624
* The second parameter of nexttoward is always long double.Benjamin Kramer2013-09-282-8/+8
| | | | llvm-svn: 191623
* Documentation: minor fixes/improvements to documentation of ↵James Dennett2013-09-281-2/+5
| | | | | | DependentScopeDeclRefExpr. llvm-svn: 191622
OpenPOWER on IntegriCloud