summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* [MC] Merge VK_PPC_TPREL in to generic VK_TPREL.Colin LeMahieu2016-02-106-38/+36
| | | | | | Differential Revision: http://reviews.llvm.org/D17038 llvm-svn: 260401
* [PGO] Indirect-call profile annotation in IR level profilingRong Xu2016-02-101-5/+46
| | | | | | | | | | This patch reads the indirect-call value records in the profile and makes the annotation in the indirect-call instruction. This is for IR level profile instrumentation. Differential Revision: http://reviews.llvm.org/D16935 llvm-svn: 260400
* AMDGPU: Fix indentation and variable namesMatt Arsenault2016-02-101-34/+31
| | | | llvm-svn: 260399
* AMDGPU: Split R600 and SI load loweringMatt Arsenault2016-02-105-103/+95
| | | | | | | These weren't actually sharing anything in the common LowerLOAD. llvm-svn: 260398
* [ThinLTO] Move global processing from Linker to TransformUtils (NFC)Teresa Johnson2016-02-104-294/+245
| | | | | | | | | | | | | | | Summary: As discussed on IRC, move the ThinLTOGlobalProcessing code out of the linker, and into TransformUtils. The name of the class is changed to FunctionImportGlobalProcessing. Reviewers: joker.eph, rafael Subscribers: joker.eph, llvm-commits Differential Revision: http://reviews.llvm.org/D17081 llvm-svn: 260395
* [SPARC] Repair floating-point condition encodings in assembly parser.James Y Knight2016-02-101-3/+3
| | | | | | | | | | | | | | | The encodings for floating point conditions A(lways) and N(ever) were incorrectly specified for the assembly parser, per Sparc manual v8 page 121. This change corrects that mistake. Also, strangely, all of the branch instructions already had MC test cases, except for the broken ones. Added the tests. Patch by Chris Dewhurst Differential Revision: http://reviews.llvm.org/D17074 llvm-svn: 260390
* Rename a member variable to be more accurate with how it is usedDaniel Berlin2016-02-101-7/+5
| | | | llvm-svn: 260389
* Constify two functions, make them accessible to unit testsDaniel Berlin2016-02-101-5/+9
| | | | llvm-svn: 260387
* [PGO] Differentiate Clang instrumentation and IR level instrumentation profilesRong Xu2016-02-103-6/+57
| | | | | | | | | | | | | | | | | | | | This patch uses one bit in profile version to differentiate Clang instrumentation and IR level instrumentation profiles. PGOInstrumenation generates a COMDAT variable __llvm_profile_raw_version so that the compiler runtime can set the right profile kind. For Maco-O platform, we generate the variable as linkonce_odr linkage as COMDAT is not supported. PGOInstrumenation now checks this bit to make sure it's an IR level instrumentation profile. The patch was submitted as r260164 but reverted due to a Darwin test breakage. Original Differential Revision: http://reviews.llvm.org/D15540 Differential Revision: http://reviews.llvm.org/D17020 llvm-svn: 260385
* [AArch64] This bit of logic is specific to pairing. NFC.Chad Rosier2016-02-101-8/+10
| | | | llvm-svn: 260383
* Fix VST_CODE_* bitcode id comments (NFC)Teresa Johnson2016-02-102-18/+18
| | | | llvm-svn: 260382
* [X86] Fix stack alignment for MCU target, by Anton Nadolskiy.Andrey Turetskiy2016-02-101-2/+7
| | | | | | | | This patch fixes stack alignments for MCU (should be aligned to 4 bytes). Differential Revision: http://reviews.llvm.org/D15646 llvm-svn: 260375
* [AVR] Add instruction definitionsDylan McKay2016-02-105-3/+2569
| | | | | | | | | | | | Summary: Add the AVR instruction tablegen definitions. Reviewers: stoklund, hfinkel, dsanders, arsenm, vkalintiris Subscribers: dylanmckay, agnat, rjordans, llvm-commits Differential Revision: http://reviews.llvm.org/D15703 llvm-svn: 260363
* X86: Remove useless semicolonJF Bastien2016-02-101-1/+1
| | | | llvm-svn: 260359
* StructurizeCFG: Initialize SkipUniformRegions in the default constructorTom Stellard2016-02-101-1/+1
| | | | | | This should fix some random bot failures caused by r260336. llvm-svn: 260342
* [Orc] Add lazy-JITting support for i386.Lang Hames2016-02-102-0/+136
| | | | | | | | | | | This patch adds a new class, OrcI386, which contains the hooks needed to support lazy-JITing on i386 (currently only for Pentium 2 or above, as the JIT re-entry code uses the FXSAVE/FXRSTOR instructions). Support for i386 is enabled in the LLI lazy JIT and the Orc C API, and regression and unit tests are enabled for this architecture. llvm-svn: 260338
* StructurizeCFG: Add an option for skipping regions with only uniform branchesTom Stellard2016-02-101-3/+38
| | | | | | | | | | | | | | Summary: Tests for this will be added once the AMDGPU backend enables this option. Reviewers: arsenm Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D16602 llvm-svn: 260336
* Add support for struct in C API testAmaury Sechet2016-02-101-0/+22
| | | | | | | | | | | | Summary: As per title. This also include extra support for insertvalue and extracvalue. Reviewers: bogner, chandlerc, echristo, dblaikie, joker.eph, Wallbraker Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D17055 llvm-svn: 260335
* Add binding for counting argument and find called value of call and invoke ↵Amaury Sechet2016-02-101-12/+11
| | | | | | | | | | | | instruction from the C API. Summary: As per title. This remove the need to rely on internal knowledge of call and invoke instruction to find called value and argument count. Reviewers: bogner, chandlerc, echristo, dblaikie, joker.eph, Wallbraker Differential Revision: http://reviews.llvm.org/D17054 llvm-svn: 260332
* [x86] convert masked load of exactly one element to scalar loadSanjay Patel2016-02-091-0/+43
| | | | | | | This is the load counterpart to the store optimization that was added in: http://reviews.llvm.org/rL260145 llvm-svn: 260325
* Add convergent-removing bits to FunctionAttrs pass.Justin Lebar2016-02-091-0/+63
| | | | | | | | | | | | | | | | | Summary: Remove the convergent attribute on any functions which provably do not contain or invoke any convergent functions. After this change, we'll be able to modify clang to conservatively add 'convergent' to all functions when compiling CUDA. Reviewers: jingyue, joker.eph Subscribers: llvm-commits, tra, jhen, hfinkel, resistor, chandlerc, arsenm Differential Revision: http://reviews.llvm.org/D17013 llvm-svn: 260319
* Fix GCC build.Peter Collingbourne2016-02-091-0/+4
| | | | llvm-svn: 260317
* [CodeGen] Prefer "if (SDValue R = ...)" to "if (R.getNode())". NFCI.Ahmed Bougacha2016-02-0914-167/+98
| | | | llvm-svn: 260316
* [X86] Don't reuse an unrelated variable, create a new one. NFC.Ahmed Bougacha2016-02-091-26/+28
| | | | | | | Using Op makes it look like we're doing something with it. We're really not. llvm-svn: 260315
* [X86] Remove unnecessary assignment. NFC.Ahmed Bougacha2016-02-091-1/+0
| | | | llvm-svn: 260314
* Add C binding for AllocaInst::getAllocatedTypeAmaury Sechet2016-02-091-0/+6
| | | | | | | | | | | | | | | Summary: Comes with an awesome test. Depends on D16912 Reviewers: bogner, chandlerc, echristo, dblaikie, joker.eph, Wallbraker Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D16942 llvm-svn: 260313
* WholeProgramDevirt: introduce.Peter Collingbourne2016-02-094-0/+739
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This pass implements whole program optimization of virtual calls in cases where we know (via bitset information) that the list of callees is fixed. This includes the following: - Single implementation devirtualization: if a virtual call has a single possible callee, replace all calls with a direct call to that callee. - Virtual constant propagation: if the virtual function's return type is an integer <=64 bits and all possible callees are readnone, for each class and each list of constant arguments: evaluate the function, store the return value alongside the virtual table, and rewrite each virtual call as a load from the virtual table. - Uniform return value optimization: if the conditions for virtual constant propagation hold and each function returns the same constant value, replace each virtual call with that constant. - Unique return value optimization for i1 return values: if the conditions for virtual constant propagation hold and a single vtable's function returns 0, or a single vtable's function returns 1, replace each virtual call with a comparison of the vptr against that vtable's address. Differential Revision: http://reviews.llvm.org/D16795 llvm-svn: 260312
* Improve the C API echo test tool to emit basic block is the right order.Amaury Sechet2016-02-091-0/+4
| | | | | | | | | | | | Summary: As per title. Also add a facility method to get the name of a basic block from the C API. Reviewers: bogner, chandlerc, echristo, dblaikie, joker.eph, Wallbraker Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D16912 llvm-svn: 260309
* [mips] Extend MipsAsmParser class to handle %got(sym + const) expressionsSimon Atanasyan2016-02-091-0/+1
| | | | | | | | | Now the parser supports `%got(sym)` expressions only but `%got(sym + const)` variant is also valid and accepted by GAS. Differential Revision: http://reviews.llvm.org/D16885 llvm-svn: 260305
* [MemoryBuiltins] Fix an issue with hasNoAliasAttrSanjoy Das2016-02-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | Summary: `hasNoAliasAttr` is buggy: it checks to see if the called function has a `noalias` attribute, which is incorrect since functions are not even allowed to have the `noalias` attribute. The comment on its only caller, `llvm::isNoAliasFn`, makes it pretty clear that the intention to do the `noalias` check on the return value, and not the callee. Unfortunately I couldn't find a way to test this upstream -- fixing this does not change the observable behavior of any of the passes that use this. This is not very surprising, since `noalias` does not tell anything about the contents of the allocated memory (so, e.g., you still cannot fold loads). I'll be happy to be proven wrong though. Reviewers: chandlerc, reames Subscribers: mcrosier, llvm-commits Differential Revision: http://reviews.llvm.org/D17037 llvm-svn: 260298
* [Verifier] Add checks for masked.load and masked.store intrinsicsPhilip Reames2016-02-091-0/+38
| | | | | | While trying to track down what appears to be a LoopVectorizer bug, I noticed that we had no validation of the correctness of calls emitted to @llvm.masked.load and @llvm.masked.store. This meant malformed IR was showing up much much later than it should. Hopefully, having Verifier rules in place will make this easier to isolate. llvm-svn: 260296
* [SelectionDAG] make getMemBasePlusOffset() accessible; NFCISanjay Patel2016-02-092-50/+32
| | | | | | | | | I reinvented this functionality in http://reviews.llvm.org/D16828 because it was hidden away as a static function. The changes in x86 are not based on a complete audit. I suspect there are other possible uses there, and there are almost certainly more potential users in other targets. llvm-svn: 260295
* [AArch64] This check is specific to merging instructions. NFC.Chad Rosier2016-02-091-4/+4
| | | | llvm-svn: 260283
* [InstCombine][GC] Handle gc.relocations of vector typePhilip Reames2016-02-091-25/+22
| | | | | | | | We introduced gc.relocates of vector-of-pointer types a couple of weeks back. Somehow, I missed updating the InstCombine rule to account for this. If we hit this code path with a vector-of-pointers gc.relocate, we'd crash on a cast<PointerType>. I also took the chance to do a bit of code style cleanup. llvm-svn: 260279
* [AArch64] AArch64LoadStoreOptimizer: fix bug in pre-inc check iteratorGeoff Berry2016-02-091-8/+9
| | | | | | | | | | | | | | | Summary: Fix case where a pre-inc/dec load/store would not be formed if the add/sub that forms the inc/dec part of the operation was the first instruction in the block being examined. Reviewers: mcrosier, jmolloy, t.p.northover, junbuml Subscribers: aemerson, rengolin, mcrosier, llvm-commits Differential Revision: http://reviews.llvm.org/D16785 llvm-svn: 260275
* [AArch64] Bail even earlier if the instructions modifieds the base register. ↵Chad Rosier2016-02-091-5/+6
| | | | | | NFC. llvm-svn: 260274
* [AArch64] Simplify. NFC.Chad Rosier2016-02-091-3/+1
| | | | llvm-svn: 260273
* [AArch64] Add an assert to ensure we don't scale an offset that can't be scaled.Chad Rosier2016-02-091-1/+3
| | | | llvm-svn: 260272
* [AArch64] Add a FIXME about invalid KILL markers after the ld/st opt pass.Chad Rosier2016-02-091-0/+5
| | | | llvm-svn: 260264
* llvm-config: Add preliminary Windows supportEhsan Akhgari2016-02-091-27/+25
| | | | | | | | | | | | | | | | | Summary: This patch adds Windows support for a few of the llvm-config commands, including cflags, ldflags, libs, and system-libs. Currently llvm-config is untested, so this patch adds tests for the commands that it fixes as well. Reviewers: rnk Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D16762 llvm-svn: 260263
* [AArch64] Remove redundant calls and clang format. NFC.Chad Rosier2016-02-091-42/+40
| | | | llvm-svn: 260260
* [Hexagon] Fixing relocation generation and adding tests.Colin LeMahieu2016-02-092-182/+263
| | | | llvm-svn: 260259
* [MC] Adding GOTREL expression variant.Colin LeMahieu2016-02-091-0/+2
| | | | llvm-svn: 260258
* [AArch64] Hoist now common logic. NFC.Chad Rosier2016-02-091-13/+9
| | | | llvm-svn: 260257
* [AArch64] Rename variable to make it clear we're merging here, not pairing.Chad Rosier2016-02-091-19/+19
| | | | llvm-svn: 260256
* [AArch64] Separage the codegen logic for widening vs. pairing. NFC.Chad Rosier2016-02-091-38/+94
| | | | llvm-svn: 260249
* [FunctionAttrs] Fix SCC logic around operand bundlesSanjoy Das2016-02-091-2/+6
| | | | | | | | | | | FunctionAttrs does an "optimistic" analysis of SCCs as a unit, which means normally it is able to disregard calls from an SCC into itself. However, calls and invokes with operand bundles are allowed to have memory effects not fully described by the memory effects on the call target, so we can't be optimistic around operand-bundled calls from an SCC into itself. llvm-svn: 260244
* [AArch64] Cleanup to simplify logic when widening vs. pairing loads/stores. NFC.Chad Rosier2016-02-091-13/+50
| | | | | | | | The logic to pair instructions and merge narrow instructions has become cloogy and error prone. This patch beings to unravel these two similar, but distinct optimizations. llvm-svn: 260242
* [x86] make getOneTrueElt() a helper function ; NFCSanjay Patel2016-02-091-35/+34
| | | | | | | As mentioned in http://reviews.llvm.org/D16828 , the related masked load transform will need this logic, so I'm moving it out to make that patch smaller. llvm-svn: 260240
* [AArch64] Rename variable to improve readability. NFC.Chad Rosier2016-02-091-5/+5
| | | | llvm-svn: 260228
OpenPOWER on IntegriCloud