Krzysztof Parzyszek
6cf90d3647
[Hexagon] Change the vector scaling for vector offsets
...
Keep full offset value on MI-level instructions, but have it scaled down
in the MC-level instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@299664 91177308-0d34-0410-b5e6-96231b3b80d8
2017-04-06 17:28:21 +00:00
Krzysztof Parzyszek
e9d7ca1b92
[Hexagon] Implement @llvm.readcyclecounter()
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@295892 91177308-0d34-0410-b5e6-96231b3b80d8
2017-02-22 22:28:47 +00:00
Krzysztof Parzyszek
6eebe31eee
[Hexagon] Introduce Hexagon V62
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@294805 91177308-0d34-0410-b5e6-96231b3b80d8
2017-02-10 23:46:45 +00:00
Krzysztof Parzyszek
7f4371b614
[Hexagon] Replace instruction definitions with auto-generated ones
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@294753 91177308-0d34-0410-b5e6-96231b3b80d8
2017-02-10 15:33:13 +00:00
Krzysztof Parzyszek
06ff48c9a0
[Hexagon] Rename TypeCOMPOUND to TypeCJ
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@293894 91177308-0d34-0410-b5e6-96231b3b80d8
2017-02-02 15:03:30 +00:00
Eugene Zelenko
cce1593b22
[Hexagon] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289604 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-13 22:13:50 +00:00
Colin LeMahieu
de0c130004
[Hexagon] Changing from literal numeric value to argument since #-1 will not parse when '-' is converted to a token.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288634 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-05 04:29:00 +00:00
Peter Collingbourne
4ac35e8272
Support: Remove MemoryObject and DataStreamer interfaces.
...
These interfaces are no longer used.
Differential Revision: https://reviews.llvm.org/D26222
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@285774 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-02 00:08:37 +00:00
Krzysztof Parzyszek
92c5c9e3ab
[Hexagon] Rename operand/predicate names for unshifted integers
...
For example, rename s6Ext to s6_0Ext. The names for shifted integers
include the underscore and this will make the naming consistent. It
also exposed a few duplicates that were removed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@285728 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-01 19:02:10 +00:00
Mehdi Amini
ae5f5d3d3c
Move the global variables representing each Target behind accessor function
...
This avoids "static initialization order fiasco"
Differential Revision: https://reviews.llvm.org/D25412
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283702 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-09 23:00:34 +00:00
Colin LeMahieu
ff22dc34df
[Hexagon] NFC Removing 'V4_' prefix from duplex instruction names.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283514 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-07 00:15:07 +00:00
Colin LeMahieu
27ab1b8a7a
[Hexagon] NFC. Canonicalizing absolute address instruction names.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@283507 91177308-0d34-0410-b5e6-96231b3b80d8
2016-10-06 23:02:11 +00:00
Krzysztof Parzyszek
60719d620c
[Hexagon] Fix disassembler crash after r279255
...
When p0 was added as an explicit operand to the duplex subinstructions,
the disassembler was not updated to reflect this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@281104 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-09 21:45:00 +00:00
Mehdi Amini
f6071e14c5
[NFC] Header cleanup
...
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>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@266595 91177308-0d34-0410-b5e6-96231b3b80d8
2016-04-18 09:17:29 +00:00
Colin LeMahieu
f0ac61f720
[Hexagon] Adding missing break in switch statement. Extra operands would have been appended to the end.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@263657 91177308-0d34-0410-b5e6-96231b3b80d8
2016-03-16 20:00:38 +00:00
Colin LeMahieu
71381aee13
[NFC] Convert tabs to spaces.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@262411 91177308-0d34-0410-b5e6-96231b3b80d8
2016-03-01 22:05:03 +00:00
Colin LeMahieu
83948c56bd
[NFC] Referencing manual for reason why subregbit is checked
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@259380 91177308-0d34-0410-b5e6-96231b3b80d8
2016-02-01 18:15:39 +00:00
Chris Bieneman
caeade4234
Remove autoconf support
...
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
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@258861 91177308-0d34-0410-b5e6-96231b3b80d8
2016-01-26 21:29:08 +00:00
Benjamin Kramer
b6242a88c2
Reflect the MC/MCDisassembler split on the include/ level.
...
No functional change, just moving code around.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@258818 91177308-0d34-0410-b5e6-96231b3b80d8
2016-01-26 16:44:37 +00:00
Craig Topper
79402ee6f9
Replace uint16_t with the MCPhysReg typedef in many places. A lot of physical register arrays already use this typedef.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254843 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-05 07:13:35 +00:00
Craig Topper
97beeddf5b
[Hexagon] Use array_lengthof and const correct and type correct the array and array size. NFC
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254384 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-01 06:13:08 +00:00
Craig Topper
cac7246b4c
Use array_lengthof instead of manually calculating it. NFC
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254383 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-01 06:13:06 +00:00
Craig Topper
5861170521
[Hexagon] Use ArrayRef to avoid needing to calculate an array size. Interestingly the original code may have had a bug because it was passing the byte size of a uint16_t array instead of the number of entries.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254382 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-01 06:13:04 +00:00
Colin LeMahieu
6de64e032f
[Hexagon] Factoring bundle creation in to a utility function.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@253056 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-13 17:42:46 +00:00
Colin LeMahieu
c0aef701cc
[Hexagon] Enabling ASM parsing on Hexagon backend and adding instruction parsing tests. General updating of the code emission.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252443 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-09 04:07:48 +00:00
Colin LeMahieu
b939021544
[Hexagon] Fixing mistaken case fallthrough.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@251867 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-03 00:21:19 +00:00
Colin LeMahieu
b4b2bb0a0f
[Hexagon] Adding skeleton of HVX extension instructions.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@250600 91177308-0d34-0410-b5e6-96231b3b80d8
2015-10-17 01:33:04 +00:00
Cameron Esfahani
7ec94a3dea
Explicitly clear the MI operand list when getInstruction() is called. Call MI.clear() within MCD::OPC_Decode case and inside of translateInstruction() for the X86 target. Remove now unnecessary MI.clear() from ARMDisassembler.
...
Summary: Explicitly clear the MI operand list when getInstruction() is called.
Reviewers: hfinkel, t.p.northover, hvarga, kparzysz, jyknight, qcolombet, uweigand
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D11665
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@244557 91177308-0d34-0410-b5e6-96231b3b80d8
2015-08-11 01:15:07 +00:00
Alexander Kornienko
cd52a7a381
Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC)
...
Apparently, the style needs to be agreed upon first.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240390 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-23 09:49:53 +00:00
Alexander Kornienko
cf0db29df2
Fixed/added namespace ending comments using clang-tidy. NFC
...
The patch is generated using this command:
tools/clang/tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \
-checks=-*,llvm-namespace-comment -header-filter='llvm/.*|clang/.*' \
llvm/lib/
Thanks to Eugene Kosov for the original patch!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240137 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-19 15:57:42 +00:00
Colin LeMahieu
c196bfecd6
[Hexagon] Adding decoders for signed operands and ensuring all signed operand types disassemble correctly.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239477 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-10 16:52:32 +00:00
Colin LeMahieu
750b351b76
[Hexagon] Reapply r239097 with tests corrected for shuffling and duplexing.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239161 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-05 16:00:11 +00:00
Colin LeMahieu
4e8f68f245
Revert r239095 incorrect test tree.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239102 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-04 21:32:42 +00:00
Colin LeMahieu
60b4c7fc30
[Hexagon] Adding functionality for duplexing. Duplexing is a way to compress commonly used pairs of instructions in order to reduce code size. The test case duplex.ll normally would be 8 bytes, assign register to 0 and jump to link register. After duplexing this is only 4 bytes. This also tests the HexagonMCShuffler code path which is used to make sure duplexed instructions still follow slot requirements.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239095 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-04 21:16:16 +00:00
Colin LeMahieu
0ace3c01f7
[Hexagon] Disassembling, printing, and emitting instructions a whole-bundle at a time which is the semantic unit for Hexagon. Fixing tests to use the new format. Disabling tests in the direct object emission path for a followup patch.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238556 91177308-0d34-0410-b5e6-96231b3b80d8
2015-05-29 14:44:13 +00:00
NAKAMURA Takumi
f61fb0c9a7
Prune CRLFs.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238125 91177308-0d34-0410-b5e6-96231b3b80d8
2015-05-25 01:43:23 +00:00
Jim Grosbach
db703aaedd
MC: Modernize MCOperand API naming. NFC.
...
MCOperand::Create*() methods renamed to MCOperand::create*().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@237275 91177308-0d34-0410-b5e6-96231b3b80d8
2015-05-13 18:37:00 +00:00
Colin LeMahieu
55d7decf27
[Hexagon] Moving remaining methods off of HexagonMCInst in to HexagonMCInstrInfo and eliminating HexagonMCInst class.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229914 91177308-0d34-0410-b5e6-96231b3b80d8
2015-02-19 21:10:50 +00:00
Colin LeMahieu
11179629b5
[Hexagon] Adding vector load with post-increment instructions. Adding decoder function for 64bit control register class.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@228708 91177308-0d34-0410-b5e6-96231b3b80d8
2015-02-10 16:59:36 +00:00
Chandler Carruth
1b279144ec
[cleanup] Re-sort all the #include lines in LLVM using
...
utils/sort_includes.py.
I clearly haven't done this in a while, so more changed than usual. This
even uncovered a missing include from the InstrProf library that I've
added. No functionality changed here, just mechanical cleanup of the
include order.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225974 91177308-0d34-0410-b5e6-96231b3b80d8
2015-01-14 11:23:27 +00:00
Colin LeMahieu
6ff5e4862d
[Hexagon] Adding deallocframe and circular addressing loads.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@224869 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-26 20:30:58 +00:00
Colin LeMahieu
e403ffc801
[Hexagon] Adding transfers to and from control registers.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@224599 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-19 19:06:32 +00:00
Colin LeMahieu
78ec9010c5
[Hexagon] Adding DoubleRegs decoder. Moving C2_mux and A2_nop. Adding combine imm-imm form.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223494 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-05 18:24:06 +00:00
Colin LeMahieu
152ac18e80
[Hexagon] Marking some instructions as CodeGenOnly=0 and adding disassembly tests.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223334 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-04 03:41:21 +00:00
Colin LeMahieu
b7927f100d
[Hexagon] Converting from ADD_rr to A2_add which has encoding bits.
...
Adding test to show correct instruction selection and encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@222249 91177308-0d34-0410-b5e6-96231b3b80d8
2014-11-18 20:28:11 +00:00
Rafael Espindola
6a222ec893
Pass an ArrayRef to MCDisassembler::getInstruction.
...
With this patch MCDisassembler::getInstruction takes an ArrayRef<uint8_t>
instead of a MemoryObject.
Even on X86 there is a maximum size an instruction can have. Given
that, it seems way simpler and more efficient to just pass an ArrayRef
to the disassembler instead of a MemoryObject and have it do a virtual
call every time it wants some extra bytes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221751 91177308-0d34-0410-b5e6-96231b3b80d8
2014-11-12 02:04:27 +00:00
Rafael Espindola
d342c4c748
Misc style fixes. NFC.
...
This fixes a few cases of:
* Wrong variable name style.
* Lines longer than 80 columns.
* Repeated names in comments.
* clang-format of the above.
This make the next patch a lot easier to read.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221615 91177308-0d34-0410-b5e6-96231b3b80d8
2014-11-10 18:11:10 +00:00
Colin LeMahieu
38d3e4d5d8
[Hexagon] Reverting 220584 to address ASAN errors.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221210 91177308-0d34-0410-b5e6-96231b3b80d8
2014-11-04 00:14:36 +00:00
NAKAMURA Takumi
af628cc0b8
Prune CRLF.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220678 91177308-0d34-0410-b5e6-96231b3b80d8
2014-10-27 12:37:26 +00:00
Colin LeMahieu
8699f5390b
[Hexagon] Resubmission of 220427
...
Modified library structure to deal with circular dependency between HexagonInstPrinter and HexagonMCInst.
Adding encoding bits for add opcode.
Adding llvm-mc tests.
Removing unit tests.
http://reviews.llvm.org/D5624
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220584 91177308-0d34-0410-b5e6-96231b3b80d8
2014-10-24 19:00:32 +00:00