Vasileios Kalintiris
974d409259
[mips] Added support for the ERETNC instruction.
...
Summary: This required adding the instruction predicate HasMips32r5.
Patch by Scott Egerton.
Reviewers: dsanders, vkalintiris
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D11136
llvm-svn: 242666
2015-07-20 12:28:56 +00:00
Zoran Jovanovic
2a47d08afd
[mips][microMIPS] Implement SLL and NOP instructions
...
http://reviews.llvm.org/D10474
llvm-svn: 241150
2015-07-01 09:54:51 +00:00
Daniel Sanders
b2fa8add82
[mips] Fold duplicate big-endian disassembler tests together.
...
llvm-svn: 240887
2015-06-27 17:56:44 +00:00
Daniel Sanders
abe7d840b9
[mips] Sort big-endian disassembler tests by opcode.
...
llvm-svn: 240885
2015-06-27 16:13:59 +00:00
Daniel Sanders
de692cae9d
[mips] Make little-endian disassembler test filenames consistent.
...
Most are named *-el.txt. Renamed the three that were *-le.txt
llvm-svn: 240884
2015-06-27 15:42:25 +00:00
Daniel Sanders
a3134fae17
[mips] Add COP0 register class and use it in M[FT]C0/DM[FT]C0.
...
Summary:
Previously it (incorrectly) used GPR's.
Patch by Simon Dardis. A couple small corrections by myself.
Reviewers: dsanders
Reviewed By: dsanders
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10567
llvm-svn: 240883
2015-06-27 15:39:19 +00:00
Zoran Jovanovic
67e04be640
[mips][microMIPS] Implement BREAK, EHB and EI instructions
...
http://reviews.llvm.org/D10090
llvm-svn: 240531
2015-06-24 10:32:16 +00:00
Zoran Jovanovic
cdfcbe41f2
[mips][microMIPS] Implement ERET and ERETNC instructions
...
http://reviews.llvm.org/D10091
llvm-svn: 239522
2015-06-11 10:22:46 +00:00
Zoran Jovanovic
fcecf26092
[mips][microMIPSr6] Change disassembler tests to one line format
...
llvm-svn: 239519
2015-06-11 09:42:10 +00:00
Zoran Jovanovic
85a53a1ed5
[mips][microMIPSr6] Implement SEB and SEH instructions
...
Differential Revision: http://reviews.llvm.org/D9739
llvm-svn: 238333
2015-05-27 15:39:47 +00:00
Jozef Kolek
888830adfe
[mips][microMIPSr6] Implement BEQZALC, BGEZALC, BGTZALC, BLEZALC, BLTZALC and BNEZALC instructions
...
This patch implements microMIPS32r6 BEQZALC, BGEZALC, BGTZALC, BLEZALC, BLTZALC
and BNEZALC instructions using mapping.
Differential Revision: http://reviews.llvm.org/D10031
llvm-svn: 238325
2015-05-27 14:19:22 +00:00
Zoran Jovanovic
dde61c00c3
[mips][microMIPSr6] Implement NOR, OR, ORI, XOR and XORI instructions
...
Differential Revision: http://reviews.llvm.org/D8800
llvm-svn: 237697
2015-05-19 14:12:55 +00:00
Zoran Jovanovic
299fed6b7d
[mips][microMIPSr6] Implement AND and ANDI instructions
...
Differential Revision: http://reviews.llvm.org/D8772
llvm-svn: 237696
2015-05-19 13:32:31 +00:00
Zoran Jovanovic
3825261572
[mips][microMIPSr6] Implement DIV, DIVU, MOD and MODU instructions
...
Differential Revision: http://reviews.llvm.org/D8769
llvm-svn: 237685
2015-05-19 11:21:37 +00:00
Jozef Kolek
cc0c0fc926
[mips][microMIPSr6] Implement LSA instruction
...
This patch implements LSA instruction using mapping.
Differential Revision: http://reviews.llvm.org/D8919
llvm-svn: 237634
2015-05-18 23:12:10 +00:00
Jozef Kolek
cbb227b48d
[mips][microMIPSr6] Implement ALIGN and AUI instructions
...
This patch implements ALIGN and AUI instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8782
llvm-svn: 237563
2015-05-18 11:44:30 +00:00
Jozef Kolek
6fec325d10
[mips][microMIPSr6] Implement CLO and CLZ instructions
...
This patch implements CLO and CLZ instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8553
llvm-svn: 237257
2015-05-13 14:18:11 +00:00
Jozef Kolek
38bb81db85
[mips][microMIPSr6] Implement SELEQZ and SELNEZ instructions
...
This patch implements SELEQZ and SELNEZ instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8497
llvm-svn: 237158
2015-05-12 17:39:32 +00:00
Jozef Kolek
8abad7bacc
[mips][microMIPSr6] Implement ALUIPC and AUIPC instructions
...
This patch implements ALUIPC and AUIPC instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8441
llvm-svn: 236858
2015-05-08 14:25:11 +00:00
Jozef Kolek
9ce6e0a926
[mips][microMIPSr6] Implement ADDIUPC and LWPC instructions
...
This patch implements ADDIUPC and LWPC instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8415
llvm-svn: 236852
2015-05-08 13:52:04 +00:00
Jozef Kolek
cf98462818
[mips][microMIPSr6] Implement JIALC and JIC instructions
...
This patch implements JIALC and JIC instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8389
llvm-svn: 236748
2015-05-07 17:12:23 +00:00
Daniel Sanders
4160c802d9
[mips][msa] Test basic operations for the N32 ABI too.
...
Summary:
This required adding instruction aliases for dneg.
N64 will be enabled shortly but requires additional bugfixes.
Reviewers: vkalintiris
Reviewed By: vkalintiris
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D9341
llvm-svn: 236489
2015-05-05 08:48:35 +00:00
Daniel Sanders
4d532b5617
[mips] Sorted instructions in mips64r6 disassembly tests. NFC.
...
llvm-svn: 236223
2015-04-30 10:52:42 +00:00
Zoran Jovanovic
387ce30685
[mips][microMIPSr6] Implement MUL, MUH, MULU and MUHU instructions
...
Differential Revision: http://reviews.llvm.org/D8894
llvm-svn: 236131
2015-04-29 17:23:22 +00:00
Zoran Jovanovic
cca29e8f6e
[mips][microMIPSr6] Implement SUB and SUBU instructions
...
Differential Revision: http://reviews.llvm.org/D8764
llvm-svn: 236118
2015-04-29 16:22:46 +00:00
Zoran Jovanovic
5f34d44354
[mips][microMIPSr6] Implement ADD, ADDU and ADDIU instructions
...
Differential Revision: http://reviews.llvm.org/D8704
llvm-svn: 236111
2015-04-29 15:11:07 +00:00
Jozef Kolek
8e086cedfa
[mips][microMIPSr6] Implement CACHE and PREF instructions
...
Implement CACHE and PREF instructions using mapping.
Differential Revision: http://reviews.llvm.org/D8893
llvm-svn: 235379
2015-04-21 11:17:25 +00:00
Jozef Kolek
207d248eba
[mips][microMIPSr6] Implement BITSWAP instruction
...
Implement BITSWAP instruction using mapping.
Differential Revision: http://reviews.llvm.org/D8857
llvm-svn: 235321
2015-04-20 18:14:59 +00:00
Jozef Kolek
676d60125c
[mips][microMIPSr6] Implement disassembler support
...
Implement disassembler support for microMIPS32r6.
Differential Revision: http://reviews.llvm.org/D8490
llvm-svn: 235307
2015-04-20 14:40:38 +00:00
Daniel Sanders
1779314e3c
[mips] Add backend support for Mips32r[35] and Mips64r[35].
...
Summary:
These ISA's didn't add any instructions so they are almost identical to
Mips32r2 and Mips64r2. Even the ELF e_flags are the same, However the ISA
revision in .MIPS.abiflags is 3 or 5 respectively instead of 2.
Reviewers: vmedic
Reviewed By: vmedic
Subscribers: tomatabacu, llvm-commits, atanasyan
Differential Revision: http://reviews.llvm.org/D7381
llvm-svn: 229695
2015-02-18 16:24:50 +00:00
Daniel Sanders
a19216c8f4
[mips] Merge disassemblers into a single implementation.
...
Summary:
Currently we have Mips32 and Mips64 disassemblers and this causes the target
triple to affect the disassembly despite all the relevant information being in
the ELF header. These implementations do not need to be separate.
This patch merges them together such that the appropriate tables are checked
for the subtarget (e.g. Mips64 is checked when GP64 is enabled).
Reviewers: vmedic
Reviewed By: vmedic
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D7498
llvm-svn: 228825
2015-02-11 11:28:56 +00:00
Zoran Jovanovic
416886793f
[mips][microMIPS] Implement movep instruction
...
Differential Revision: http://reviews.llvm.org/D7465
llvm-svn: 228703
2015-02-10 16:36:20 +00:00
Jozef Kolek
e76eb41c21
[mips][microMIPS] Add disassembler tests for 16-bit instructions BREAK16 and SDBBP16
...
Differential Revision: http://reviews.llvm.org/D7443
llvm-svn: 228687
2015-02-10 13:20:51 +00:00
Jozef Kolek
d68d424abf
[mips][microMIPS] Fix disassembling of 16-bit microMIPS instructions LWM16 and SWM16
...
Differential Revision: http://reviews.llvm.org/D7436
llvm-svn: 228683
2015-02-10 12:41:13 +00:00
Vladimir Medic
df464ae224
[Mips][Disassembler] When disassembler meets cache/pref instructions for r6 it crashes as the access to operands array is out of range. This patch adds dedicated decoder method for R6 CACHE_HINT_DESC class that properly handles decoding of these instructions.
...
llvm-svn: 227430
2015-01-29 11:33:41 +00:00
Jozef Kolek
e10a02ecf0
[mips][microMIPS] Implement LWGP instruction
...
Differential Revision: http://reviews.llvm.org/D6650
llvm-svn: 227325
2015-01-28 17:27:26 +00:00
Vladimir Medic
0516a5b686
When disassembler meets compact jump instructions for r6 it crashes as the access to operands array is out of range. This patch removes dedicated decoder method that wrongly handles decoding of these instructions.
...
llvm-svn: 227084
2015-01-26 10:33:43 +00:00
Reid Kleckner
f4ebbc6825
mips: Fix "XPASS" test results by removing 'not' commands
...
These tests are asserting and crashing for me, and 'not' sees that as a
non-zero exit code instead of a signal code for obscure Windows reasons.
This causes the test to pass, giving me an unclean 'ninja check'.
The test is already XFAILd, so just run the test without 'not' and let
lit handle the failure.
llvm-svn: 226958
2015-01-23 22:55:31 +00:00
Jozef Kolek
5cfebdde2b
[mips][microMIPS] MicroMIPS 16-bit unconditional branch instruction B
...
Implement microMIPS 16-bit unconditional branch instruction B.
Implemented 16-bit microMIPS unconditional instruction has real name B16, and
B is an alias which expands to either B16 or BEQ according to the rules:
b 256 --> b16 256 # R_MICROMIPS_PC10_S1
b 12256 --> beq $zero, $zero, 12256 # R_MICROMIPS_PC16_S1
b label --> beq $zero, $zero, label # R_MICROMIPS_PC16_S1
Differential Revision: http://reviews.llvm.org/D3514
llvm-svn: 226657
2015-01-21 12:39:30 +00:00
Jozef Kolek
2c6d73207e
[mips][microMIPS] Implement ADDIUPC instruction
...
Differential Revision: http://reviews.llvm.org/D6582
llvm-svn: 226656
2015-01-21 12:10:11 +00:00
Vladimir Medic
435cf8a415
[Mips][Disassembler]When disassembler meets load/store from coprocessor 2 instructions for mips r6 it crashes as the access to operands array is out of range. This patch adds dedicated decoder method that properly handles decoding of these instructions.
...
llvm-svn: 226652
2015-01-21 10:47:36 +00:00
Jozef Kolek
0d49117769
Reverted revision 226577.
...
llvm-svn: 226595
2015-01-20 19:29:28 +00:00
Jozef Kolek
45f7f9c1ab
[mips][microMIPS] MicroMIPS 16-bit unconditional branch instruction B
...
Implement microMIPS 16-bit unconditional branch instruction B.
Implemented 16-bit microMIPS unconditional instruction has real name B16, and
B is an alias which expands to either B16 or BEQ according to the rules:
b 256 --> b16 256 # R_MICROMIPS_PC10_S1
b 12256 --> beq $zero, $zero, 12256 # R_MICROMIPS_PC16_S1
b label --> beq $zero, $zero, label # R_MICROMIPS_PC16_S1
Differential Revision: http://reviews.llvm.org/D3514
llvm-svn: 226577
2015-01-20 16:45:27 +00:00
Daniel Sanders
01dce6c931
[mips] 'CHECK :' is not a valid check directive. Fixed.
...
llvm-svn: 226409
2015-01-18 18:43:10 +00:00
Daniel Sanders
0cb9dc6e68
[mips] Make whitespace in disassembler tests more consistent. NFC.
...
The tests for the ISA's should now be approximately diffable. That is, the
output of 'diff valid-mips1.txt valid-mips2.txt' should be emit the lines
for instructions that were added/removed to/from MIPS-I by MIPS-II. This
doesn't work perfectly at the moment due to ordering differences but it
should be close.
llvm-svn: 226408
2015-01-18 18:38:36 +00:00
Daniel Sanders
46ad7cbfce
[mips] Make whitespace of disassembler tests more consistent by removing blank lines. NFC.
...
llvm-svn: 226407
2015-01-18 18:21:19 +00:00
Vladimir Medic
df3ed1c9d6
Add disassembler tests for mips64r6 platform. There are no functional changes.
...
llvm-svn: 226166
2015-01-15 14:18:12 +00:00
Vladimir Medic
d6d486ddcc
Add disassembler tests for mips32r6 platform. There are no functional changes.
...
llvm-svn: 226165
2015-01-15 14:11:38 +00:00
Vladimir Medic
5dcf17b881
Add disassembler tests for mips64r2 platform. There are no functional changes.
...
llvm-svn: 226164
2015-01-15 14:06:34 +00:00
Vladimir Medic
e993dac523
Add disassembler tests for mips64 platform. There are no functional changes.
...
llvm-svn: 226151
2015-01-15 08:50:20 +00:00