summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Hexagon/AsmParser
Commit message (Collapse)AuthorAgeFilesLines
...
* Refactor and cleanup Assembly Parsing / LexingNirav Dave2016-06-161-13/+12
| | | | | | | | | | | | | | | | | | | | | | | Add explicit Comment Token in Assembly Lexing for future support for outputting explicit comments from inline assembly. As part of this, CPPHash Directives are now explicitly distinguished from Hash line comments in Lexer. Line comments are recorded as EndOfStatement tokens, not Comment tokens to simplify compatibility with current TargetParsers. This slightly complicates comment output. This remove all lexing tasks out of the parser, does minor cleanup to remove extraneous newlines Asm Output, and some improvements white space handling. Reviewers: rtrieu, dwmw2, rnk Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D20009 llvm-svn: 272953
* Run clang-tidy's performance-unnecessary-copy-initialization over LLVM.Benjamin Kramer2016-06-121-2/+2
| | | | | | No functionality change intended. llvm-svn: 272516
* 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
* [Hexagon] Define certain aliases for vector instructionsKrzysztof Parzyszek2016-04-281-0/+13
| | | | | | | | | Specifically: Vd = #0 -> Vd = vxor(Vd, Vd) Vdd = #0 -> Vdd.w = vsub(Vdd.w, Vdd.w) Vdd = Vss -> Vdd = vcombine(Vss.H, Vss.L) llvm-svn: 267901
* [Hexagon] Properly recognize register alt namesKrzysztof Parzyszek2016-04-211-27/+33
| | | | llvm-svn: 267038
* [NFC] Header cleanupMehdi Amini2016-04-181-2/+0
| | | | | | | | | | | | | | Removed some unused headers, replaced some headers with forward class declarations. Found using simple scripts like this one: clear && ack --cpp -l '#include "llvm/ADT/IndexedMap.h"' | xargs grep -L 'IndexedMap[<]' | xargs grep -n --color=auto 'IndexedMap' Patch by Eugene Kosov <claprix@yandex.ru> Differential Revision: http://reviews.llvm.org/D19219 From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 266595
* [Hexagon] Modifying r262258 to only be in effect in the hand assembler path, ↵Colin LeMahieu2016-03-011-0/+16
| | | | | | not the integrated assembler. llvm-svn: 262400
* [Hexagon] Setting sign mismatch flag on expression instead of using bit tricks.Colin LeMahieu2016-02-291-16/+11
| | | | llvm-svn: 262243
* [Hexagon] Using MustExtend flag on expression instead of passing around bools.Colin LeMahieu2016-02-291-22/+20
| | | | llvm-svn: 262238
* [Hexagon] Loop instructions don't need special processing. Extension and ↵Colin LeMahieu2016-02-171-25/+0
| | | | | | fitting is performed by generic code and the comment is incorrect, loops don't have a separate extended opcode. llvm-svn: 261118
* [Hexagon] Adding relocation for code size, cold path optimization allowing a ↵Colin LeMahieu2016-02-161-0/+16
| | | | | | | | | | | | 23-bit 4-byte aligned relocation to be a valid instruction encoding. The usual way to get a 32-bit relocation is to use a constant extender which doubles the size of the instruction, 4 bytes to 8 bytes. Another way is to put a .word32 and mix code and data within a function. The disadvantage is it's not a valid instruction encoding and jumping over it causes prefetch stalls inside the hardware. This relocation packs a 23-bit value in to an "r0 = add(rX, #a)" instruction by overwriting the source register bits. Since r0 is the return value register, if this instruction is placed after a function call which return void, r0 will be filled with an undefined value, the prefetch won't be confused, and the callee can access the constant value by way of the link register. llvm-svn: 261006
* [Hexagon] Hoist nonnull assert up.Benjamin Kramer2016-02-161-1/+0
| | | | | | | | Once a pointer is turned into a reference it cannot be nullptr, clang rightfully warns about this assert being a tautology. Put the assert before the reference is created. llvm-svn: 260949
* [NFC] Fixing naming convention, lowercase start of function name.Colin LeMahieu2016-02-151-19/+19
| | | | llvm-svn: 260903
* [Hexagon] Wrapping all MCExprs inside MCOperands within HexagonMCExpr to ↵Colin LeMahieu2016-02-151-52/+71
| | | | | | simplify handling and allow flags on the expression. llvm-svn: 260902
* Replace usages of llvm::utostr_32 with just llvm::utostr. While this is less ↵Craig Topper2016-01-311-20/+20
| | | | | | efficient, its unclear the few places that were using the _32 version were doing so for efficiency. llvm-svn: 259330
* Move MCTargetAsmParser.h to llvm/MC/MCParser where it belongs.Benjamin Kramer2016-01-271-5/+5
| | | | llvm-svn: 258917
* Remove autoconf supportChris Bieneman2016-01-261-15/+0
| | | | | | | | | | | | | | | | Summary: This patch is provided in preparation for removing autoconf on 1/26. The proposal to remove autoconf on 1/26 was discussed on the llvm-dev thread here: http://lists.llvm.org/pipermail/llvm-dev/2016-January/093875.html "I felt a great disturbance in the [build system], as if millions of [makefiles] suddenly cried out in terror and were suddenly silenced. I fear something [amazing] has happened." - Obi Wan Kenobi Reviewers: chandlerc, grosbach, bob.wilson, tstellarAMD, echristo, whitequark Subscribers: chfast, simoncook, emaste, jholewinski, tberghammer, jfb, danalbert, srhines, arsenm, dschuff, jyknight, dsanders, joker.eph, llvm-commits Differential Revision: http://reviews.llvm.org/D16471 llvm-svn: 258861
* fix 'the the '; NFCSanjay Patel2015-12-071-1/+1
| | | | llvm-svn: 254928
* [Hexagon] Using multiply instead of shift on signed number which can be UBColin LeMahieu2015-12-041-2/+2
| | | | llvm-svn: 254719
* Fixup for r254547: use format_hex() to simplify code.Alexey Samsonov2015-12-021-2/+1
| | | | llvm-svn: 254560
* [Hexagon] Remove std::hex in favor of format().Alexey Samsonov2015-12-021-5/+7
| | | | | | | | | std::hex is not used anywhere in LLVM code base except for this place, and it has a known undefined behavior (at least in libstdc++ 4.9.3): https://llvm.org/bugs/show_bug.cgi?id=18156, which fires in UBSan bootstrap of LLVM. llvm-svn: 254547
* Reduce the size of MCRelaxableFragment.Akira Hatanaka2015-11-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | MCRelaxableFragment previously kept a copy of MCSubtargetInfo and MCInst to enable re-encoding the MCInst later during relaxation. A copy of MCSubtargetInfo (instead of a reference or pointer) was needed because the feature bits could be modified by the parser. This commit replaces the MCSubtargetInfo copy in MCRelaxableFragment with a constant reference to MCSubtargetInfo. The copies of MCSubtargetInfo are kept in MCContext, and the target parsers are now responsible for asking MCContext to provide a copy whenever the feature bits of MCSubtargetInfo have to be toggled. With this patch, I saw a 4% reduction in peak memory usage when I compiled verify-uselistorder.lto.bc using llc. rdar://problem/21736951 Differential Revision: http://reviews.llvm.org/D14346 llvm-svn: 253127
* [MCTargetAsmParser] Move the member varialbes that referenceAkira Hatanaka2015-11-141-8/+7
| | | | | | | | | | MCSubtargetInfo in the subclasses into MCTargetAsmParser and define a member function getSTI. This is done in preparation for making changes to shrink the size of MCRelaxableFragment. (see http://reviews.llvm.org/D14346). llvm-svn: 253124
* [Hexagon] Factoring bundle creation in to a utility function.Colin LeMahieu2015-11-131-2/+1
| | | | llvm-svn: 253056
* [Hexagon] Allocate MCInst in the MCContext to avoid leaking it.Benjamin Kramer2015-11-121-1/+1
| | | | | | Found by leaksanitizer. llvm-svn: 252931
* [Hexagon] Separating statement to match what clang-format would do.Colin LeMahieu2015-11-091-2/+4
| | | | llvm-svn: 252513
* [Hexagon] Adding override to methods.Colin LeMahieu2015-11-091-4/+5
| | | | llvm-svn: 252453
* [Hexagon] Fixing warnings.Colin LeMahieu2015-11-091-4/+2
| | | | llvm-svn: 252448
* [Hexagon] Enabling ASM parsing on Hexagon backend and adding instruction ↵Colin LeMahieu2015-11-094-0/+2197
parsing tests. General updating of the code emission. llvm-svn: 252443
OpenPOWER on IntegriCloud