summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Hexagon
Commit message (Collapse)AuthorAgeFilesLines
...
* [Hexagon] Modify HexagonExpandCondsets to handle subregistersKrzysztof Parzyszek2016-06-081-507/+454
| | | | | | | | | Also, switch to using functions from LiveIntervalAnalysis to update live intervals, instead of performing the updates manually. Re-committing r272045. llvm-svn: 272135
* Avoid copies of std::strings and APInt/APFloats where we only read from itBenjamin Kramer2016-06-082-2/+2
| | | | | | | | As suggested by clang-tidy's performance-unnecessary-copy-initialization. This can easily hit lifetime issues, so I audited every change and ran the tests under asan, which came back clean. llvm-svn: 272126
* Revert r272045 since GCC doesn't know how to compile it.Krzysztof Parzyszek2016-06-071-449/+507
| | | | llvm-svn: 272048
* [Hexagon] Modify HexagonExpandCondsets to handle subregistersKrzysztof Parzyszek2016-06-071-507/+449
| | | | | | | Also, switch to using functions from LiveIntervalAnalysis to update live intervals, instead of performing the updates manually. llvm-svn: 272045
* Remove bogus initialization of the PPC and Hexagon SelectionDAGISelChandler Carruth2016-06-031-19/+1
| | | | | | | | | | | | | | | | | subclasses. These are not passes proper. We don't support registering them, they can't be constructed with default arguments, and the ID is actually in a base class. Only these two targets even had any boiler plate to try to do this, and it had to be munged out of the INITIALIZE_PASS macros to work. What's worse, the boiler plate has rotted and the "name" of the pass is actually the description string now!!! =/ All of this is completely unnecessary. No other target bothers, and nothing breaks if you don't initialize them because CodeGen has an entirely separate initialization path that is somewhat more durable than relying on the implicit initialization the way the 'opt' tool does for registered passes. llvm-svn: 271650
* Use the standard INITIALIZE_PASS macro rather than hand rolling a (notChandler Carruth2016-06-031-9/+2
| | | | | | entirely correct) version of its contents. llvm-svn: 271649
* [Hexagon] Expand COPY pseudo-instructionKrzysztof Parzyszek2016-06-021-6/+11
| | | | | | | | Handle it locally instead of having the target-independent pass deal with it. The generic pass does not preserve implicit uses, which may be necessary. llvm-svn: 271520
* [RDF] Ignore implicit defs when resetting <kill> flagsKrzysztof Parzyszek2016-06-021-1/+5
| | | | llvm-svn: 271519
* [Hexagon] Disable expanding MUX instructions that define a subregisterKrzysztof Parzyszek2016-05-311-0/+5
| | | | | | | The code in HexagonExpandCondsets.cpp does not handle those cases at the moment. llvm-svn: 271281
* [Hexagon] Add option to enable subregister liveness trackingKrzysztof Parzyszek2016-05-282-0/+11
| | | | llvm-svn: 271088
* [Hexagon] Separate C8 and USR to avoid unwanted subregister compositionKrzysztof Parzyszek2016-05-282-6/+18
| | | | | | | | Composing subreg_loreg with subreg_oveflow leads to strange results with lane masks for register classes with subreg_loreg. In particular, dead lane detection generates incorrect code. llvm-svn: 271087
* [Hexagon] Use standard macros to initialize HexagonExpandCondsets passKrzysztof Parzyszek2016-05-271-12/+7
| | | | llvm-svn: 271045
* [Hexagon] Do not create passes in the constructor of HexagonPassConfigKrzysztof Parzyszek2016-05-271-9/+5
| | | | | | | When running mir tests, a pass created in that constructor would not be freed, leading to memory leaks. llvm-svn: 271043
* Avoid some copies by using const references.Benjamin Kramer2016-05-271-1/+0
| | | | | | | clang-tidy's performance-unnecessary-copy-initialization with some manual fixes. No functional changes intended. llvm-svn: 270988
* Apply clang-tidy's misc-static-assert where it makes sense.Benjamin Kramer2016-05-272-3/+3
| | | | | | | Also fold conditions into assert(0) where it makes sense. No functional change intended. llvm-svn: 270982
* [hexagon] Move BlockRanges and RDF stuff into the llvm namespace.Benjamin Kramer2016-05-2710-28/+28
| | | | | | No functional change intended. llvm-svn: 270980
* [Hexagon] Enable the post-RA schedulerKrzysztof Parzyszek2016-05-263-7/+91
| | | | | | | | | The aggressive anti-dependency breaker can rename the restored callee- saved registers. To prevent this, mark these registers are live on all paths to the return/tail-call instructions, and add implicit use operands for them to these instructions. llvm-svn: 270898
* [Hexagon] Select the aggressive anti-dependency breakerKrzysztof Parzyszek2016-05-261-0/+2
| | | | llvm-svn: 270857
* [Hexagon] Move some debug-only variable declarations into DEBUGKrzysztof Parzyszek2016-05-231-19/+21
| | | | llvm-svn: 270459
* Fix -Wunused-variable in non-Asserts buildDavid Blaikie2016-05-191-2/+1
| | | | llvm-svn: 270118
* Simplify conditional unreachable into an assertionDavid Blaikie2016-05-191-7/+3
| | | | llvm-svn: 270111
* Fix a covnersion from string to bool issue used in an assertRon Lieberman2016-05-191-1/+1
| | | | | | | Problem Was exposed by -Wstring-conversion llvm-svn: 270087
* Delete Reloc::Default.Rafael Espindola2016-05-183-8/+14
| | | | | | | | | | | | Having an enum member named Default is quite confusing: Is it distinct from the others? This patch removes that member and instead uses Optional<Reloc> in places where we have a user input that still hasn't been maped to the default value, which is now clear has no be one of the remaining 3 options. llvm-svn: 269988
* [Hexagon] Recognize "q" and "v" in inline-asm as register constraintsKrzysztof Parzyszek2016-05-182-2/+16
| | | | llvm-svn: 269933
* [Hexagon] Make getCallerSavedRegs specific to a register classKrzysztof Parzyszek2016-05-163-33/+61
| | | | llvm-svn: 269674
* [Hexagon] Simplify HexagonInstrInfo::isPredicableKrzysztof Parzyszek2016-05-161-84/+5
| | | | | | | Remove all the checks for constant extenders from isPredicable. The users of it should be the ones checking cost/profitability. llvm-svn: 269664
* [Hexagon] Remove dead nodes from SelectionDAG to avoid cyclesKrzysztof Parzyszek2016-05-131-1/+2
| | | | | | | | Recent changes to the instruction selection code exposed a problem where a dead node was not removed on time. This node had both input and output chains, which lead to an apparent cycle. llvm-svn: 269458
* [scan-build] fix dead store warnings emitted on LLVM Hexagon code baseKrzysztof Parzyszek2016-05-134-4/+0
| | | | | | | | Patch by Apelete Seketeli. Differential Revision: http://reviews.llvm.org/D19900 llvm-svn: 269415
* [MIB] Create a helper function getRegState to extract all register flagsKrzysztof Parzyszek2016-05-131-12/+0
| | | | llvm-svn: 269414
* SDAG: Implement Select instead of SelectImpl in HexagonDAGToDAGISelJustin Bogner2016-05-121-139/+189
| | | | | | | | | | | | - Where we were returning a node before, call ReplaceNode instead. - Where we had already replaced all uses and we returned a node, just remove the dead node instead. - Where we would return null to fall back to another selector, rename the method to try* and return a bool for success. Part of llvm.org/pr26808. llvm-svn: 269358
* SDAG: Clean up a dangling node in HexagonISelDAGToDAG::SelectImplJustin Bogner2016-05-121-1/+1
| | | | | | | | | When we convert to the void Select interface, leaving unreferenced nodes around won't be allowed anymore. Part of llvm.org/pr26808. llvm-svn: 269355
* [Hexagon] Expand VSelect pseudo instructionsKrzysztof Parzyszek2016-05-121-0/+38
| | | | llvm-svn: 269328
* [Hexagon] Properly handle instruction selection of vsplat intrinsicsKrzysztof Parzyszek2016-05-121-2/+3
| | | | llvm-svn: 269312
* [Hexagon] Add a debug option to disable all backend optimizationsKrzysztof Parzyszek2016-05-111-1/+4
| | | | llvm-svn: 269192
* [Hexagon] Use offsets relative to FP+8 in .cfi_offset instructionsKrzysztof Parzyszek2016-05-111-5/+19
| | | | | | | | When generating .cfi_offset instructions, make sure that the offset is calculated with respect to the register used to define the CFA (which is currently always FP+8). llvm-svn: 269191
* SDAG: Avoid relying on the return value of SelectCode in Hexagon. NFCJustin Bogner2016-05-101-3/+11
| | | | | | | | | | This is a bit of a spot fix for now. I'll try to fix this up more comprehensively soon. This is part of the work to have Select return void instead of an SDNode *, which is in turn part of llvm.org/pr26808. llvm-svn: 269112
* CodeGen: Move TargetPassConfig from Passes.h to an own header; NFCMatthias Braun2016-05-101-0/+1
| | | | | | | | Many files include Passes.h but only a fraction needs to know about the TargetPassConfig class. Move it into an own header. Also rename Passes.cpp to TargetPassConfig.cpp while we are at it. llvm-svn: 269011
* [Hexagon] Treat all conditional branches as predicted (not-taken by default)Krzysztof Parzyszek2016-05-092-8/+52
| | | | llvm-svn: 268946
* [Hexagon] Be careful about anti-dependencies with a call in packetizerKrzysztof Parzyszek2016-05-061-2/+24
| | | | | | | | | | | In a case like J2_callr <ga:@foo>, %R0<imp-use>, ... R0<def> = ... the anti-dependency on R0 cannot be ignored and the two instructions cannot be packetized together, since if they were, the assignment to R0 would take place before the call. llvm-svn: 268776
* SDAG: Rename Select->SelectImpl and repurpose Select as returning voidJustin Bogner2016-05-051-2/+2
| | | | | | | | | | | | | | This is a step towards removing the rampant undefined behaviour in SelectionDAG, which is a part of llvm.org/PR26808. We rename SelectionDAGISel::Select to SelectImpl and update targets to match, and then change Select to return void and consolidate the sketchy behaviour we're trying to get away from there. Next, we'll update backends to implement `void Select(...)` instead of SelectImpl and eventually drop the base Select implementation. llvm-svn: 268693
* [scan-build] fix warnings emitted on LLVM Hexagon code baseKrzysztof Parzyszek2016-05-053-1/+3
| | | | | | | | Patch by Apelete Seketeli. Differential Revision: http://reviews.llvm.org/D19968 llvm-svn: 268691
* [Hexagon] Fix the offset ranges for vector memory instructionsKrzysztof Parzyszek2016-05-051-8/+8
| | | | llvm-svn: 268690
* Touch Hexagon/CMakeLists.txt to regenerate build files, since r268641 ↵NAKAMURA Takumi2016-05-051-1/+1
| | | | | | | complains of missing HexagonAlias.td on ninja. FIXME: TableGen.cmake globs *.td(s) with wildcards for deps. It is not good. llvm-svn: 268666
* [Hexagon] Add aliases for vector loads/stores with no explicit offsetKrzysztof Parzyszek2016-05-051-0/+79
| | | | | | The mem(r0) instructions are treated as mem(r0+#0). llvm-svn: 268661
* [Hexagon] Merge HexagonAlias.td into HexagonInstrAlias.td, NFCKrzysztof Parzyszek2016-05-053-95/+81
| | | | llvm-svn: 268641
* [Hexagon] Handle operand type differences for A2_tfrpiKrzysztof Parzyszek2016-05-051-1/+16
| | | | | | | | | | The instruction A2_tfrpi has a 64-bit operand, while the corresponding intrinsic takes a 32-bit value. The actual value has only 8 significant bits, so the difference is only in the type used to represent it. In order to map the intrinsic to the instruction, the operand needs to be extended to the correct type. llvm-svn: 268635
* Fix NDEBUG build: variables used only in debug code causing compile errorKrzysztof Parzyszek2016-04-291-4/+8
| | | | llvm-svn: 268057
* [Hexagon] Optimize addressing modes for load/storeKrzysztof Parzyszek2016-04-298-1/+848
| | | | | | Patch by Jyotsna Verma. llvm-svn: 268051
* Unify XDEBUG and EXPENSIVE_CHECKS (into the latter), and add an option to ↵Filipe Cabecinhas2016-04-291-1/+1
| | | | | | | | | | | | | | | | | | | the cmake build to enable them. Summary: Historically, we had a switch in the Makefiles for turning on "expensive checks". This has never been ported to the cmake build, but the (dead-ish) code is still around. This will also make it easier to turn it on in buildbots. Reviewers: chandlerc Subscribers: jyknight, mzolotukhin, RKSimon, gberry, llvm-commits Differential Revision: http://reviews.llvm.org/D19723 llvm-svn: 268050
* [RDF] Recognize tail calls in graph creationKrzysztof Parzyszek2016-04-281-4/+20
| | | | llvm-svn: 267939
OpenPOWER on IntegriCloud