summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Replace vector<unique_ptr<File> with unique_ptr<File>.Rui Ueyama2015-01-134-20/+16
| | | | | | | Because each InputElement has exactly one File, we no longer have to use a vector to store pointers to Files. llvm-svn: 225814
* When attribute 'optnone' appears on the same declaration with aPaul Robinson2015-01-134-32/+30
| | | | | | | | | | | | conflicting attribute, warn about the conflict and pick a "winning" attribute to preserve, instead of emitting an error. This matches the behavior when the conflicting attributes are on different declarations. Along the way I discovered that conflicts involving __forceinline were reported as 'always_inline' (alternate spelling, same attribute) so fixed that up to report the attribute as spelled in the source. llvm-svn: 225813
* Fix maxLoopDepth computation in ScopInfoDavid Peixotto2015-01-132-0/+82
| | | | | | | | | | | | | | | | The max loop depth was incorrectly computed for scops that contain a block from a loop but do not contain the entire loop. We need to check that the full loop is contained in the region when computing the max loop depth. These scops occur when a region containing an inner loop is expanded to include some blocks from the outer loop, but it cannot be fully expanded to contain the outer loop because the region containing the outer loop is invalid. Differential Revision: http://reviews.llvm.org/D6913 llvm-svn: 225812
* Revert "r225808 - [PowerPC] Add StackMap/PatchPoint support"Hal Finkel2015-01-1317-1116/+98
| | | | | | | Reverting this while I investiage buildbot failures (segfaulting in GetCostForDef at ScheduleDAGRRList.cpp:314). llvm-svn: 225811
* Update multiline.ll testcase to handle (ppc64le) .localentry directiveWill Schmidt2015-01-131-1/+1
| | | | | | | | | | | | The ppc64le platform will emit a .localentry directive. This is triggering a false-positive against a CHECK-NOT: .loc in multiline.ll. Add a space "{{ }}" to the check-not line to allow for arguments, and prevent .localentry from matching. Differential Revision: http://reviews.llvm.org/D6935 llvm-svn: 225810
* [PowerPC] Add missing override keywordHal Finkel2015-01-131-1/+1
| | | | llvm-svn: 225809
* [PowerPC] Add StackMap/PatchPoint supportHal Finkel2015-01-1317-98/+1116
| | | | | | | | | | | | | | | | | | | | | | | | | This commit does two things: 1. Refactors PPCFastISel to use more of the common infrastructure for call lowering (this lets us take advantage of this common code for lowering some common intrinsics, stackmap/patchpoint among them). 2. Adds support for stackmap/patchpoint lowering. For the most part, this is very similar to the support in the AArch64 target, with the obvious differences (different registers, NOP instructions, etc.). The test cases are adapted from the AArch64 test cases. One difference of note is that the patchpoint call sequence takes 24 bytes, so you can't use less than that (on AArch64 you can go down to 16). Also, as noted in the docs, we take the patchpoint address to be the actual code address (assuming the call is local in the TOC-sharing sense), which should yield higher performance than generating the full cross-DSO indirect-call sequence and is likely just as useful for JITed code (if not, we'll change it). StackMaps and Patchpoints are still marked as experimental, and so this support is doubly experimental. So go ahead and experiment! llvm-svn: 225808
* [StackMaps] Use CurrentFnSymForSizeHal Finkel2015-01-131-1/+1
| | | | | | | | When computing the call-site offset, use AP.CurrentFnSymForSize instead of AP.CurrentFnSym. There should be no change for other targets, but this is necessary for generating valid expressions for PPC64/ELF. llvm-svn: 225807
* [StackMaps] Mark in CallLoweringInfo when lowering a patchpointHal Finkel2015-01-135-6/+22
| | | | | | | | | | | | | | | While, generally speaking, the process of lowering arguments for a patchpoint is the same as lowering a regular indirect call, on some targets it may not be exactly the same. Targets may not, for example, want to add additional register dependencies that apply only to making cross-DSO calls through linker stubs, may not want to load additional registers out of function descriptors, and may not want to add additional side-effect-causing instructions that cannot be removed later with the call itself being generated. The PowerPC target will use this in a future commit (for all of the reasons stated above). llvm-svn: 225806
* [StackMaps] Allow the target to pre-process the live-out maskHal Finkel2015-01-132-0/+7
| | | | | | | | | | | | | | Some targets, PowerPC for example, have pseudo-registers (such as that used to represent the rounding mode), that don't have DWARF register numbers or a register class. These are used only for internal dependency tracking, and should not appear in the recorded live-outs. This adds a callback allowing the target to pre-process the live-out mask in order to remove these kinds of registers so that the StackMaps code does not complain about them and/or attempt to include them in the output. This will be used by the PowerPC target in a future commit. llvm-svn: 225805
* [PowerPC] Split the blr definition into BLR and BLR8Hal Finkel2015-01-135-6/+13
| | | | | | | | | | We really need a separate 64-bit version of this instruction so that it can be marked as clobbering LR8 (instead of just LR). No change in functionality (although the verifier might be slightly happier), however, it is required for stackmap/patchpoint support. Thus, this will be covered by stackmap test cases once those are added. llvm-svn: 225804
* Inherit attributes when infering a framework moduleBen Langmuir2015-01-135-27/+52
| | | | | | | | | | If a module map contains framework module * [extern_c] {} We will now infer [extern_c] on the inferred framework modules (we already inferred [system] as a special case). llvm-svn: 225803
* Handle [extern_c] attribute in module printerBen Langmuir2015-01-131-2/+5
| | | | | | | I'm not sure why we have OS.indent(Indent+2) for the system attribute, but presumably we want the same behaviour for all attributes... llvm-svn: 225802
* Remove unused method canInferFrameworkModuleBen Langmuir2015-01-132-40/+0
| | | | llvm-svn: 225801
* [PowerPC] Add DWARF numbers for CA (XER), etc.Hal Finkel2015-01-131-5/+4
| | | | | | | | | | | | For registers that have DWARF numbers (like CA, which is really part of XER), add them. Also, RM is not an SPR, and the declaration hack (where it is declared as an SPR with an arbitrary number) is not needed, so just declare it as a register. NFC; although CA's register number will be needed when stackmap/patchpoint support is added. llvm-svn: 225800
* Make regex::assign not clobber the regex in case of failure. Fixes PR#22213Marshall Clow2015-01-132-3/+10
| | | | llvm-svn: 225799
* [mips][microMIPS] Fix issue with 16b instructions in jr instruction delay slotJozef Kolek2015-01-132-5/+64
| | | | | | | | | 16 bit instructions are not allowed in jr delay slot. Same stands for PseudoIndirectBranch and PseudoReturn. Differential Revision: http://reviews.llvm.org/D6815 llvm-svn: 225798
* Added a Mips lld milestone to the release notes for the 3.6 release.Daniel Sanders2015-01-131-4/+5
| | | | llvm-svn: 225797
* fixed the missed bracket introduced by checkin rev 225792Andrey Churbanov2015-01-131-1/+1
| | | | llvm-svn: 225796
* Added TLI hook for isFPExtFree. Some of the FMA combine heuristics are now ↵Olivier Sallenave2015-01-134-63/+85
| | | | | | guarded with that hook. llvm-svn: 225795
* This patch enables the use of KMP_AFFINITY=balanced on non-MIC ↵Andrey Churbanov2015-01-135-39/+19
| | | | | | Architectures. The restriction for using balanced affinity on non-MIC architectures is it only works for one-package machines. llvm-svn: 225794
* small fixes to the hierarchical barrierAndrey Churbanov2015-01-131-1/+4
| | | | llvm-svn: 225793
* aarch64 port sent by C. BergstromAndrey Churbanov2015-01-1318-88/+139
| | | | llvm-svn: 225792
* Revert "SLPVectorizer: Cache results from memory alias checking."Erik Eckstein2015-01-131-49/+19
| | | | | | The alias cache has a problem of incorrect collisions in case a new instruction is allocated at the same address as a previously deleted instruction. llvm-svn: 225790
* Return the architecture by probing predefined compiler macrosAndrey Churbanov2015-01-132-13/+77
| | | | llvm-svn: 225789
* Silence warnings about unknown pragmas for compilers that are not Clang. NFC.Aaron Ballman2015-01-131-1/+4
| | | | llvm-svn: 225788
* [OCaml] Allow out-of-tree builds of LLVM bindings.Peter Zotov2015-01-131-2/+9
| | | | | | | | | | | | In order to use this feature, configure LLVM as usual, but then build and install it as: make all install SYSTEM_LLVM_CONFIG=llvm-config where llvm-config is the llvm-config binary installed on your system (possibly llvm-config-VERSION on e.g. Debian). llvm-svn: 225787
* SLPVectorizer: Cache results from memory alias checking.Erik Eckstein2015-01-131-19/+49
| | | | | | | This speeds up the dependency calculations for blocks with many load/store/call instructions. Beside the improved runtime, there is no functional change. llvm-svn: 225786
* [PM] In the PassManager template, remove a pointless indirection throughChandler Carruth2015-01-131-9/+4
| | | | | | | | | | a nested class template for the PassModel, and use the T-suffix for the two typedefs to match the code in the AnalysisManager. This is the last of the fairly fundamental code cleanups here. Will be focusing on the printing of analyses next to finish that aspect off. llvm-svn: 225785
* [PM] Remove the 'AnalysisManagerT' type parameter from numerous layersChandler Carruth2015-01-132-45/+37
| | | | | | | | | | | | | | of templates in the new pass manager. The analysis manager is now itself just a template predicated on the IR unit. This makes lots of the templates really trivial and more clear: they are all parameterized on a single type, the IR unit's type. Everything else is a function of that. To me, this is a really nice cleanup of the APIs and removes a layer of 'magic' and 'indirection' that really wasn't there and just got in the way of understanding what is going on here. llvm-svn: 225784
* [PM] Refactor the new pass manager to use a single template to implementChandler Carruth2015-01-136-390/+243
| | | | | | | | | | | | | | | | | | | | | | | the generic functionality of the pass managers themselves. In the new infrastructure, the pass "manager" isn't actually interesting at all. It just pipelines a single chunk of IR through N passes. We don't need to know anything about the IR or the passes to do this really and we can replace the 3 implementations of the exact same functionality with a single generic PassManager template, complementing the single generic AnalysisManager template. I've left typedefs in place to give convenient names to the various obvious instantiations of the template. With this, I think I've nuked almost all of the redundant logic in the managers, and I think the overall design is actually simpler for having single templates that clearly indicate there is no special logic here. The logging is made somewhat more annoying by this change, but I don't think the difference is worth having heavy-weight traits to help log things. llvm-svn: 225783
* [mips] Fix va_arg() for pointer types on big-endian N32.Daniel Sanders2015-01-133-6/+61
| | | | | | | | | | | | | | | | | | | | | Summary: The Mips ABI's treat pointers in the same way as integers. They are sign-extended to 32-bit for O32, and 64-bit for N32/N64. This doesn't matter for O32 and N64 where pointers are already the correct width but it does matter for big-endian N32, where pointers are 32-bit and need promoting. The caller side is already passing pointers correctly. This patch corrects the callee. Reviewers: vmedic, atanasyan Reviewed By: atanasyan Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D6812 llvm-svn: 225782
* Revert "Sema: An extern declaration can't be a redeclaration of a parameter"David Majnemer2015-01-132-6/+4
| | | | | | | This reverts commit r225780, we can't compile line 181 in sanitizer_platform_limits_posix.cc with this commit. llvm-svn: 225781
* Sema: An extern declaration can't be a redeclaration of a parameterDavid Majnemer2015-01-132-4/+6
| | | | | | | | | | In the following: void f(int x) { extern int x; } The second declaration of 'x' shouldn't be considered a redeclaration of the parameter. llvm-svn: 225780
* Update release notes wrt OCaml bindings.Peter Zotov2015-01-131-0/+26
| | | | llvm-svn: 225779
* [OCaml] Use $CAMLORIGIN, an rpath-$ORIGIN-like mechanism in OCaml.Peter Zotov2015-01-132-4/+12
| | | | | | | | | | | | | | | As a result, installations of LLVM in non-standard locations will not require passing custom -ccopt -L flags when building the binary, nor absolute paths would be embedded in the cma/cmxa files. Additionally, the executables will not require changes to LD_LIBRARY_PATH, although CAML_LD_LIBRARY_PATH still has to be set for ocamlc without -custom. See http://caml.inria.fr/mantis/view.php?id=6642. Note that the patch is approved, but not merged yet. It will be released in 4.03 and likely 4.02. llvm-svn: 225778
* Update clang-format.el to use xml output and patch in the returned chunks.Manuel Klimek2015-01-131-46/+86
| | | | | | | | | This leads to better undo behavior and avoids window content jumping around. Patch by Johann Klähn. llvm-svn: 225777
* Parse: Switch to using EOF tokens for late parsed attributesDavid Majnemer2015-01-131-12/+15
| | | | | | | | | The EOF token injection technique is preferable to using isBeforeInTranslationUnit to determine whether or not additional cleanup is needed. I don't have an example off-hand that requires it but it is nicer nonetheless. llvm-svn: 225776
* IR/MetadataTest.cpp: Appease msc17 to avoid initializer list.NAKAMURA Takumi2015-01-131-1/+1
| | | | llvm-svn: 225775
* Parse: Don't crash when default argument in typedef consists of sole '='David Majnemer2015-01-132-2/+8
| | | | | | | | We'd crash trying to make the SourceRange for the tokens we'd like to highlight. Don't assume there is more than one token makes up the default argument. llvm-svn: 225774
* Enhance the eh_frame unwind instruction augmenter so thatJason Molenda2015-01-131-6/+46
| | | | | | | | | it will do the right thing on x86 routines with a mid-function epilogue sequence (where the unwind rules need to be reinstalled after the epilogue has completed). <rdar://problem/19417410> llvm-svn: 225773
* Peephole opt needs optimizeSelect() to keep track of newly created MIsMehdi Amini2015-01-134-7/+27
| | | | | | | | | | | | | | | Peephole optimizer is scanning a basic block forward. At some point it needs to answer the question "given a pointer to an MI in the current BB, is it located before or after the current instruction". To perform this, it keeps a set of the MIs already seen during the scan, if a MI is not in the set, it is assumed to be after. It means that newly created MIs have to be inserted in the set as well. This commit passes the set as an argument to the target-dependent optimizeSelect() so that it can properly update the set with the (potentially) newly created MIs. llvm-svn: 225772
* Add an additional check to UnwindAssembly_x86::AugmentUnwindPlanFromCallSite Jason Molenda2015-01-133-17/+45
| | | | | | | | | | | | | | | | which will verify if the eh_frame instructions include details about the prologue or not. Both clang and gcc include prologue instructions but there's no requirement for them to do so -- and I'm sure we'll have to interoperate with a compiler that doesn't generate prologue info at some point. I don't have any compilers that omit the prologue instructions so the testing was of the "makre sure augmented unwind info is still created". With an eh_frame without prologue, this code should reject the augmentation scheme altogether and we should fall back to using assembly instruction profiling. llvm-svn: 225771
* Change the x86 assembly instruction unwind parser toJason Molenda2015-01-135-201/+216
| | | | | | | | | | | | | | | step through the complete function looking for any epilogue instructions. If we find an epilogue sequence, re-instate the correct unwind instructions if there is more code past that epilogue -- this will correctly handle an x86 function with multiple epilogues in it. NB there is still a bug with the "eh_frame augmented" UnwindPlans and mid-function epilogues. Looking at that next. <rdar://problem/18863406> llvm-svn: 225770
* Remove dead code.Rui Ueyama2015-01-134-53/+1
| | | | | | | Now every InputElement has exactly one File in it, so "expand" method is now no-op. llvm-svn: 225769
* Parse: Don't crash if missing an initializer expressionDavid Majnemer2015-01-132-1/+6
| | | | llvm-svn: 225768
* Remove InputGraph::registerObserver.Rui Ueyama2015-01-137-81/+62
| | | | | | | | | | | | PECOFF was the only user of the API, and the reason why we created the API is because, although the driver creates a list of input files, it has no knowledge on what files are being created. It was because everything was hidden behind the InputGraph abstraction. Now the driver knows what that's doing. We no longer need this indirection to get the file list being processed. llvm-svn: 225767
* Remove InputGraph::dump().Rui Ueyama2015-01-133-13/+0
| | | | | | This is dead code. llvm-svn: 225766
* Parse: use the EOF token method to lex inline method bodiesDavid Majnemer2015-01-132-22/+25
| | | | | | | | Mark the end of the method body with an EOF token, collect it once we expect to be done with method body parsing. No functionality change intended. llvm-svn: 225765
* Convert other drivers to use WrapperNode.Rui Ueyama2015-01-1336-602/+294
| | | | llvm-svn: 225764
OpenPOWER on IntegriCloud