1 1.1 christos /* Table of opcodes for the sparc. 2 1.11 christos Copyright (C) 1989-2024 Free Software Foundation, Inc. 3 1.1 christos 4 1.1 christos This file is part of the GNU opcodes library. 5 1.1 christos 6 1.1 christos This library is free software; you can redistribute it and/or modify 7 1.1 christos it under the terms of the GNU General Public License as published by 8 1.1 christos the Free Software Foundation; either version 3, or (at your option) 9 1.1 christos any later version. 10 1.1 christos 11 1.1 christos It is distributed in the hope that it will be useful, but WITHOUT 12 1.1 christos ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 13 1.1 christos or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 14 1.1 christos License for more details. 15 1.1 christos 16 1.1 christos You should have received a copy of the GNU General Public License 17 1.1 christos along with this file; see the file COPYING. If not, write to the 18 1.1 christos Free Software Foundation, 51 Franklin Street - Fifth Floor, Boston, 19 1.1 christos MA 02110-1301, USA. */ 20 1.1 christos 21 1.1 christos 22 1.1 christos /* FIXME-someday: perhaps the ,a's and such should be embedded in the 23 1.1 christos instruction's name rather than the args. This would make gas faster, pinsn 24 1.1 christos slower, but would mess up some macros a bit. xoxorich. */ 25 1.1 christos 26 1.1 christos #include "sysdep.h" 27 1.1 christos #include <stdio.h> 28 1.1 christos #include "opcode/sparc.h" 29 1.1 christos 30 1.1 christos /* Some defines to make life easy. */ 31 1.1 christos #define MASK_V6 SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V6) 32 1.1 christos #define MASK_V7 SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V7) 33 1.1 christos #define MASK_V8 SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V8) 34 1.1 christos #define MASK_LEON SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_LEON) 35 1.1 christos #define MASK_SPARCLET SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_SPARCLET) 36 1.1 christos #define MASK_SPARCLITE SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_SPARCLITE) 37 1.1 christos #define MASK_V9 SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9) 38 1.1 christos #define MASK_V9A SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9A) 39 1.1 christos #define MASK_V9B SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9B) 40 1.6 christos #define MASK_V9C SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9C) 41 1.6 christos #define MASK_V9D SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9D) 42 1.6 christos #define MASK_V9E SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9E) 43 1.6 christos #define MASK_V9V SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9V) 44 1.6 christos #define MASK_V9M SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_V9M) 45 1.8 christos #define MASK_M8 SPARC_OPCODE_ARCH_MASK (SPARC_OPCODE_ARCH_M8) 46 1.1 christos 47 1.1 christos /* Bit masks of architectures supporting the insn. */ 48 1.1 christos 49 1.1 christos #define v6 (MASK_V6 | MASK_V7 | MASK_V8 | MASK_LEON \ 50 1.1 christos | MASK_SPARCLET | MASK_SPARCLITE \ 51 1.6 christos | MASK_V9 | MASK_V9A | MASK_V9B \ 52 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 53 1.8 christos | MASK_M8) 54 1.1 christos /* v6 insns not supported on the sparclet. */ 55 1.1 christos #define v6notlet (MASK_V6 | MASK_V7 | MASK_V8 | MASK_LEON \ 56 1.6 christos | MASK_SPARCLITE | MASK_V9 | MASK_V9A | MASK_V9B \ 57 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 58 1.8 christos | MASK_M8) 59 1.1 christos #define v7 (MASK_V7 | MASK_V8 | MASK_LEON | MASK_SPARCLET \ 60 1.6 christos | MASK_SPARCLITE | MASK_V9 | MASK_V9A | MASK_V9B \ 61 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 62 1.8 christos | MASK_M8) 63 1.1 christos /* Although not all insns are implemented in hardware, sparclite is defined 64 1.1 christos to be a superset of v8. Unimplemented insns trap and are then theoretically 65 1.1 christos implemented in software. 66 1.1 christos It's not clear that the same is true for sparclet, although the docs 67 1.1 christos suggest it is. Rather than complicating things, the sparclet assembler 68 1.1 christos recognizes all v8 insns. */ 69 1.1 christos #define v8 (MASK_V8 | MASK_LEON | MASK_SPARCLET | MASK_SPARCLITE \ 70 1.6 christos | MASK_V9 | MASK_V9A | MASK_V9B \ 71 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 72 1.8 christos | MASK_M8) 73 1.1 christos #define sparclet (MASK_SPARCLET) 74 1.8 christos #define leon (MASK_LEON) 75 1.1 christos /* sparclet insns supported by leon. */ 76 1.1 christos #define letandleon (MASK_SPARCLET | MASK_LEON) 77 1.1 christos #define sparclite (MASK_SPARCLITE) 78 1.6 christos #define v9 (MASK_V9 | MASK_V9A | MASK_V9B \ 79 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 80 1.8 christos | MASK_M8) 81 1.1 christos /* v9 insns supported by leon. */ 82 1.6 christos #define v9andleon (MASK_V9 | MASK_V9A | MASK_V9B \ 83 1.6 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 84 1.8 christos | MASK_M8 | MASK_LEON) 85 1.6 christos #define v9a (MASK_V9A | MASK_V9B \ 86 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 87 1.8 christos | MASK_M8) 88 1.6 christos #define v9b (MASK_V9B \ 89 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 90 1.8 christos | MASK_M8) 91 1.8 christos #define v9c (MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M \ 92 1.8 christos | MASK_M8) 93 1.8 christos #define v9d (MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M | MASK_M8) 94 1.8 christos #define v9e (MASK_V9E | MASK_V9V | MASK_V9M | MASK_M8) 95 1.8 christos #define v9v (MASK_V9V | MASK_V9M | MASK_M8) 96 1.8 christos #define v9m (MASK_V9M | MASK_M8) 97 1.8 christos #define m8 (MASK_M8) 98 1.6 christos 99 1.1 christos /* v6 insns not supported by v9. */ 100 1.1 christos #define v6notv9 (MASK_V6 | MASK_V7 | MASK_V8 | MASK_LEON \ 101 1.1 christos | MASK_SPARCLET | MASK_SPARCLITE) 102 1.1 christos /* v9a instructions which would appear to be aliases to v9's impdep's 103 1.1 christos otherwise. */ 104 1.1 christos #define v9notv9a (MASK_V9) 105 1.1 christos 106 1.7 christos /* Hardware capability sets, used to keep sparc_opcode_archs easy to 107 1.7 christos read. */ 108 1.7 christos #define HWS_V8 HWCAP_MUL32 | HWCAP_DIV32 | HWCAP_FSMULD 109 1.7 christos #define HWS_V9 HWS_V8 | HWCAP_POPC 110 1.7 christos #define HWS_VA HWS_V9 | HWCAP_VIS 111 1.7 christos #define HWS_VB HWS_VA | HWCAP_VIS2 112 1.7 christos #define HWS_VC HWS_VB | HWCAP_ASI_BLK_INIT 113 1.7 christos #define HWS_VD HWS_VC | HWCAP_FMAF | HWCAP_VIS3 | HWCAP_HPC 114 1.7 christos #define HWS_VE HWS_VD \ 115 1.7 christos | HWCAP_AES | HWCAP_DES | HWCAP_KASUMI | HWCAP_CAMELLIA \ 116 1.7 christos | HWCAP_MD5 | HWCAP_SHA1 | HWCAP_SHA256 |HWCAP_SHA512 | HWCAP_MPMUL \ 117 1.7 christos | HWCAP_MONT | HWCAP_CRC32C | HWCAP_CBCOND | HWCAP_PAUSE 118 1.7 christos #define HWS_VV HWS_VE | HWCAP_FJFMAU | HWCAP_IMA 119 1.7 christos #define HWS_VM HWS_VV 120 1.8 christos #define HWS_VM8 HWS_VM 121 1.7 christos 122 1.7 christos #define HWS2_VM \ 123 1.7 christos HWCAP2_VIS3B | HWCAP2_ADP | HWCAP2_SPARC5 | HWCAP2_MWAIT \ 124 1.7 christos | HWCAP2_XMPMUL | HWCAP2_XMONT 125 1.8 christos #define HWS2_VM8 HWS2_VM \ 126 1.8 christos | HWCAP2_SPARC6 | HWCAP2_ONADDSUB | HWCAP2_ONMUL | HWCAP2_ONDIV \ 127 1.8 christos | HWCAP2_DICTUNP | HWCAP2_FPCMPSHL | HWCAP2_RLE | HWCAP2_SHA3 128 1.8 christos 129 1.7 christos 130 1.1 christos /* Table of opcode architectures. 131 1.1 christos The order is defined in opcode/sparc.h. */ 132 1.1 christos 133 1.1 christos const struct sparc_opcode_arch sparc_opcode_archs[] = 134 1.1 christos { 135 1.7 christos { "v6", MASK_V6, 0, 0 }, 136 1.7 christos { "v7", MASK_V6 | MASK_V7, 0, 0 }, 137 1.7 christos { "v8", MASK_V6 | MASK_V7 | MASK_V8, HWS_V8, 0 }, 138 1.7 christos { "leon", MASK_V6 | MASK_V7 | MASK_V8 | MASK_LEON, HWS_V8, 0 }, 139 1.7 christos { "sparclet", MASK_V6 | MASK_V7 | MASK_V8 | MASK_SPARCLET, HWS_V8, 0 }, 140 1.7 christos { "sparclite", MASK_V6 | MASK_V7 | MASK_V8 | MASK_SPARCLITE, HWS_V8, 0 }, 141 1.1 christos /* ??? Don't some v8 priviledged insns conflict with v9? */ 142 1.7 christos { "v9", MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9, HWS_V9, 0 }, 143 1.1 christos /* v9 with ultrasparc additions */ 144 1.7 christos { "v9a", MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A, HWS_VA, 0 }, 145 1.1 christos /* v9 with cheetah additions */ 146 1.7 christos { "v9b", MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B, HWS_VB, 0 }, 147 1.6 christos /* v9 with UA2005 and T1 additions. */ 148 1.6 christos { "v9c", (MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B 149 1.7 christos | MASK_V9C), HWS_VC, 0 }, 150 1.6 christos /* v9 with UA2007 and T3 additions. */ 151 1.6 christos { "v9d", (MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B 152 1.7 christos | MASK_V9C | MASK_V9D), HWS_VD, 0 }, 153 1.6 christos /* v9 with OSA2011 and T4 additions modulus integer multiply-add. */ 154 1.6 christos { "v9e", (MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B 155 1.7 christos | MASK_V9C | MASK_V9D | MASK_V9E), HWS_VE, 0 }, 156 1.6 christos /* V9 with OSA2011 and T4 additions, integer multiply and Fujitsu fp 157 1.6 christos multiply-add. */ 158 1.6 christos { "v9v", (MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B 159 1.7 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V), HWS_VV, 0 }, 160 1.6 christos /* v9 with OSA2015 and M7 additions. */ 161 1.6 christos { "v9m", (MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B 162 1.7 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M), HWS_VM, HWS2_VM }, 163 1.8 christos /* v9 with OSA2017 and M8 additions. */ 164 1.8 christos { "m8", (MASK_V6 | MASK_V7 | MASK_V8 | MASK_V9 | MASK_V9A | MASK_V9B 165 1.8 christos | MASK_V9C | MASK_V9D | MASK_V9E | MASK_V9V | MASK_V9M | MASK_M8), 166 1.8 christos HWS_VM8, HWS2_VM8 }, 167 1.7 christos { NULL, 0, 0, 0 } 168 1.1 christos }; 169 1.1 christos 170 1.1 christos /* Given NAME, return it's architecture entry. */ 171 1.1 christos 172 1.1 christos enum sparc_opcode_arch_val 173 1.1 christos sparc_opcode_lookup_arch (const char *name) 174 1.1 christos { 175 1.1 christos const struct sparc_opcode_arch *p; 176 1.1 christos 177 1.1 christos for (p = &sparc_opcode_archs[0]; p->name; ++p) 178 1.1 christos if (strcmp (name, p->name) == 0) 179 1.1 christos return (enum sparc_opcode_arch_val) (p - &sparc_opcode_archs[0]); 180 1.1 christos 181 1.1 christos return SPARC_OPCODE_ARCH_BAD; 182 1.1 christos } 183 1.1 christos 184 1.1 christos /* Branch condition field. */ 186 1.1 christos #define COND(x) (((x) & 0xf) << 25) 187 1.1 christos 188 1.1 christos /* Compare And Branch condition field. */ 189 1.1 christos #define CBCOND(x) (((x) & 0x1f) << 25) 190 1.1 christos 191 1.1 christos /* v9: Move (MOVcc and FMOVcc) condition field. */ 192 1.1 christos #define MCOND(x,i_or_f) ((((i_or_f) & 1) << 18) | (((x) >> 11) & (0xf << 14))) /* v9 */ 193 1.1 christos 194 1.1 christos /* v9: Move register (MOVRcc and FMOVRcc) condition field. */ 195 1.1 christos #define RCOND(x) (((x) & 0x7) << 10) /* v9 */ 196 1.1 christos 197 1.1 christos #define CONDA (COND (0x8)) 198 1.1 christos #define CONDCC (COND (0xd)) 199 1.1 christos #define CONDCS (COND (0x5)) 200 1.1 christos #define CONDE (COND (0x1)) 201 1.1 christos #define CONDG (COND (0xa)) 202 1.1 christos #define CONDGE (COND (0xb)) 203 1.1 christos #define CONDGU (COND (0xc)) 204 1.1 christos #define CONDL (COND (0x3)) 205 1.1 christos #define CONDLE (COND (0x2)) 206 1.1 christos #define CONDLEU (COND (0x4)) 207 1.1 christos #define CONDN (COND (0x0)) 208 1.1 christos #define CONDNE (COND (0x9)) 209 1.1 christos #define CONDNEG (COND (0x6)) 210 1.1 christos #define CONDPOS (COND (0xe)) 211 1.1 christos #define CONDVC (COND (0xf)) 212 1.1 christos #define CONDVS (COND (0x7)) 213 1.1 christos 214 1.1 christos #define CONDNZ CONDNE 215 1.1 christos #define CONDZ CONDE 216 1.1 christos #define CONDGEU CONDCC 217 1.1 christos #define CONDLU CONDCS 218 1.1 christos 219 1.1 christos #define FCONDA (COND (0x8)) 220 1.1 christos #define FCONDE (COND (0x9)) 221 1.1 christos #define FCONDG (COND (0x6)) 222 1.1 christos #define FCONDGE (COND (0xb)) 223 1.1 christos #define FCONDL (COND (0x4)) 224 1.1 christos #define FCONDLE (COND (0xd)) 225 1.1 christos #define FCONDLG (COND (0x2)) 226 1.1 christos #define FCONDN (COND (0x0)) 227 1.1 christos #define FCONDNE (COND (0x1)) 228 1.1 christos #define FCONDO (COND (0xf)) 229 1.1 christos #define FCONDU (COND (0x7)) 230 1.1 christos #define FCONDUE (COND (0xa)) 231 1.1 christos #define FCONDUG (COND (0x5)) 232 1.1 christos #define FCONDUGE (COND (0xc)) 233 1.1 christos #define FCONDUL (COND (0x3)) 234 1.1 christos #define FCONDULE (COND (0xe)) 235 1.1 christos 236 1.1 christos #define FCONDNZ FCONDNE 237 1.1 christos #define FCONDZ FCONDE 238 1.1 christos 239 1.1 christos #define ICC (0) /* v9 */ 240 1.1 christos #define XCC (1 << 12) /* v9 */ 241 1.1 christos #define CBCOND_XCC (1 << 21) 242 1.1 christos #define FCC(x) (((x) & 0x3) << 11) /* v9 */ 243 1.1 christos #define FBFCC(x) (((x) & 0x3) << 20) /* v9 */ 244 1.1 christos 245 1.1 christos /* The order of the opcodes in the table is significant: 247 1.1 christos 248 1.1 christos * The assembler requires that all instances of the same mnemonic must 249 1.1 christos be consecutive. If they aren't, the assembler will bomb at runtime. 250 1.1 christos 251 1.1 christos * The disassembler should not care about the order of the opcodes. */ 252 1.1 christos 253 1.1 christos /* Entries for commutative arithmetic operations. */ 254 1.3 christos /* ??? More entries can make use of this. */ 255 1.3 christos #define COMMUTEOP(opcode, op3, arch_mask) \ 256 1.3 christos { opcode, F3(2, op3, 0), F3(~2, ~op3, ~0)|ASI(~0), "1,2,d", 0, 0, 0, arch_mask }, \ 257 1.1 christos { opcode, F3(2, op3, 1), F3(~2, ~op3, ~1), "1,i,d", 0, 0, 0, arch_mask }, \ 258 1.1 christos { opcode, F3(2, op3, 1), F3(~2, ~op3, ~1), "i,1,d", 0, 0, 0, arch_mask } 259 1.1 christos 260 1.3 christos const struct sparc_opcode sparc_opcodes[] = { 261 1.3 christos 262 1.3 christos { "ld", F3(3, 0x00, 0), F3(~3, ~0x00, ~0), "[1+2],d", 0, 0, 0, v6 }, 263 1.3 christos { "ld", F3(3, 0x00, 0), F3(~3, ~0x00, ~0)|RS2_G0, "[1],d", 0, 0, 0, v6 }, /* ld [rs1+%g0],d */ 264 1.3 christos { "ld", F3(3, 0x00, 1), F3(~3, ~0x00, ~1), "[1+i],d", 0, 0, 0, v6 }, 265 1.3 christos { "ld", F3(3, 0x00, 1), F3(~3, ~0x00, ~1), "[i+1],d", 0, 0, 0, v6 }, 266 1.3 christos { "ld", F3(3, 0x00, 1), F3(~3, ~0x00, ~1)|RS1_G0, "[i],d", 0, 0, 0, v6 }, 267 1.3 christos { "ld", F3(3, 0x00, 1), F3(~3, ~0x00, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v6 }, /* ld [rs1+0],d */ 268 1.3 christos { "ld", F3(3, 0x20, 0), F3(~3, ~0x20, ~0), "[1+2],g", 0, 0, 0, v6 }, 269 1.3 christos { "ld", F3(3, 0x20, 0), F3(~3, ~0x20, ~0)|RS2_G0, "[1],g", 0, 0, 0, v6 }, /* ld [rs1+%g0],d */ 270 1.3 christos { "ld", F3(3, 0x20, 1), F3(~3, ~0x20, ~1), "[1+i],g", 0, 0, 0, v6 }, 271 1.3 christos { "ld", F3(3, 0x20, 1), F3(~3, ~0x20, ~1), "[i+1],g", 0, 0, 0, v6 }, 272 1.3 christos { "ld", F3(3, 0x20, 1), F3(~3, ~0x20, ~1)|RS1_G0, "[i],g", 0, 0, 0, v6 }, 273 1.3 christos { "ld", F3(3, 0x20, 1), F3(~3, ~0x20, ~1)|SIMM13(~0), "[1],g", 0, 0, 0, v6 }, /* ld [rs1+0],d */ 274 1.3 christos 275 1.3 christos { "ld", F3(3, 0x21, 0), F3(~3, ~0x21, ~0)|RD(~0), "[1+2],F", 0, 0, 0, v6 }, 276 1.3 christos { "ld", F3(3, 0x21, 0), F3(~3, ~0x21, ~0)|RS2_G0|RD(~0),"[1],F", 0, 0, 0, v6 }, /* ld [rs1+%g0],d */ 277 1.3 christos { "ld", F3(3, 0x21, 1), F3(~3, ~0x21, ~1)|RD(~0), "[1+i],F", 0, 0, 0, v6 }, 278 1.3 christos { "ld", F3(3, 0x21, 1), F3(~3, ~0x21, ~1)|RD(~0), "[i+1],F", 0, 0, 0, v6 }, 279 1.3 christos { "ld", F3(3, 0x21, 1), F3(~3, ~0x21, ~1)|RS1_G0|RD(~0),"[i],F", 0, 0, 0, v6 }, 280 1.3 christos { "ld", F3(3, 0x21, 1), F3(~3, ~0x21, ~1)|SIMM13(~0)|RD(~0),"[1],F", 0, 0, 0, v6 }, /* ld [rs1+0],d */ 281 1.3 christos 282 1.3 christos { "ld", F3(3, 0x30, 0), F3(~3, ~0x30, ~0), "[1+2],D", 0, 0, 0, v6notv9 }, 283 1.3 christos { "ld", F3(3, 0x30, 0), F3(~3, ~0x30, ~0)|RS2_G0, "[1],D", 0, 0, 0, v6notv9 }, /* ld [rs1+%g0],d */ 284 1.3 christos { "ld", F3(3, 0x30, 1), F3(~3, ~0x30, ~1), "[1+i],D", 0, 0, 0, v6notv9 }, 285 1.3 christos { "ld", F3(3, 0x30, 1), F3(~3, ~0x30, ~1), "[i+1],D", 0, 0, 0, v6notv9 }, 286 1.3 christos { "ld", F3(3, 0x30, 1), F3(~3, ~0x30, ~1)|RS1_G0, "[i],D", 0, 0, 0, v6notv9 }, 287 1.3 christos { "ld", F3(3, 0x30, 1), F3(~3, ~0x30, ~1)|SIMM13(~0), "[1],D", 0, 0, 0, v6notv9 }, /* ld [rs1+0],d */ 288 1.3 christos { "ld", F3(3, 0x31, 0), F3(~3, ~0x31, ~0), "[1+2],C", 0, 0, 0, v6notv9 }, 289 1.3 christos { "ld", F3(3, 0x31, 0), F3(~3, ~0x31, ~0)|RS2_G0, "[1],C", 0, 0, 0, v6notv9 }, /* ld [rs1+%g0],d */ 290 1.3 christos { "ld", F3(3, 0x31, 1), F3(~3, ~0x31, ~1), "[1+i],C", 0, 0, 0, v6notv9 }, 291 1.3 christos { "ld", F3(3, 0x31, 1), F3(~3, ~0x31, ~1), "[i+1],C", 0, 0, 0, v6notv9 }, 292 1.1 christos { "ld", F3(3, 0x31, 1), F3(~3, ~0x31, ~1)|RS1_G0, "[i],C", 0, 0, 0, v6notv9 }, 293 1.1 christos { "ld", F3(3, 0x31, 1), F3(~3, ~0x31, ~1)|SIMM13(~0), "[1],C", 0, 0, 0, v6notv9 }, /* ld [rs1+0],d */ 294 1.1 christos 295 1.3 christos /* The v9 LDUW is the same as the old 'ld' opcode, it is not the same as the 296 1.3 christos 'ld' pseudo-op in v9. */ 297 1.3 christos { "lduw", F3(3, 0x00, 0), F3(~3, ~0x00, ~0), "[1+2],d", F_ALIAS, 0, 0, v9 }, 298 1.3 christos { "lduw", F3(3, 0x00, 0), F3(~3, ~0x00, ~0)|RS2_G0, "[1],d", F_ALIAS, 0, 0, v9 }, /* ld [rs1+%g0],d */ 299 1.3 christos { "lduw", F3(3, 0x00, 1), F3(~3, ~0x00, ~1), "[1+i],d", F_ALIAS, 0, 0, v9 }, 300 1.3 christos { "lduw", F3(3, 0x00, 1), F3(~3, ~0x00, ~1), "[i+1],d", F_ALIAS, 0, 0, v9 }, 301 1.3 christos { "lduw", F3(3, 0x00, 1), F3(~3, ~0x00, ~1)|RS1_G0, "[i],d", F_ALIAS, 0, 0, v9 }, 302 1.3 christos { "lduw", F3(3, 0x00, 1), F3(~3, ~0x00, ~1)|SIMM13(~0), "[1],d", F_ALIAS, 0, 0, v9 }, /* ld [rs1+0],d */ 303 1.3 christos 304 1.3 christos { "ldtw", F3(3, 0x03, 0), F3(~3, ~0x03, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v9 }, 305 1.3 christos { "ldtw", F3(3, 0x03, 0), F3(~3, ~0x03, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v9 }, /* ldd [rs1+%g0],d */ 306 1.3 christos { "ldtw", F3(3, 0x03, 1), F3(~3, ~0x03, ~1), "[1+i],d", 0, 0, 0, v9 }, 307 1.3 christos { "ldtw", F3(3, 0x03, 1), F3(~3, ~0x03, ~1), "[i+1],d", 0, 0, 0, v9 }, 308 1.3 christos { "ldtw", F3(3, 0x03, 1), F3(~3, ~0x03, ~1)|RS1_G0, "[i],d", 0, 0, 0, v9 }, 309 1.3 christos { "ldtw", F3(3, 0x03, 1), F3(~3, ~0x03, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v9 }, /* ldd [rs1+0],d */ 310 1.3 christos 311 1.3 christos { "ldd", F3(3, 0x03, 0), F3(~3, ~0x03, ~0)|ASI(~0), "[1+2],d", F_ALIAS, 0, 0, v6 }, 312 1.3 christos { "ldd", F3(3, 0x03, 0), F3(~3, ~0x03, ~0)|ASI_RS2(~0), "[1],d", F_ALIAS, 0, 0, v6 }, /* ldd [rs1+%g0],d */ 313 1.3 christos { "ldd", F3(3, 0x03, 1), F3(~3, ~0x03, ~1), "[1+i],d", F_ALIAS, 0, 0, v6 }, 314 1.3 christos { "ldd", F3(3, 0x03, 1), F3(~3, ~0x03, ~1), "[i+1],d", F_ALIAS, 0, 0, v6 }, 315 1.3 christos { "ldd", F3(3, 0x03, 1), F3(~3, ~0x03, ~1)|RS1_G0, "[i],d", F_ALIAS, 0, 0, v6 }, 316 1.3 christos { "ldd", F3(3, 0x03, 1), F3(~3, ~0x03, ~1)|SIMM13(~0), "[1],d", F_ALIAS, 0, 0, v6 }, /* ldd [rs1+0],d */ 317 1.3 christos { "ldd", F3(3, 0x23, 0), F3(~3, ~0x23, ~0)|ASI(~0), "[1+2],H", F_ALIAS, 0, 0, v6 }, 318 1.3 christos { "ldd", F3(3, 0x23, 0), F3(~3, ~0x23, ~0)|ASI_RS2(~0), "[1],H", F_ALIAS, 0, 0, v6 }, /* ldd [rs1+%g0],d */ 319 1.3 christos { "ldd", F3(3, 0x23, 1), F3(~3, ~0x23, ~1), "[1+i],H", F_ALIAS, 0, 0, v6 }, 320 1.3 christos { "ldd", F3(3, 0x23, 1), F3(~3, ~0x23, ~1), "[i+1],H", F_ALIAS, 0, 0, v6 }, 321 1.3 christos { "ldd", F3(3, 0x23, 1), F3(~3, ~0x23, ~1)|RS1_G0, "[i],H", F_ALIAS, 0, 0, v6 }, 322 1.3 christos { "ldd", F3(3, 0x23, 1), F3(~3, ~0x23, ~1)|SIMM13(~0), "[1],H", F_ALIAS, 0, 0, v6 }, /* ldd [rs1+0],d */ 323 1.3 christos 324 1.3 christos { "ldd", F3(3, 0x33, 0), F3(~3, ~0x33, ~0)|ASI(~0), "[1+2],D", 0, 0, 0, v6notv9 }, 325 1.3 christos { "ldd", F3(3, 0x33, 0), F3(~3, ~0x33, ~0)|ASI_RS2(~0), "[1],D", 0, 0, 0, v6notv9 }, /* ldd [rs1+%g0],d */ 326 1.3 christos { "ldd", F3(3, 0x33, 1), F3(~3, ~0x33, ~1), "[1+i],D", 0, 0, 0, v6notv9 }, 327 1.3 christos { "ldd", F3(3, 0x33, 1), F3(~3, ~0x33, ~1), "[i+1],D", 0, 0, 0, v6notv9 }, 328 1.3 christos { "ldd", F3(3, 0x33, 1), F3(~3, ~0x33, ~1)|RS1_G0, "[i],D", 0, 0, 0, v6notv9 }, 329 1.3 christos { "ldd", F3(3, 0x33, 1), F3(~3, ~0x33, ~1)|SIMM13(~0), "[1],D", 0, 0, 0, v6notv9 }, /* ldd [rs1+0],d */ 330 1.3 christos 331 1.3 christos { "ldq", F3(3, 0x22, 0), F3(~3, ~0x22, ~0)|ASI(~0), "[1+2],J", 0, 0, 0, v9 }, 332 1.3 christos { "ldq", F3(3, 0x22, 0), F3(~3, ~0x22, ~0)|ASI_RS2(~0), "[1],J", 0, 0, 0, v9 }, /* ldd [rs1+%g0],d */ 333 1.3 christos { "ldq", F3(3, 0x22, 1), F3(~3, ~0x22, ~1), "[1+i],J", 0, 0, 0, v9 }, 334 1.3 christos { "ldq", F3(3, 0x22, 1), F3(~3, ~0x22, ~1), "[i+1],J", 0, 0, 0, v9 }, 335 1.3 christos { "ldq", F3(3, 0x22, 1), F3(~3, ~0x22, ~1)|RS1_G0, "[i],J", 0, 0, 0, v9 }, 336 1.3 christos { "ldq", F3(3, 0x22, 1), F3(~3, ~0x22, ~1)|SIMM13(~0), "[1],J", 0, 0, 0, v9 }, /* ldd [rs1+0],d */ 337 1.3 christos 338 1.3 christos { "ldsb", F3(3, 0x09, 0), F3(~3, ~0x09, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v6 }, 339 1.3 christos { "ldsb", F3(3, 0x09, 0), F3(~3, ~0x09, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v6 }, /* ldsb [rs1+%g0],d */ 340 1.3 christos { "ldsb", F3(3, 0x09, 1), F3(~3, ~0x09, ~1), "[1+i],d", 0, 0, 0, v6 }, 341 1.3 christos { "ldsb", F3(3, 0x09, 1), F3(~3, ~0x09, ~1), "[i+1],d", 0, 0, 0, v6 }, 342 1.3 christos { "ldsb", F3(3, 0x09, 1), F3(~3, ~0x09, ~1)|RS1_G0, "[i],d", 0, 0, 0, v6 }, 343 1.3 christos { "ldsb", F3(3, 0x09, 1), F3(~3, ~0x09, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v6 }, /* ldsb [rs1+0],d */ 344 1.3 christos 345 1.3 christos { "ldsh", F3(3, 0x0a, 0), F3(~3, ~0x0a, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v6 }, /* ldsh [rs1+%g0],d */ 346 1.3 christos { "ldsh", F3(3, 0x0a, 0), F3(~3, ~0x0a, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v6 }, 347 1.3 christos { "ldsh", F3(3, 0x0a, 1), F3(~3, ~0x0a, ~1), "[1+i],d", 0, 0, 0, v6 }, 348 1.3 christos { "ldsh", F3(3, 0x0a, 1), F3(~3, ~0x0a, ~1), "[i+1],d", 0, 0, 0, v6 }, 349 1.3 christos { "ldsh", F3(3, 0x0a, 1), F3(~3, ~0x0a, ~1)|RS1_G0, "[i],d", 0, 0, 0, v6 }, 350 1.3 christos { "ldsh", F3(3, 0x0a, 1), F3(~3, ~0x0a, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v6 }, /* ldsh [rs1+0],d */ 351 1.3 christos 352 1.3 christos { "ldstub", F3(3, 0x0d, 0), F3(~3, ~0x0d, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v6 }, 353 1.3 christos { "ldstub", F3(3, 0x0d, 0), F3(~3, ~0x0d, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v6 }, /* ldstub [rs1+%g0],d */ 354 1.3 christos { "ldstub", F3(3, 0x0d, 1), F3(~3, ~0x0d, ~1), "[1+i],d", 0, 0, 0, v6 }, 355 1.3 christos { "ldstub", F3(3, 0x0d, 1), F3(~3, ~0x0d, ~1), "[i+1],d", 0, 0, 0, v6 }, 356 1.3 christos { "ldstub", F3(3, 0x0d, 1), F3(~3, ~0x0d, ~1)|RS1_G0, "[i],d", 0, 0, 0, v6 }, 357 1.3 christos { "ldstub", F3(3, 0x0d, 1), F3(~3, ~0x0d, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v6 }, /* ldstub [rs1+0],d */ 358 1.3 christos 359 1.3 christos { "ldsw", F3(3, 0x08, 0), F3(~3, ~0x08, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v9 }, 360 1.3 christos { "ldsw", F3(3, 0x08, 0), F3(~3, ~0x08, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v9 }, /* ldsw [rs1+%g0],d */ 361 1.3 christos { "ldsw", F3(3, 0x08, 1), F3(~3, ~0x08, ~1), "[1+i],d", 0, 0, 0, v9 }, 362 1.3 christos { "ldsw", F3(3, 0x08, 1), F3(~3, ~0x08, ~1), "[i+1],d", 0, 0, 0, v9 }, 363 1.3 christos { "ldsw", F3(3, 0x08, 1), F3(~3, ~0x08, ~1)|RS1_G0, "[i],d", 0, 0, 0, v9 }, 364 1.3 christos { "ldsw", F3(3, 0x08, 1), F3(~3, ~0x08, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v9 }, /* ldsw [rs1+0],d */ 365 1.3 christos 366 1.3 christos { "ldub", F3(3, 0x01, 0), F3(~3, ~0x01, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v6 }, 367 1.3 christos { "ldub", F3(3, 0x01, 0), F3(~3, ~0x01, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v6 }, /* ldub [rs1+%g0],d */ 368 1.3 christos { "ldub", F3(3, 0x01, 1), F3(~3, ~0x01, ~1), "[1+i],d", 0, 0, 0, v6 }, 369 1.3 christos { "ldub", F3(3, 0x01, 1), F3(~3, ~0x01, ~1), "[i+1],d", 0, 0, 0, v6 }, 370 1.3 christos { "ldub", F3(3, 0x01, 1), F3(~3, ~0x01, ~1)|RS1_G0, "[i],d", 0, 0, 0, v6 }, 371 1.3 christos { "ldub", F3(3, 0x01, 1), F3(~3, ~0x01, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v6 }, /* ldub [rs1+0],d */ 372 1.3 christos 373 1.3 christos { "lduh", F3(3, 0x02, 0), F3(~3, ~0x02, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v6 }, 374 1.3 christos { "lduh", F3(3, 0x02, 0), F3(~3, ~0x02, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v6 }, /* lduh [rs1+%g0],d */ 375 1.3 christos { "lduh", F3(3, 0x02, 1), F3(~3, ~0x02, ~1), "[1+i],d", 0, 0, 0, v6 }, 376 1.3 christos { "lduh", F3(3, 0x02, 1), F3(~3, ~0x02, ~1), "[i+1],d", 0, 0, 0, v6 }, 377 1.3 christos { "lduh", F3(3, 0x02, 1), F3(~3, ~0x02, ~1)|RS1_G0, "[i],d", 0, 0, 0, v6 }, 378 1.3 christos { "lduh", F3(3, 0x02, 1), F3(~3, ~0x02, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v6 }, /* lduh [rs1+0],d */ 379 1.3 christos 380 1.3 christos { "ldx", F3(3, 0x0b, 0), F3(~3, ~0x0b, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v9 }, 381 1.3 christos { "ldx", F3(3, 0x0b, 0), F3(~3, ~0x0b, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v9 }, /* ldx [rs1+%g0],d */ 382 1.3 christos { "ldx", F3(3, 0x0b, 1), F3(~3, ~0x0b, ~1), "[1+i],d", 0, 0, 0, v9 }, 383 1.3 christos { "ldx", F3(3, 0x0b, 1), F3(~3, ~0x0b, ~1), "[i+1],d", 0, 0, 0, v9 }, 384 1.3 christos { "ldx", F3(3, 0x0b, 1), F3(~3, ~0x0b, ~1)|RS1_G0, "[i],d", 0, 0, 0, v9 }, 385 1.3 christos { "ldx", F3(3, 0x0b, 1), F3(~3, ~0x0b, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v9 }, /* ldx [rs1+0],d */ 386 1.3 christos 387 1.3 christos { "ldx", F3(3, 0x21, 0)|RD(1), F3(~3, ~0x21, ~0)|RD(~1), "[1+2],F", 0, 0, 0, v9 }, 388 1.3 christos { "ldx", F3(3, 0x21, 0)|RD(1), F3(~3, ~0x21, ~0)|RS2_G0|RD(~1), "[1],F", 0, 0, 0, v9 }, /* ld [rs1+%g0],d */ 389 1.3 christos { "ldx", F3(3, 0x21, 1)|RD(1), F3(~3, ~0x21, ~1)|RD(~1), "[1+i],F", 0, 0, 0, v9 }, 390 1.3 christos { "ldx", F3(3, 0x21, 1)|RD(1), F3(~3, ~0x21, ~1)|RD(~1), "[i+1],F", 0, 0, 0, v9 }, 391 1.3 christos { "ldx", F3(3, 0x21, 1)|RD(1), F3(~3, ~0x21, ~1)|RS1_G0|RD(~1), "[i],F", 0, 0, 0, v9 }, 392 1.6 christos { "ldx", F3(3, 0x21, 1)|RD(1), F3(~3, ~0x21, ~1)|SIMM13(~0)|RD(~1),"[1],F", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 393 1.6 christos 394 1.6 christos { "ldx", F3(3, 0x21, 0)|RD(3), F3(~3, ~0x21, ~0)|RD(~3), "[1+2],(", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, /* ldx [rs1+rs2],%efsr */ 395 1.6 christos { "ldx", F3(3, 0x21, 0)|RD(3), F3(~3, ~0x21, ~0)|RS2_G0|RD(~3),"[1],(", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, /* ldx [rs1],%efsr */ 396 1.6 christos { "ldx", F3(3, 0x21, 1)|RD(3), F3(~3, ~0x21, ~1)|RD(~3), "[1+i],(", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, /* ldx [%rs1+0],%efsr */ 397 1.6 christos { "ldx", F3(3, 0x21, 1)|RD(3), F3(~3, ~0x21, ~1)|RD(~3), "[i+1],(", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, /* ldx [0+%rs1],%efsr */ 398 1.3 christos { "ldx", F3(3, 0x21, 1)|RD(3), F3(~3, ~0x21, ~1)|RS1_G0|RD(~3),"[i],(", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, /* ldx [0],%efsr */ 399 1.3 christos { "ldx", F3(3, 0x21, 1)|RD(3), F3(~3, ~0x21, ~1)|SIMM13(~0)|RD(~3),"[1],(", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, /* ldx [%rs1], %efsr */ 400 1.3 christos 401 1.3 christos { "lda", F3(3, 0x10, 0), F3(~3, ~0x10, ~0), "[1+2]A,d", 0, 0, 0, v6 }, 402 1.3 christos { "lda", F3(3, 0x10, 0), F3(~3, ~0x10, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v6 }, /* lda [rs1+%g0],d */ 403 1.3 christos { "lda", F3(3, 0x10, 1), F3(~3, ~0x10, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 404 1.3 christos { "lda", F3(3, 0x10, 1), F3(~3, ~0x10, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 405 1.3 christos { "lda", F3(3, 0x10, 1), F3(~3, ~0x10, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 406 1.3 christos { "lda", F3(3, 0x10, 1), F3(~3, ~0x10, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 407 1.3 christos { "lda", F3(3, 0x30, 0), F3(~3, ~0x30, ~0), "[1+2]A,g", 0, 0, 0, v9 }, 408 1.3 christos { "lda", F3(3, 0x30, 0), F3(~3, ~0x30, ~0)|RS2_G0, "[1]A,g", 0, 0, 0, v9 }, /* lda [rs1+%g0],d */ 409 1.3 christos { "lda", F3(3, 0x30, 1), F3(~3, ~0x30, ~1), "[1+i]o,g", 0, 0, 0, v9 }, 410 1.3 christos { "lda", F3(3, 0x30, 1), F3(~3, ~0x30, ~1), "[i+1]o,g", 0, 0, 0, v9 }, 411 1.3 christos { "lda", F3(3, 0x30, 1), F3(~3, ~0x30, ~1)|RS1_G0, "[i]o,g", 0, 0, 0, v9 }, 412 1.6 christos { "lda", F3(3, 0x30, 1), F3(~3, ~0x30, ~1)|SIMM13(~0), "[1]o,g", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 413 1.6 christos 414 1.6 christos /* Note that the LDTXA instructions share an opcode with the 415 1.6 christos (deprecated) LDTWA instructions below. They are differenciated by 416 1.6 christos the combination of the `i' instruction field and the ASI used in 417 1.6 christos the instruction. */ 418 1.6 christos 419 1.6 christos #define ldtxa(asi) \ 420 1.6 christos { "ldtxa", F3(3, 0x13, 0)|ASI((asi)), F3(~3, ~0x13, ~0)|ASI(~(asi)), "[1+2]A,d", 0, HWCAP_ASI_BLK_INIT, 0, v9c }, \ 421 1.6 christos { "ldtxa", F3(3, 0x13, 0)|ASI((asi)), F3(~3, ~0x13, ~0)|ASI(~(asi))|RS2_G0, "[1]A,d", 0, HWCAP_ASI_BLK_INIT, 0, v9c } 422 1.6 christos 423 1.6 christos ldtxa (0x22), /* #ASI_TWINX_AIUP */ 424 1.6 christos ldtxa (0x23), /* #ASI_TWINX_AIUS */ 425 1.6 christos ldtxa (0x26), /* #ASI_TWINX_REAL */ 426 1.6 christos ldtxa (0x27), /* #ASI_TWINX_N */ 427 1.6 christos ldtxa (0x2A), /* #ASI_TWINX_AIUP_L */ 428 1.6 christos ldtxa (0x2B), /* #ASI_TWINX_AIUS_L */ 429 1.6 christos ldtxa (0x2E), /* #ASI_TWINX_REAL_L */ 430 1.6 christos ldtxa (0x2F), /* #ASI_TWINX_NL */ 431 1.6 christos ldtxa (0xE2), /* #ASI_TWINX_P */ 432 1.6 christos ldtxa (0xE3), /* #ASI_TWINX_S */ 433 1.6 christos ldtxa (0xEA), /* #ASI_TWINX_PL */ 434 1.3 christos ldtxa (0xEB), /* #ASI_TWINX_SL */ 435 1.3 christos 436 1.3 christos { "ldtwa", F3(3, 0x13, 0), F3(~3, ~0x13, ~0), "[1+2]A,d", 0, 0, 0, v9 }, 437 1.3 christos { "ldtwa", F3(3, 0x13, 0), F3(~3, ~0x13, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v9 }, /* ldda [rs1+%g0],d */ 438 1.3 christos { "ldtwa", F3(3, 0x13, 1), F3(~3, ~0x13, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 439 1.3 christos { "ldtwa", F3(3, 0x13, 1), F3(~3, ~0x13, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 440 1.3 christos { "ldtwa", F3(3, 0x13, 1), F3(~3, ~0x13, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 441 1.3 christos { "ldtwa", F3(3, 0x13, 1), F3(~3, ~0x13, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 442 1.3 christos 443 1.3 christos { "ldda", F3(3, 0x13, 0), F3(~3, ~0x13, ~0), "[1+2]A,d", F_ALIAS, 0, 0, v6 }, 444 1.3 christos { "ldda", F3(3, 0x13, 0), F3(~3, ~0x13, ~0)|RS2_G0, "[1]A,d", F_ALIAS, 0, 0, v6 }, /* ldda [rs1+%g0],d */ 445 1.3 christos { "ldda", F3(3, 0x13, 1), F3(~3, ~0x13, ~1), "[1+i]o,d", F_ALIAS, 0, 0, v9 }, 446 1.3 christos { "ldda", F3(3, 0x13, 1), F3(~3, ~0x13, ~1), "[i+1]o,d", F_ALIAS, 0, 0, v9 }, 447 1.3 christos { "ldda", F3(3, 0x13, 1), F3(~3, ~0x13, ~1)|RS1_G0, "[i]o,d", F_ALIAS, 0, 0, v9 }, 448 1.3 christos { "ldda", F3(3, 0x13, 1), F3(~3, ~0x13, ~1)|SIMM13(~0), "[1]o,d", F_ALIAS, 0, 0, v9 }, /* ld [rs1+0],d */ 449 1.3 christos 450 1.3 christos { "ldda", F3(3, 0x33, 0), F3(~3, ~0x33, ~0), "[1+2]A,H", 0, 0, 0, v9 }, 451 1.3 christos { "ldda", F3(3, 0x33, 0), F3(~3, ~0x33, ~0)|RS2_G0, "[1]A,H", 0, 0, 0, v9 }, /* ldda [rs1+%g0],d */ 452 1.3 christos { "ldda", F3(3, 0x33, 1), F3(~3, ~0x33, ~1), "[1+i]o,H", 0, 0, 0, v9 }, 453 1.3 christos { "ldda", F3(3, 0x33, 1), F3(~3, ~0x33, ~1), "[i+1]o,H", 0, 0, 0, v9 }, 454 1.3 christos { "ldda", F3(3, 0x33, 1), F3(~3, ~0x33, ~1)|RS1_G0, "[i]o,H", 0, 0, 0, v9 }, 455 1.3 christos { "ldda", F3(3, 0x33, 1), F3(~3, ~0x33, ~1)|SIMM13(~0), "[1]o,H", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 456 1.3 christos 457 1.3 christos { "ldqa", F3(3, 0x32, 0), F3(~3, ~0x32, ~0), "[1+2]A,J", 0, 0, 0, v9 }, 458 1.3 christos { "ldqa", F3(3, 0x32, 0), F3(~3, ~0x32, ~0)|RS2_G0, "[1]A,J", 0, 0, 0, v9 }, /* ldd [rs1+%g0],d */ 459 1.3 christos { "ldqa", F3(3, 0x32, 1), F3(~3, ~0x32, ~1), "[1+i]o,J", 0, 0, 0, v9 }, 460 1.3 christos { "ldqa", F3(3, 0x32, 1), F3(~3, ~0x32, ~1), "[i+1]o,J", 0, 0, 0, v9 }, 461 1.3 christos { "ldqa", F3(3, 0x32, 1), F3(~3, ~0x32, ~1)|RS1_G0, "[i]o,J", 0, 0, 0, v9 }, 462 1.3 christos { "ldqa", F3(3, 0x32, 1), F3(~3, ~0x32, ~1)|SIMM13(~0), "[1]o,J", 0, 0, 0, v9 }, /* ldd [rs1+0],d */ 463 1.3 christos 464 1.3 christos { "ldsba", F3(3, 0x19, 0), F3(~3, ~0x19, ~0), "[1+2]A,d", 0, 0, 0, v6 }, 465 1.3 christos { "ldsba", F3(3, 0x19, 0), F3(~3, ~0x19, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v6 }, /* ldsba [rs1+%g0],d */ 466 1.3 christos { "ldsba", F3(3, 0x19, 1), F3(~3, ~0x19, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 467 1.3 christos { "ldsba", F3(3, 0x19, 1), F3(~3, ~0x19, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 468 1.3 christos { "ldsba", F3(3, 0x19, 1), F3(~3, ~0x19, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 469 1.3 christos { "ldsba", F3(3, 0x19, 1), F3(~3, ~0x19, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 470 1.3 christos 471 1.3 christos { "ldsha", F3(3, 0x1a, 0), F3(~3, ~0x1a, ~0), "[1+2]A,d", 0, 0, 0, v6 }, 472 1.3 christos { "ldsha", F3(3, 0x1a, 0), F3(~3, ~0x1a, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v6 }, /* ldsha [rs1+%g0],d */ 473 1.3 christos { "ldsha", F3(3, 0x1a, 1), F3(~3, ~0x1a, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 474 1.3 christos { "ldsha", F3(3, 0x1a, 1), F3(~3, ~0x1a, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 475 1.3 christos { "ldsha", F3(3, 0x1a, 1), F3(~3, ~0x1a, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 476 1.3 christos { "ldsha", F3(3, 0x1a, 1), F3(~3, ~0x1a, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 477 1.3 christos 478 1.3 christos { "ldstuba", F3(3, 0x1d, 0), F3(~3, ~0x1d, ~0), "[1+2]A,d", 0, 0, 0, v6 }, 479 1.3 christos { "ldstuba", F3(3, 0x1d, 0), F3(~3, ~0x1d, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v6 }, /* ldstuba [rs1+%g0],d */ 480 1.3 christos { "ldstuba", F3(3, 0x1d, 1), F3(~3, ~0x1d, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 481 1.3 christos { "ldstuba", F3(3, 0x1d, 1), F3(~3, ~0x1d, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 482 1.3 christos { "ldstuba", F3(3, 0x1d, 1), F3(~3, ~0x1d, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 483 1.3 christos { "ldstuba", F3(3, 0x1d, 1), F3(~3, ~0x1d, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 484 1.3 christos 485 1.3 christos { "ldswa", F3(3, 0x18, 0), F3(~3, ~0x18, ~0), "[1+2]A,d", 0, 0, 0, v9 }, 486 1.3 christos { "ldswa", F3(3, 0x18, 0), F3(~3, ~0x18, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v9 }, /* lda [rs1+%g0],d */ 487 1.3 christos { "ldswa", F3(3, 0x18, 1), F3(~3, ~0x18, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 488 1.3 christos { "ldswa", F3(3, 0x18, 1), F3(~3, ~0x18, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 489 1.3 christos { "ldswa", F3(3, 0x18, 1), F3(~3, ~0x18, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 490 1.3 christos { "ldswa", F3(3, 0x18, 1), F3(~3, ~0x18, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 491 1.3 christos 492 1.3 christos { "lduba", F3(3, 0x11, 0), F3(~3, ~0x11, ~0), "[1+2]A,d", 0, 0, 0, v6 }, 493 1.3 christos { "lduba", F3(3, 0x11, 0), F3(~3, ~0x11, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v6 }, /* lduba [rs1+%g0],d */ 494 1.3 christos { "lduba", F3(3, 0x11, 1), F3(~3, ~0x11, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 495 1.3 christos { "lduba", F3(3, 0x11, 1), F3(~3, ~0x11, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 496 1.3 christos { "lduba", F3(3, 0x11, 1), F3(~3, ~0x11, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 497 1.3 christos { "lduba", F3(3, 0x11, 1), F3(~3, ~0x11, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 498 1.3 christos 499 1.3 christos { "lduha", F3(3, 0x12, 0), F3(~3, ~0x12, ~0), "[1+2]A,d", 0, 0, 0, v6 }, 500 1.3 christos { "lduha", F3(3, 0x12, 0), F3(~3, ~0x12, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v6 }, /* lduha [rs1+%g0],d */ 501 1.3 christos { "lduha", F3(3, 0x12, 1), F3(~3, ~0x12, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 502 1.3 christos { "lduha", F3(3, 0x12, 1), F3(~3, ~0x12, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 503 1.3 christos { "lduha", F3(3, 0x12, 1), F3(~3, ~0x12, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 504 1.3 christos { "lduha", F3(3, 0x12, 1), F3(~3, ~0x12, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 505 1.3 christos 506 1.3 christos { "lduwa", F3(3, 0x10, 0), F3(~3, ~0x10, ~0), "[1+2]A,d", F_ALIAS, 0, 0, v9 }, /* lduwa === lda */ 507 1.3 christos { "lduwa", F3(3, 0x10, 0), F3(~3, ~0x10, ~0)|RS2_G0, "[1]A,d", F_ALIAS, 0, 0, v9 }, /* lda [rs1+%g0],d */ 508 1.3 christos { "lduwa", F3(3, 0x10, 1), F3(~3, ~0x10, ~1), "[1+i]o,d", F_ALIAS, 0, 0, v9 }, 509 1.3 christos { "lduwa", F3(3, 0x10, 1), F3(~3, ~0x10, ~1), "[i+1]o,d", F_ALIAS, 0, 0, v9 }, 510 1.3 christos { "lduwa", F3(3, 0x10, 1), F3(~3, ~0x10, ~1)|RS1_G0, "[i]o,d", F_ALIAS, 0, 0, v9 }, 511 1.3 christos { "lduwa", F3(3, 0x10, 1), F3(~3, ~0x10, ~1)|SIMM13(~0), "[1]o,d", F_ALIAS, 0, 0, v9 }, /* ld [rs1+0],d */ 512 1.3 christos 513 1.3 christos { "ldxa", F3(3, 0x1b, 0), F3(~3, ~0x1b, ~0), "[1+2]A,d", 0, 0, 0, v9 }, 514 1.3 christos { "ldxa", F3(3, 0x1b, 0), F3(~3, ~0x1b, ~0)|RS2_G0, "[1]A,d", 0, 0, 0, v9 }, /* lda [rs1+%g0],d */ 515 1.3 christos { "ldxa", F3(3, 0x1b, 1), F3(~3, ~0x1b, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 516 1.3 christos { "ldxa", F3(3, 0x1b, 1), F3(~3, ~0x1b, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 517 1.3 christos { "ldxa", F3(3, 0x1b, 1), F3(~3, ~0x1b, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 518 1.3 christos { "ldxa", F3(3, 0x1b, 1), F3(~3, ~0x1b, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* ld [rs1+0],d */ 519 1.3 christos 520 1.3 christos { "st", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI(~0), "d,[1+2]", 0, 0, 0, v6 }, 521 1.3 christos { "st", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI_RS2(~0), "d,[1]", 0, 0, 0, v6 }, /* st d,[rs1+%g0] */ 522 1.3 christos { "st", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[1+i]", 0, 0, 0, v6 }, 523 1.3 christos { "st", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[i+1]", 0, 0, 0, v6 }, 524 1.3 christos { "st", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RS1_G0, "d,[i]", 0, 0, 0, v6 }, 525 1.3 christos { "st", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|SIMM13(~0), "d,[1]", 0, 0, 0, v6 }, /* st d,[rs1+0] */ 526 1.3 christos { "st", F3(3, 0x24, 0), F3(~3, ~0x24, ~0)|ASI(~0), "g,[1+2]", 0, 0, 0, v6 }, 527 1.3 christos { "st", F3(3, 0x24, 0), F3(~3, ~0x24, ~0)|ASI_RS2(~0), "g,[1]", 0, 0, 0, v6 }, /* st d[rs1+%g0] */ 528 1.3 christos { "st", F3(3, 0x24, 1), F3(~3, ~0x24, ~1), "g,[1+i]", 0, 0, 0, v6 }, 529 1.3 christos { "st", F3(3, 0x24, 1), F3(~3, ~0x24, ~1), "g,[i+1]", 0, 0, 0, v6 }, 530 1.3 christos { "st", F3(3, 0x24, 1), F3(~3, ~0x24, ~1)|RS1_G0, "g,[i]", 0, 0, 0, v6 }, 531 1.3 christos { "st", F3(3, 0x24, 1), F3(~3, ~0x24, ~1)|SIMM13(~0), "g,[1]", 0, 0, 0, v6 }, /* st d,[rs1+0] */ 532 1.3 christos 533 1.3 christos { "st", F3(3, 0x34, 0), F3(~3, ~0x34, ~0)|ASI(~0), "D,[1+2]", 0, 0, 0, v6notv9 }, 534 1.3 christos { "st", F3(3, 0x34, 0), F3(~3, ~0x34, ~0)|ASI_RS2(~0), "D,[1]", 0, 0, 0, v6notv9 }, /* st d,[rs1+%g0] */ 535 1.3 christos { "st", F3(3, 0x34, 1), F3(~3, ~0x34, ~1), "D,[1+i]", 0, 0, 0, v6notv9 }, 536 1.3 christos { "st", F3(3, 0x34, 1), F3(~3, ~0x34, ~1), "D,[i+1]", 0, 0, 0, v6notv9 }, 537 1.3 christos { "st", F3(3, 0x34, 1), F3(~3, ~0x34, ~1)|RS1_G0, "D,[i]", 0, 0, 0, v6notv9 }, 538 1.3 christos { "st", F3(3, 0x34, 1), F3(~3, ~0x34, ~1)|SIMM13(~0), "D,[1]", 0, 0, 0, v6notv9 }, /* st d,[rs1+0] */ 539 1.3 christos { "st", F3(3, 0x35, 0), F3(~3, ~0x35, ~0)|ASI(~0), "C,[1+2]", 0, 0, 0, v6notv9 }, 540 1.3 christos { "st", F3(3, 0x35, 0), F3(~3, ~0x35, ~0)|ASI_RS2(~0), "C,[1]", 0, 0, 0, v6notv9 }, /* st d,[rs1+%g0] */ 541 1.3 christos { "st", F3(3, 0x35, 1), F3(~3, ~0x35, ~1), "C,[1+i]", 0, 0, 0, v6notv9 }, 542 1.3 christos { "st", F3(3, 0x35, 1), F3(~3, ~0x35, ~1), "C,[i+1]", 0, 0, 0, v6notv9 }, 543 1.3 christos { "st", F3(3, 0x35, 1), F3(~3, ~0x35, ~1)|RS1_G0, "C,[i]", 0, 0, 0, v6notv9 }, 544 1.3 christos { "st", F3(3, 0x35, 1), F3(~3, ~0x35, ~1)|SIMM13(~0), "C,[1]", 0, 0, 0, v6notv9 }, /* st d,[rs1+0] */ 545 1.3 christos 546 1.3 christos { "st", F3(3, 0x25, 0), F3(~3, ~0x25, ~0)|RD_G0|ASI(~0), "F,[1+2]", 0, 0, 0, v6 }, 547 1.3 christos { "st", F3(3, 0x25, 0), F3(~3, ~0x25, ~0)|RD_G0|ASI_RS2(~0), "F,[1]", 0, 0, 0, v6 }, /* st d,[rs1+%g0] */ 548 1.3 christos { "st", F3(3, 0x25, 1), F3(~3, ~0x25, ~1)|RD_G0, "F,[1+i]", 0, 0, 0, v6 }, 549 1.3 christos { "st", F3(3, 0x25, 1), F3(~3, ~0x25, ~1)|RD_G0, "F,[i+1]", 0, 0, 0, v6 }, 550 1.3 christos { "st", F3(3, 0x25, 1), F3(~3, ~0x25, ~1)|RD_G0|RS1_G0, "F,[i]", 0, 0, 0, v6 }, 551 1.3 christos { "st", F3(3, 0x25, 1), F3(~3, ~0x25, ~1)|RD_G0|SIMM13(~0), "F,[1]", 0, 0, 0, v6 }, /* st d,[rs1+0] */ 552 1.3 christos 553 1.3 christos { "stw", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v9 }, 554 1.3 christos { "stw", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+%g0] */ 555 1.3 christos { "stw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[1+i]", F_ALIAS, 0, 0, v9 }, 556 1.3 christos { "stw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[i+1]", F_ALIAS, 0, 0, v9 }, 557 1.3 christos { "stw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v9 }, 558 1.3 christos { "stw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+0] */ 559 1.3 christos { "stsw", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v9 }, 560 1.3 christos { "stsw", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+%g0] */ 561 1.3 christos { "stsw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[1+i]", F_ALIAS, 0, 0, v9 }, 562 1.3 christos { "stsw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[i+1]", F_ALIAS, 0, 0, v9 }, 563 1.3 christos { "stsw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v9 }, 564 1.3 christos { "stsw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+0] */ 565 1.3 christos { "stuw", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v9 }, 566 1.3 christos { "stuw", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+%g0] */ 567 1.3 christos { "stuw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[1+i]", F_ALIAS, 0, 0, v9 }, 568 1.3 christos { "stuw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[i+1]", F_ALIAS, 0, 0, v9 }, 569 1.3 christos { "stuw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v9 }, 570 1.3 christos { "stuw", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+0] */ 571 1.3 christos 572 1.3 christos { "spill", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v6 }, 573 1.3 christos { "spill", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* st d,[rs1+%g0] */ 574 1.3 christos { "spill", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[1+i]", F_ALIAS, 0, 0, v6 }, 575 1.3 christos { "spill", F3(3, 0x04, 1), F3(~3, ~0x04, ~1), "d,[i+1]", F_ALIAS, 0, 0, v6 }, 576 1.3 christos { "spill", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v6 }, 577 1.3 christos { "spill", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* st d,[rs1+0] */ 578 1.3 christos 579 1.3 christos { "sta", F3(3, 0x14, 0), F3(~3, ~0x14, ~0), "d,[1+2]A", 0, 0, 0, v6 }, 580 1.3 christos { "sta", F3(3, 0x14, 0), F3(~3, ~0x14, ~0)|RS2(~0), "d,[1]A", 0, 0, 0, v6 }, /* sta d,[rs1+%g0] */ 581 1.3 christos { "sta", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[1+i]o", 0, 0, 0, v9 }, 582 1.3 christos { "sta", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[i+1]o", 0, 0, 0, v9 }, 583 1.3 christos { "sta", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|RS1_G0, "d,[i]o", 0, 0, 0, v9 }, 584 1.3 christos { "sta", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|SIMM13(~0), "d,[1]o", 0, 0, 0, v9 }, /* st d,[rs1+0] */ 585 1.3 christos 586 1.3 christos { "sta", F3(3, 0x34, 0), F3(~3, ~0x34, ~0), "g,[1+2]A", 0, 0, 0, v9 }, 587 1.3 christos { "sta", F3(3, 0x34, 0), F3(~3, ~0x34, ~0)|RS2(~0), "g,[1]A", 0, 0, 0, v9 }, /* sta d,[rs1+%g0] */ 588 1.3 christos { "sta", F3(3, 0x34, 1), F3(~3, ~0x34, ~1), "g,[1+i]o", 0, 0, 0, v9 }, 589 1.3 christos { "sta", F3(3, 0x34, 1), F3(~3, ~0x34, ~1), "g,[i+1]o", 0, 0, 0, v9 }, 590 1.3 christos { "sta", F3(3, 0x34, 1), F3(~3, ~0x34, ~1)|RS1_G0, "g,[i]o", 0, 0, 0, v9 }, 591 1.3 christos { "sta", F3(3, 0x34, 1), F3(~3, ~0x34, ~1)|SIMM13(~0), "g,[1]o", 0, 0, 0, v9 }, /* st d,[rs1+0] */ 592 1.3 christos 593 1.3 christos { "stwa", F3(3, 0x14, 0), F3(~3, ~0x14, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v9 }, 594 1.3 christos { "stwa", F3(3, 0x14, 0), F3(~3, ~0x14, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v9 }, /* sta d,[rs1+%g0] */ 595 1.3 christos { "stwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 596 1.3 christos { "stwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 597 1.3 christos { "stwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 598 1.3 christos { "stwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+0] */ 599 1.3 christos { "stswa", F3(3, 0x14, 0), F3(~3, ~0x14, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v9 }, 600 1.3 christos { "stswa", F3(3, 0x14, 0), F3(~3, ~0x14, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v9 }, /* sta d,[rs1+%g0] */ 601 1.3 christos { "stswa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 602 1.3 christos { "stswa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 603 1.3 christos { "stswa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 604 1.3 christos { "stswa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+0] */ 605 1.3 christos { "stuwa", F3(3, 0x14, 0), F3(~3, ~0x14, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v9 }, 606 1.3 christos { "stuwa", F3(3, 0x14, 0), F3(~3, ~0x14, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v9 }, /* sta d,[rs1+%g0] */ 607 1.3 christos { "stuwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 608 1.3 christos { "stuwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 609 1.3 christos { "stuwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 610 1.3 christos { "stuwa", F3(3, 0x14, 1), F3(~3, ~0x14, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* st d,[rs1+0] */ 611 1.3 christos 612 1.3 christos { "stb", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|ASI(~0), "d,[1+2]", 0, 0, 0, v6 }, 613 1.3 christos { "stb", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|ASI_RS2(~0), "d,[1]", 0, 0, 0, v6 }, /* stb d,[rs1+%g0] */ 614 1.3 christos { "stb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1), "d,[1+i]", 0, 0, 0, v6 }, 615 1.3 christos { "stb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1), "d,[i+1]", 0, 0, 0, v6 }, 616 1.3 christos { "stb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RS1_G0, "d,[i]", 0, 0, 0, v6 }, 617 1.3 christos { "stb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|SIMM13(~0), "d,[1]", 0, 0, 0, v6 }, /* stb d,[rs1+0] */ 618 1.3 christos 619 1.3 christos { "stsb", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v6 }, 620 1.3 christos { "stsb", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* stb d,[rs1+%g0] */ 621 1.3 christos { "stsb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1), "d,[1+i]", F_ALIAS, 0, 0, v6 }, 622 1.3 christos { "stsb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1), "d,[i+1]", F_ALIAS, 0, 0, v6 }, 623 1.3 christos { "stsb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v6 }, 624 1.3 christos { "stsb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* stb d,[rs1+0] */ 625 1.3 christos { "stub", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v6 }, 626 1.3 christos { "stub", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* stb d,[rs1+%g0] */ 627 1.3 christos { "stub", F3(3, 0x05, 1), F3(~3, ~0x05, ~1), "d,[1+i]", F_ALIAS, 0, 0, v6 }, 628 1.3 christos { "stub", F3(3, 0x05, 1), F3(~3, ~0x05, ~1), "d,[i+1]", F_ALIAS, 0, 0, v6 }, 629 1.3 christos { "stub", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v6 }, 630 1.3 christos { "stub", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* stb d,[rs1+0] */ 631 1.3 christos 632 1.3 christos { "stba", F3(3, 0x15, 0), F3(~3, ~0x15, ~0), "d,[1+2]A", 0, 0, 0, v6 }, 633 1.3 christos { "stba", F3(3, 0x15, 0), F3(~3, ~0x15, ~0)|RS2(~0), "d,[1]A", 0, 0, 0, v6 }, /* stba d,[rs1+%g0] */ 634 1.3 christos { "stba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1), "d,[1+i]o", 0, 0, 0, v9 }, 635 1.3 christos { "stba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1), "d,[i+1]o", 0, 0, 0, v9 }, 636 1.3 christos { "stba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1)|RS1_G0, "d,[i]o", 0, 0, 0, v9 }, 637 1.3 christos { "stba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1)|SIMM13(~0), "d,[1]o", 0, 0, 0, v9 }, /* stb d,[rs1+0] */ 638 1.3 christos 639 1.3 christos { "stsba", F3(3, 0x15, 0), F3(~3, ~0x15, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v6 }, 640 1.3 christos { "stsba", F3(3, 0x15, 0), F3(~3, ~0x15, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v6 }, /* stba d,[rs1+%g0] */ 641 1.3 christos { "stsba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 642 1.3 christos { "stsba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 643 1.3 christos { "stsba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 644 1.3 christos { "stsba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* stb d,[rs1+0] */ 645 1.3 christos { "stuba", F3(3, 0x15, 0), F3(~3, ~0x15, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v6 }, 646 1.3 christos { "stuba", F3(3, 0x15, 0), F3(~3, ~0x15, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v6 }, /* stba d,[rs1+%g0] */ 647 1.3 christos { "stuba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 648 1.3 christos { "stuba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 649 1.3 christos { "stuba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 650 1.3 christos { "stuba", F3(3, 0x15, 1), F3(~3, ~0x15, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* stb d,[rs1+0] */ 651 1.3 christos 652 1.3 christos { "sttw", F3(3, 0x07, 0), F3(~3, ~0x07, ~0)|ASI(~0), "d,[1+2]", 0, 0, 0, v9 }, 653 1.3 christos { "sttw", F3(3, 0x07, 0), F3(~3, ~0x07, ~0)|ASI_RS2(~0), "d,[1]", 0, 0, 0, v9 }, /* std d,[rs1+%g0] */ 654 1.3 christos { "sttw", F3(3, 0x07, 1), F3(~3, ~0x07, ~1), "d,[1+i]", 0, 0, 0, v9 }, 655 1.3 christos { "sttw", F3(3, 0x07, 1), F3(~3, ~0x07, ~1), "d,[i+1]", 0, 0, 0, v9 }, 656 1.3 christos { "sttw", F3(3, 0x07, 1), F3(~3, ~0x07, ~1)|RS1_G0, "d,[i]", 0, 0, 0, v9 }, 657 1.3 christos { "sttw", F3(3, 0x07, 1), F3(~3, ~0x07, ~1)|SIMM13(~0), "d,[1]", 0, 0, 0, v9 }, /* std d,[rs1+0] */ 658 1.3 christos 659 1.3 christos { "std", F3(3, 0x07, 0), F3(~3, ~0x07, ~0)|ASI(~0), "d,[1+2]", F_PREF_ALIAS, 0, 0, v6 }, 660 1.3 christos { "std", F3(3, 0x07, 0), F3(~3, ~0x07, ~0)|ASI_RS2(~0), "d,[1]", F_PREF_ALIAS, 0, 0, v6 }, /* std d,[rs1+%g0] */ 661 1.3 christos { "std", F3(3, 0x07, 1), F3(~3, ~0x07, ~1), "d,[1+i]", F_PREF_ALIAS, 0, 0, v6 }, 662 1.3 christos { "std", F3(3, 0x07, 1), F3(~3, ~0x07, ~1), "d,[i+1]", F_PREF_ALIAS, 0, 0, v6 }, 663 1.3 christos { "std", F3(3, 0x07, 1), F3(~3, ~0x07, ~1)|RS1_G0, "d,[i]", F_PREF_ALIAS, 0, 0, v6 }, 664 1.3 christos { "std", F3(3, 0x07, 1), F3(~3, ~0x07, ~1)|SIMM13(~0), "d,[1]", F_PREF_ALIAS, 0, 0, v6 }, /* std d,[rs1+0] */ 665 1.3 christos 666 1.3 christos { "std", F3(3, 0x26, 0), F3(~3, ~0x26, ~0)|ASI(~0), "q,[1+2]", 0, 0, 0, v6notv9 }, 667 1.3 christos { "std", F3(3, 0x26, 0), F3(~3, ~0x26, ~0)|ASI_RS2(~0), "q,[1]", 0, 0, 0, v6notv9 }, /* std d,[rs1+%g0] */ 668 1.3 christos { "std", F3(3, 0x26, 1), F3(~3, ~0x26, ~1), "q,[1+i]", 0, 0, 0, v6notv9 }, 669 1.3 christos { "std", F3(3, 0x26, 1), F3(~3, ~0x26, ~1), "q,[i+1]", 0, 0, 0, v6notv9 }, 670 1.3 christos { "std", F3(3, 0x26, 1), F3(~3, ~0x26, ~1)|RS1_G0, "q,[i]", 0, 0, 0, v6notv9 }, 671 1.3 christos { "std", F3(3, 0x26, 1), F3(~3, ~0x26, ~1)|SIMM13(~0), "q,[1]", 0, 0, 0, v6notv9 }, /* std d,[rs1+0] */ 672 1.3 christos { "std", F3(3, 0x27, 0), F3(~3, ~0x27, ~0)|ASI(~0), "H,[1+2]", 0, 0, 0, v6 }, 673 1.3 christos { "std", F3(3, 0x27, 0), F3(~3, ~0x27, ~0)|ASI_RS2(~0), "H,[1]", 0, 0, 0, v6 }, /* std d,[rs1+%g0] */ 674 1.3 christos { "std", F3(3, 0x27, 1), F3(~3, ~0x27, ~1), "H,[1+i]", 0, 0, 0, v6 }, 675 1.3 christos { "std", F3(3, 0x27, 1), F3(~3, ~0x27, ~1), "H,[i+1]", 0, 0, 0, v6 }, 676 1.3 christos { "std", F3(3, 0x27, 1), F3(~3, ~0x27, ~1)|RS1_G0, "H,[i]", 0, 0, 0, v6 }, 677 1.3 christos { "std", F3(3, 0x27, 1), F3(~3, ~0x27, ~1)|SIMM13(~0), "H,[1]", 0, 0, 0, v6 }, /* std d,[rs1+0] */ 678 1.3 christos 679 1.3 christos { "std", F3(3, 0x36, 0), F3(~3, ~0x36, ~0)|ASI(~0), "Q,[1+2]", 0, 0, 0, v6notv9 }, 680 1.3 christos { "std", F3(3, 0x36, 0), F3(~3, ~0x36, ~0)|ASI_RS2(~0), "Q,[1]", 0, 0, 0, v6notv9 }, /* std d,[rs1+%g0] */ 681 1.3 christos { "std", F3(3, 0x36, 1), F3(~3, ~0x36, ~1), "Q,[1+i]", 0, 0, 0, v6notv9 }, 682 1.3 christos { "std", F3(3, 0x36, 1), F3(~3, ~0x36, ~1), "Q,[i+1]", 0, 0, 0, v6notv9 }, 683 1.3 christos { "std", F3(3, 0x36, 1), F3(~3, ~0x36, ~1)|RS1_G0, "Q,[i]", 0, 0, 0, v6notv9 }, 684 1.3 christos { "std", F3(3, 0x36, 1), F3(~3, ~0x36, ~1)|SIMM13(~0), "Q,[1]", 0, 0, 0, v6notv9 }, /* std d,[rs1+0] */ 685 1.3 christos { "std", F3(3, 0x37, 0), F3(~3, ~0x37, ~0)|ASI(~0), "D,[1+2]", 0, 0, 0, v6notv9 }, 686 1.3 christos { "std", F3(3, 0x37, 0), F3(~3, ~0x37, ~0)|ASI_RS2(~0), "D,[1]", 0, 0, 0, v6notv9 }, /* std d,[rs1+%g0] */ 687 1.3 christos { "std", F3(3, 0x37, 1), F3(~3, ~0x37, ~1), "D,[1+i]", 0, 0, 0, v6notv9 }, 688 1.3 christos { "std", F3(3, 0x37, 1), F3(~3, ~0x37, ~1), "D,[i+1]", 0, 0, 0, v6notv9 }, 689 1.3 christos { "std", F3(3, 0x37, 1), F3(~3, ~0x37, ~1)|RS1_G0, "D,[i]", 0, 0, 0, v6notv9 }, 690 1.3 christos { "std", F3(3, 0x37, 1), F3(~3, ~0x37, ~1)|SIMM13(~0), "D,[1]", 0, 0, 0, v6notv9 }, /* std d,[rs1+0] */ 691 1.3 christos 692 1.3 christos { "spilld", F3(3, 0x07, 0), F3(~3, ~0x07, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v6 }, 693 1.3 christos { "spilld", F3(3, 0x07, 0), F3(~3, ~0x07, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* std d,[rs1+%g0] */ 694 1.3 christos { "spilld", F3(3, 0x07, 1), F3(~3, ~0x07, ~1), "d,[1+i]", F_ALIAS, 0, 0, v6 }, 695 1.3 christos { "spilld", F3(3, 0x07, 1), F3(~3, ~0x07, ~1), "d,[i+1]", F_ALIAS, 0, 0, v6 }, 696 1.3 christos { "spilld", F3(3, 0x07, 1), F3(~3, ~0x07, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v6 }, 697 1.3 christos { "spilld", F3(3, 0x07, 1), F3(~3, ~0x07, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* std d,[rs1+0] */ 698 1.3 christos 699 1.3 christos { "sttwa", F3(3, 0x17, 0), F3(~3, ~0x17, ~0), "d,[1+2]A", 0, 0, 0, v9 }, 700 1.3 christos { "sttwa", F3(3, 0x17, 0), F3(~3, ~0x17, ~0)|RS2(~0), "d,[1]A", 0, 0, 0, v9 }, /* stda d,[rs1+%g0] */ 701 1.3 christos { "sttwa", F3(3, 0x17, 1), F3(~3, ~0x17, ~1), "d,[1+i]o", 0, 0, 0, v9 }, 702 1.3 christos { "sttwa", F3(3, 0x17, 1), F3(~3, ~0x17, ~1), "d,[i+1]o", 0, 0, 0, v9 }, 703 1.3 christos { "sttwa", F3(3, 0x17, 1), F3(~3, ~0x17, ~1)|RS1_G0, "d,[i]o", 0, 0, 0, v9 }, 704 1.3 christos { "sttwa", F3(3, 0x17, 1), F3(~3, ~0x17, ~1)|SIMM13(~0), "d,[1]o", 0, 0, 0, v9 }, /* std d,[rs1+0] */ 705 1.3 christos 706 1.3 christos { "stda", F3(3, 0x17, 0), F3(~3, ~0x17, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v6 }, 707 1.3 christos { "stda", F3(3, 0x17, 0), F3(~3, ~0x17, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v6 }, /* stda d,[rs1+%g0] */ 708 1.3 christos { "stda", F3(3, 0x17, 1), F3(~3, ~0x17, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 709 1.3 christos { "stda", F3(3, 0x17, 1), F3(~3, ~0x17, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 710 1.3 christos { "stda", F3(3, 0x17, 1), F3(~3, ~0x17, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 711 1.3 christos { "stda", F3(3, 0x17, 1), F3(~3, ~0x17, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* std d,[rs1+0] */ 712 1.3 christos { "stda", F3(3, 0x37, 0), F3(~3, ~0x37, ~0), "H,[1+2]A", 0, 0, 0, v9 }, 713 1.3 christos { "stda", F3(3, 0x37, 0), F3(~3, ~0x37, ~0)|RS2(~0), "H,[1]A", 0, 0, 0, v9 }, /* stda d,[rs1+%g0] */ 714 1.3 christos { "stda", F3(3, 0x37, 1), F3(~3, ~0x37, ~1), "H,[1+i]o", 0, 0, 0, v9 }, 715 1.3 christos { "stda", F3(3, 0x37, 1), F3(~3, ~0x37, ~1), "H,[i+1]o", 0, 0, 0, v9 }, 716 1.3 christos { "stda", F3(3, 0x37, 1), F3(~3, ~0x37, ~1)|RS1_G0, "H,[i]o", 0, 0, 0, v9 }, 717 1.3 christos { "stda", F3(3, 0x37, 1), F3(~3, ~0x37, ~1)|SIMM13(~0), "H,[1]o", 0, 0, 0, v9 }, /* std d,[rs1+0] */ 718 1.3 christos 719 1.3 christos { "sth", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|ASI(~0), "d,[1+2]", 0, 0, 0, v6 }, 720 1.3 christos { "sth", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|ASI_RS2(~0), "d,[1]", 0, 0, 0, v6 }, /* sth d,[rs1+%g0] */ 721 1.3 christos { "sth", F3(3, 0x06, 1), F3(~3, ~0x06, ~1), "d,[1+i]", 0, 0, 0, v6 }, 722 1.3 christos { "sth", F3(3, 0x06, 1), F3(~3, ~0x06, ~1), "d,[i+1]", 0, 0, 0, v6 }, 723 1.3 christos { "sth", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RS1_G0, "d,[i]", 0, 0, 0, v6 }, 724 1.3 christos { "sth", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|SIMM13(~0), "d,[1]", 0, 0, 0, v6 }, /* sth d,[rs1+0] */ 725 1.3 christos 726 1.3 christos { "stsh", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v6 }, 727 1.3 christos { "stsh", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* sth d,[rs1+%g0] */ 728 1.3 christos { "stsh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1), "d,[1+i]", F_ALIAS, 0, 0, v6 }, 729 1.3 christos { "stsh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1), "d,[i+1]", F_ALIAS, 0, 0, v6 }, 730 1.3 christos { "stsh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v6 }, 731 1.3 christos { "stsh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* sth d,[rs1+0] */ 732 1.3 christos { "stuh", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|ASI(~0), "d,[1+2]", F_ALIAS, 0, 0, v6 }, 733 1.3 christos { "stuh", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|ASI_RS2(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* sth d,[rs1+%g0] */ 734 1.3 christos { "stuh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1), "d,[1+i]", F_ALIAS, 0, 0, v6 }, 735 1.3 christos { "stuh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1), "d,[i+1]", F_ALIAS, 0, 0, v6 }, 736 1.3 christos { "stuh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RS1_G0, "d,[i]", F_ALIAS, 0, 0, v6 }, 737 1.3 christos { "stuh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|SIMM13(~0), "d,[1]", F_ALIAS, 0, 0, v6 }, /* sth d,[rs1+0] */ 738 1.3 christos 739 1.3 christos { "stha", F3(3, 0x16, 0), F3(~3, ~0x16, ~0), "d,[1+2]A", 0, 0, 0, v6 }, 740 1.3 christos { "stha", F3(3, 0x16, 0), F3(~3, ~0x16, ~0)|RS2(~0), "d,[1]A", 0, 0, 0, v6 }, /* stha ,[rs1+%g0] */ 741 1.3 christos { "stha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1), "d,[1+i]o", 0, 0, 0, v9 }, 742 1.3 christos { "stha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1), "d,[i+1]o", 0, 0, 0, v9 }, 743 1.3 christos { "stha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1)|RS1_G0, "d,[i]o", 0, 0, 0, v9 }, 744 1.3 christos { "stha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1)|SIMM13(~0), "d,[1]o", 0, 0, 0, v9 }, /* sth d,[rs1+0] */ 745 1.3 christos 746 1.3 christos { "stsha", F3(3, 0x16, 0), F3(~3, ~0x16, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v6 }, 747 1.3 christos { "stsha", F3(3, 0x16, 0), F3(~3, ~0x16, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v6 }, /* stha ,[rs1+%g0] */ 748 1.3 christos { "stsha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 749 1.3 christos { "stsha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 750 1.3 christos { "stsha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 751 1.3 christos { "stsha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* sth d,[rs1+0] */ 752 1.3 christos { "stuha", F3(3, 0x16, 0), F3(~3, ~0x16, ~0), "d,[1+2]A", F_ALIAS, 0, 0, v6 }, 753 1.3 christos { "stuha", F3(3, 0x16, 0), F3(~3, ~0x16, ~0)|RS2(~0), "d,[1]A", F_ALIAS, 0, 0, v6 }, /* stha ,[rs1+%g0] */ 754 1.3 christos { "stuha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1), "d,[1+i]o", F_ALIAS, 0, 0, v9 }, 755 1.3 christos { "stuha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1), "d,[i+1]o", F_ALIAS, 0, 0, v9 }, 756 1.3 christos { "stuha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1)|RS1_G0, "d,[i]o", F_ALIAS, 0, 0, v9 }, 757 1.3 christos { "stuha", F3(3, 0x16, 1), F3(~3, ~0x16, ~1)|SIMM13(~0), "d,[1]o", F_ALIAS, 0, 0, v9 }, /* sth d,[rs1+0] */ 758 1.3 christos 759 1.3 christos { "stx", F3(3, 0x0e, 0), F3(~3, ~0x0e, ~0)|ASI(~0), "d,[1+2]", 0, 0, 0, v9 }, 760 1.3 christos { "stx", F3(3, 0x0e, 0), F3(~3, ~0x0e, ~0)|ASI_RS2(~0), "d,[1]", 0, 0, 0, v9 }, /* stx d,[rs1+%g0] */ 761 1.3 christos { "stx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1), "d,[1+i]", 0, 0, 0, v9 }, 762 1.3 christos { "stx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1), "d,[i+1]", 0, 0, 0, v9 }, 763 1.3 christos { "stx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1)|RS1_G0, "d,[i]", 0, 0, 0, v9 }, 764 1.3 christos { "stx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1)|SIMM13(~0), "d,[1]", 0, 0, 0, v9 }, /* stx d,[rs1+0] */ 765 1.3 christos 766 1.3 christos { "stx", F3(3, 0x25, 0)|RD(1), F3(~3, ~0x25, ~0)|ASI(~0)|RD(~1), "F,[1+2]", 0, 0, 0, v9 }, 767 1.3 christos { "stx", F3(3, 0x25, 0)|RD(1), F3(~3, ~0x25, ~0)|ASI_RS2(~0)|RD(~1),"F,[1]", 0, 0, 0, v9 }, /* stx d,[rs1+%g0] */ 768 1.3 christos { "stx", F3(3, 0x25, 1)|RD(1), F3(~3, ~0x25, ~1)|RD(~1), "F,[1+i]", 0, 0, 0, v9 }, 769 1.3 christos { "stx", F3(3, 0x25, 1)|RD(1), F3(~3, ~0x25, ~1)|RD(~1), "F,[i+1]", 0, 0, 0, v9 }, 770 1.3 christos { "stx", F3(3, 0x25, 1)|RD(1), F3(~3, ~0x25, ~1)|RS1_G0|RD(~1), "F,[i]", 0, 0, 0, v9 }, 771 1.3 christos { "stx", F3(3, 0x25, 1)|RD(1), F3(~3, ~0x25, ~1)|SIMM13(~0)|RD(~1),"F,[1]", 0, 0, 0, v9 }, /* stx d,[rs1+0] */ 772 1.3 christos 773 1.3 christos { "stxa", F3(3, 0x1e, 0), F3(~3, ~0x1e, ~0), "d,[1+2]A", 0, 0, 0, v9 }, 774 1.3 christos { "stxa", F3(3, 0x1e, 0), F3(~3, ~0x1e, ~0)|RS2(~0), "d,[1]A", 0, 0, 0, v9 }, /* stxa d,[rs1+%g0] */ 775 1.3 christos { "stxa", F3(3, 0x1e, 1), F3(~3, ~0x1e, ~1), "d,[1+i]o", 0, 0, 0, v9 }, 776 1.3 christos { "stxa", F3(3, 0x1e, 1), F3(~3, ~0x1e, ~1), "d,[i+1]o", 0, 0, 0, v9 }, 777 1.3 christos { "stxa", F3(3, 0x1e, 1), F3(~3, ~0x1e, ~1)|RS1_G0, "d,[i]o", 0, 0, 0, v9 }, 778 1.3 christos { "stxa", F3(3, 0x1e, 1), F3(~3, ~0x1e, ~1)|SIMM13(~0), "d,[1]o", 0, 0, 0, v9 }, /* stx d,[rs1+0] */ 779 1.3 christos 780 1.3 christos { "stq", F3(3, 0x26, 0), F3(~3, ~0x26, ~0)|ASI(~0), "J,[1+2]", 0, 0, 0, v9 }, 781 1.3 christos { "stq", F3(3, 0x26, 0), F3(~3, ~0x26, ~0)|ASI_RS2(~0), "J,[1]", 0, 0, 0, v9 }, /* stq [rs1+%g0] */ 782 1.3 christos { "stq", F3(3, 0x26, 1), F3(~3, ~0x26, ~1), "J,[1+i]", 0, 0, 0, v9 }, 783 1.3 christos { "stq", F3(3, 0x26, 1), F3(~3, ~0x26, ~1), "J,[i+1]", 0, 0, 0, v9 }, 784 1.3 christos { "stq", F3(3, 0x26, 1), F3(~3, ~0x26, ~1)|RS1_G0, "J,[i]", 0, 0, 0, v9 }, 785 1.3 christos { "stq", F3(3, 0x26, 1), F3(~3, ~0x26, ~1)|SIMM13(~0), "J,[1]", 0, 0, 0, v9 }, /* stq [rs1+0] */ 786 1.3 christos 787 1.3 christos { "stqa", F3(3, 0x36, 0), F3(~3, ~0x36, ~0)|ASI(~0), "J,[1+2]A", 0, 0, 0, v9 }, 788 1.3 christos { "stqa", F3(3, 0x36, 0), F3(~3, ~0x36, ~0)|ASI_RS2(~0), "J,[1]A", 0, 0, 0, v9 }, /* stqa [rs1+%g0] */ 789 1.3 christos { "stqa", F3(3, 0x36, 1), F3(~3, ~0x36, ~1), "J,[1+i]o", 0, 0, 0, v9 }, 790 1.3 christos { "stqa", F3(3, 0x36, 1), F3(~3, ~0x36, ~1), "J,[i+1]o", 0, 0, 0, v9 }, 791 1.3 christos { "stqa", F3(3, 0x36, 1), F3(~3, ~0x36, ~1)|RS1_G0, "J,[i]o", 0, 0, 0, v9 }, 792 1.3 christos { "stqa", F3(3, 0x36, 1), F3(~3, ~0x36, ~1)|SIMM13(~0), "J,[1]o", 0, 0, 0, v9 }, /* stqa [rs1+0] */ 793 1.3 christos 794 1.3 christos { "swap", F3(3, 0x0f, 0), F3(~3, ~0x0f, ~0)|ASI(~0), "[1+2],d", 0, 0, 0, v7 }, 795 1.3 christos { "swap", F3(3, 0x0f, 0), F3(~3, ~0x0f, ~0)|ASI_RS2(~0), "[1],d", 0, 0, 0, v7 }, /* swap [rs1+%g0],d */ 796 1.3 christos { "swap", F3(3, 0x0f, 1), F3(~3, ~0x0f, ~1), "[1+i],d", 0, 0, 0, v7 }, 797 1.3 christos { "swap", F3(3, 0x0f, 1), F3(~3, ~0x0f, ~1), "[i+1],d", 0, 0, 0, v7 }, 798 1.3 christos { "swap", F3(3, 0x0f, 1), F3(~3, ~0x0f, ~1)|RS1_G0, "[i],d", 0, 0, 0, v7 }, 799 1.3 christos { "swap", F3(3, 0x0f, 1), F3(~3, ~0x0f, ~1)|SIMM13(~0), "[1],d", 0, 0, 0, v7 }, /* swap [rs1+0],d */ 800 1.3 christos 801 1.3 christos { "swapa", F3(3, 0x1f, 0), F3(~3, ~0x1f, ~0), "[1+2]A,d", 0, 0, 0, v7 }, 802 1.3 christos { "swapa", F3(3, 0x1f, 0), F3(~3, ~0x1f, ~0)|RS2(~0), "[1]A,d", 0, 0, 0, v7 }, /* swapa [rs1+%g0],d */ 803 1.3 christos { "swapa", F3(3, 0x1f, 1), F3(~3, ~0x1f, ~1), "[1+i]o,d", 0, 0, 0, v9 }, 804 1.3 christos { "swapa", F3(3, 0x1f, 1), F3(~3, ~0x1f, ~1), "[i+1]o,d", 0, 0, 0, v9 }, 805 1.3 christos { "swapa", F3(3, 0x1f, 1), F3(~3, ~0x1f, ~1)|RS1_G0, "[i]o,d", 0, 0, 0, v9 }, 806 1.3 christos { "swapa", F3(3, 0x1f, 1), F3(~3, ~0x1f, ~1)|SIMM13(~0), "[1]o,d", 0, 0, 0, v9 }, /* swap [rs1+0],d */ 807 1.3 christos 808 1.3 christos { "restore", F3(2, 0x3d, 0), F3(~2, ~0x3d, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 809 1.3 christos { "restore", F3(2, 0x3d, 0), F3(~2, ~0x3d, ~0)|RD_G0|RS1_G0|ASI_RS2(~0), "", 0, 0, 0, v6 }, /* restore %g0,%g0,%g0 */ 810 1.3 christos { "restore", F3(2, 0x3d, 1), F3(~2, ~0x3d, ~1), "1,i,d", 0, 0, 0, v6 }, 811 1.8 christos { "restore", F3(2, 0x3d, 1), F3(~2, ~0x3d, ~1)|RD_G0|RS1_G0|SIMM13(~0), "", 0, 0, 0, v6 }, /* restore %g0,0,%g0 */ 812 1.8 christos 813 1.8 christos { "rett", F3(2, 0x39, 0), F3(~2, ~0x39, ~0)|RD_G0|ASI(~0), "1+2", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett rs1+rs2 */ 814 1.8 christos { "rett", F3(2, 0x39, 0), F3(~2, ~0x39, ~0)|RD_G0|ASI_RS2(~0), "1", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett rs1,%g0 */ 815 1.8 christos { "rett", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|RD_G0, "1+i", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett rs1+X */ 816 1.8 christos { "rett", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|RD_G0, "i+1", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett X+rs1 */ 817 1.8 christos { "rett", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|RD_G0|RS1_G0, "i", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett X+rs1 */ 818 1.3 christos { "rett", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|RD_G0|RS1_G0, "i", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett X */ 819 1.3 christos { "rett", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|RD_G0|SIMM13(~0), "1", F_UNBR|F_DELAYED, 0, 0, v6notv9 }, /* rett rs1+0 */ 820 1.3 christos 821 1.3 christos { "save", F3(2, 0x3c, 0), F3(~2, ~0x3c, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 822 1.3 christos { "save", F3(2, 0x3c, 1), F3(~2, ~0x3c, ~1), "1,i,d", 0, 0, 0, v6 }, 823 1.3 christos { "save", F3(2, 0x3c, 1), F3(~2, ~0x3c, ~1), "i,1,d", 0, 0, 0, v6 }, /* Sun assembler compatibility */ 824 1.3 christos { "save", 0x81e00000, ~0x81e00000, "", F_ALIAS, 0, 0, v6 }, 825 1.3 christos 826 1.3 christos { "ret", F3(2, 0x38, 1)|RS1(0x1f)|SIMM13(8), F3(~2, ~0x38, ~1)|SIMM13(~8), "", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl %i7+8,%g0 */ 827 1.3 christos { "retl", F3(2, 0x38, 1)|RS1(0x0f)|SIMM13(8), F3(~2, ~0x38, ~1)|RS1(~0x0f)|SIMM13(~8), "", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl %o7+8,%g0 */ 828 1.3 christos 829 1.3 christos { "jmpl", F3(2, 0x38, 0), F3(~2, ~0x38, ~0)|ASI(~0), "1+2,d", F_JSR|F_DELAYED, 0, 0, v6 }, 830 1.3 christos { "jmpl", F3(2, 0x38, 0), F3(~2, ~0x38, ~0)|ASI_RS2(~0), "1,d", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+%g0,d */ 831 1.3 christos { "jmpl", F3(2, 0x38, 1), F3(~2, ~0x38, ~1)|SIMM13(~0), "1,d", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+0,d */ 832 1.3 christos { "jmpl", F3(2, 0x38, 1), F3(~2, ~0x38, ~1)|RS1_G0, "i,d", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl %g0+i,d */ 833 1.3 christos { "jmpl", F3(2, 0x38, 1), F3(~2, ~0x38, ~1), "1+i,d", F_JSR|F_DELAYED, 0, 0, v6 }, 834 1.3 christos { "jmpl", F3(2, 0x38, 1), F3(~2, ~0x38, ~1), "i+1,d", F_JSR|F_DELAYED, 0, 0, v6 }, 835 1.3 christos 836 1.3 christos { "done", F3(2, 0x3e, 0)|RD(0), F3(~2, ~0x3e, ~0)|RD(~0)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 837 1.3 christos { "retry", F3(2, 0x3e, 0)|RD(1), F3(~2, ~0x3e, ~0)|RD(~1)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 838 1.3 christos { "saved", F3(2, 0x31, 0)|RD(0), F3(~2, ~0x31, ~0)|RD(~0)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 839 1.3 christos { "restored", F3(2, 0x31, 0)|RD(1), F3(~2, ~0x31, ~0)|RD(~1)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 840 1.3 christos { "allclean", F3(2, 0x31, 0)|RD(2), F3(~2, ~0x31, ~0)|RD(~2)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 841 1.3 christos { "otherw", F3(2, 0x31, 0)|RD(3), F3(~2, ~0x31, ~0)|RD(~3)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 842 1.3 christos { "normalw", F3(2, 0x31, 0)|RD(4), F3(~2, ~0x31, ~0)|RD(~4)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 843 1.3 christos { "invalw", F3(2, 0x31, 0)|RD(5), F3(~2, ~0x31, ~0)|RD(~5)|RS1_G0|SIMM13(~0), "", 0, 0, 0, v9 }, 844 1.3 christos { "sir", F3(2, 0x30, 1)|RD(0xf), F3(~2, ~0x30, ~1)|RD(~0xf)|RS1_G0, "i", 0, 0, 0, v9 }, 845 1.3 christos 846 1.3 christos { "flush", F3(2, 0x3b, 0), F3(~2, ~0x3b, ~0)|ASI(~0), "[1+2]", 0, 0, 0, v9 }, 847 1.3 christos { "flush", F3(2, 0x3b, 0), F3(~2, ~0x3b, ~0)|ASI_RS2(~0), "[1]", 0, 0, 0, v9 }, /* flush rs1+%g0 */ 848 1.3 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1)|SIMM13(~0), "[1]", 0, 0, 0, v9 }, /* flush rs1+0 */ 849 1.3 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1)|RS1_G0, "[i]", 0, 0, 0, v9 }, /* flush %g0+i */ 850 1.3 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1), "[1+i]", 0, 0, 0, v9 }, 851 1.3 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1), "[i+1]", 0, 0, 0, v9 }, 852 1.3 christos 853 1.3 christos { "flush", F3(2, 0x3b, 0), F3(~2, ~0x3b, ~0)|ASI(~0), "1+2", F_ALIAS, 0, 0, v8 }, 854 1.3 christos { "flush", F3(2, 0x3b, 0), F3(~2, ~0x3b, ~0)|ASI_RS2(~0), "1", F_ALIAS, 0, 0, v8 }, /* flush rs1+%g0 */ 855 1.3 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1)|SIMM13(~0), "1", F_ALIAS, 0, 0, v8 }, /* flush rs1+0 */ 856 1.3 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1)|RS1_G0, "i", F_ALIAS, 0, 0, v8 }, /* flush %g0+i */ 857 1.1 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1), "1+i", F_ALIAS, 0, 0, v8 }, 858 1.1 christos { "flush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1), "i+1", F_ALIAS, 0, 0, v8 }, 859 1.3 christos 860 1.3 christos /* IFLUSH was renamed to FLUSH in v8. */ 861 1.3 christos { "iflush", F3(2, 0x3b, 0), F3(~2, ~0x3b, ~0)|ASI(~0), "1+2", F_ALIAS, 0, 0, v6 }, 862 1.3 christos { "iflush", F3(2, 0x3b, 0), F3(~2, ~0x3b, ~0)|ASI_RS2(~0), "1", F_ALIAS, 0, 0, v6 }, /* flush rs1+%g0 */ 863 1.3 christos { "iflush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1)|SIMM13(~0), "1", F_ALIAS, 0, 0, v6 }, /* flush rs1+0 */ 864 1.3 christos { "iflush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1)|RS1_G0, "i", F_ALIAS, 0, 0, v6 }, 865 1.3 christos { "iflush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1), "1+i", F_ALIAS, 0, 0, v6 }, 866 1.3 christos { "iflush", F3(2, 0x3b, 1), F3(~2, ~0x3b, ~1), "i+1", F_ALIAS, 0, 0, v6 }, 867 1.3 christos 868 1.3 christos { "return", F3(2, 0x39, 0), F3(~2, ~0x39, ~0)|ASI(~0), "1+2", 0, 0, 0, v9 }, 869 1.3 christos { "return", F3(2, 0x39, 0), F3(~2, ~0x39, ~0)|ASI_RS2(~0), "1", 0, 0, 0, v9 }, /* return rs1+%g0 */ 870 1.3 christos { "return", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|SIMM13(~0), "1", 0, 0, 0, v9 }, /* return rs1+0 */ 871 1.3 christos { "return", F3(2, 0x39, 1), F3(~2, ~0x39, ~1)|RS1_G0, "i", 0, 0, 0, v9 }, /* return %g0+i */ 872 1.3 christos { "return", F3(2, 0x39, 1), F3(~2, ~0x39, ~1), "1+i", 0, 0, 0, v9 }, 873 1.3 christos { "return", F3(2, 0x39, 1), F3(~2, ~0x39, ~1), "i+1", 0, 0, 0, v9 }, 874 1.3 christos 875 1.3 christos { "flushw", F3(2, 0x2b, 0), F3(~2, ~0x2b, ~0)|RD_G0|RS1_G0|ASI_RS2(~0), "", 0, 0, 0, v9 }, 876 1.3 christos 877 1.3 christos { "membar", F3(2, 0x28, 1)|RS1(0xf), F3(~2, ~0x28, ~1)|RD_G0|RS1(~0xf)|SIMM13(~127), "K", 0, 0, 0, v9 }, 878 1.3 christos { "stbar", F3(2, 0x28, 0)|RS1(0xf), F3(~2, ~0x28, ~0)|RD_G0|RS1(~0xf)|SIMM13(~0), "", 0, 0, 0, v8 }, 879 1.3 christos 880 1.3 christos { "prefetch", F3(3, 0x2d, 0), F3(~3, ~0x2d, ~0), "[1+2],*", 0, 0, 0, v9 }, 881 1.3 christos { "prefetch", F3(3, 0x2d, 0), F3(~3, ~0x2d, ~0)|RS2_G0, "[1],*", 0, 0, 0, v9 }, /* prefetch [rs1+%g0],prefetch_fcn */ 882 1.3 christos { "prefetch", F3(3, 0x2d, 1), F3(~3, ~0x2d, ~1), "[1+i],*", 0, 0, 0, v9 }, 883 1.3 christos { "prefetch", F3(3, 0x2d, 1), F3(~3, ~0x2d, ~1), "[i+1],*", 0, 0, 0, v9 }, 884 1.3 christos { "prefetch", F3(3, 0x2d, 1), F3(~3, ~0x2d, ~1)|RS1_G0, "[i],*", 0, 0, 0, v9 }, 885 1.3 christos { "prefetch", F3(3, 0x2d, 1), F3(~3, ~0x2d, ~1)|SIMM13(~0), "[1],*", 0, 0, 0, v9 }, /* prefetch [rs1+0],prefetch_fcn */ 886 1.3 christos { "prefetcha", F3(3, 0x3d, 0), F3(~3, ~0x3d, ~0), "[1+2]A,*", 0, 0, 0, v9 }, 887 1.3 christos { "prefetcha", F3(3, 0x3d, 0), F3(~3, ~0x3d, ~0)|RS2_G0, "[1]A,*", 0, 0, 0, v9 }, /* prefetcha [rs1+%g0],prefetch_fcn */ 888 1.3 christos { "prefetcha", F3(3, 0x3d, 1), F3(~3, ~0x3d, ~1), "[1+i]o,*", 0, 0, 0, v9 }, 889 1.3 christos { "prefetcha", F3(3, 0x3d, 1), F3(~3, ~0x3d, ~1), "[i+1]o,*", 0, 0, 0, v9 }, 890 1.3 christos { "prefetcha", F3(3, 0x3d, 1), F3(~3, ~0x3d, ~1)|RS1_G0, "[i]o,*", 0, 0, 0, v9 }, 891 1.3 christos { "prefetcha", F3(3, 0x3d, 1), F3(~3, ~0x3d, ~1)|SIMM13(~0), "[1]o,*", 0, 0, 0, v9 }, /* prefetcha [rs1+0],d */ 892 1.3 christos 893 1.3 christos { "sll", F3(2, 0x25, 0), F3(~2, ~0x25, ~0)|(1<<12)|(0x7f<<5), "1,2,d", 0, 0, 0, v6 }, 894 1.3 christos { "sll", F3(2, 0x25, 1), F3(~2, ~0x25, ~1)|(1<<12)|(0x7f<<5), "1,X,d", 0, 0, 0, v6 }, 895 1.3 christos { "sra", F3(2, 0x27, 0), F3(~2, ~0x27, ~0)|(1<<12)|(0x7f<<5), "1,2,d", 0, 0, 0, v6 }, 896 1.3 christos { "sra", F3(2, 0x27, 1), F3(~2, ~0x27, ~1)|(1<<12)|(0x7f<<5), "1,X,d", 0, 0, 0, v6 }, 897 1.3 christos { "srl", F3(2, 0x26, 0), F3(~2, ~0x26, ~0)|(1<<12)|(0x7f<<5), "1,2,d", 0, 0, 0, v6 }, 898 1.3 christos { "srl", F3(2, 0x26, 1), F3(~2, ~0x26, ~1)|(1<<12)|(0x7f<<5), "1,X,d", 0, 0, 0, v6 }, 899 1.3 christos 900 1.3 christos { "sllx", F3(2, 0x25, 0)|(1<<12), F3(~2, ~0x25, ~0)|(0x7f<<5), "1,2,d", 0, 0, 0, v9 }, 901 1.3 christos { "sllx", F3(2, 0x25, 1)|(1<<12), F3(~2, ~0x25, ~1)|(0x3f<<6), "1,Y,d", 0, 0, 0, v9 }, 902 1.3 christos { "srax", F3(2, 0x27, 0)|(1<<12), F3(~2, ~0x27, ~0)|(0x7f<<5), "1,2,d", 0, 0, 0, v9 }, 903 1.3 christos { "srax", F3(2, 0x27, 1)|(1<<12), F3(~2, ~0x27, ~1)|(0x3f<<6), "1,Y,d", 0, 0, 0, v9 }, 904 1.3 christos { "srlx", F3(2, 0x26, 0)|(1<<12), F3(~2, ~0x26, ~0)|(0x7f<<5), "1,2,d", 0, 0, 0, v9 }, 905 1.3 christos { "srlx", F3(2, 0x26, 1)|(1<<12), F3(~2, ~0x26, ~1)|(0x3f<<6), "1,Y,d", 0, 0, 0, v9 }, 906 1.3 christos 907 1.3 christos { "mulscc", F3(2, 0x24, 0), F3(~2, ~0x24, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 908 1.3 christos { "mulscc", F3(2, 0x24, 1), F3(~2, ~0x24, ~1), "1,i,d", 0, 0, 0, v6 }, 909 1.3 christos 910 1.3 christos { "divscc", F3(2, 0x1d, 0), F3(~2, ~0x1d, ~0)|ASI(~0), "1,2,d", 0, 0, 0, sparclite }, 911 1.3 christos { "divscc", F3(2, 0x1d, 1), F3(~2, ~0x1d, ~1), "1,i,d", 0, 0, 0, sparclite }, 912 1.3 christos 913 1.3 christos { "scan", F3(2, 0x2c, 0), F3(~2, ~0x2c, ~0)|ASI(~0), "1,2,d", 0, 0, 0, sparclet|sparclite }, 914 1.3 christos { "scan", F3(2, 0x2c, 1), F3(~2, ~0x2c, ~1), "1,i,d", 0, 0, 0, sparclet|sparclite }, 915 1.3 christos 916 1.3 christos { "popc", F3(2, 0x2e, 0), F3(~2, ~0x2e, ~0)|RS1_G0|ASI(~0),"2,d", 0, HWCAP_POPC, 0, v9 }, 917 1.3 christos { "popc", F3(2, 0x2e, 1), F3(~2, ~0x2e, ~1)|RS1_G0, "i,d", 0, HWCAP_POPC, 0, v9 }, 918 1.3 christos 919 1.3 christos { "clr", F3(2, 0x02, 0), F3(~2, ~0x02, ~0)|RD_G0|RS1_G0|ASI_RS2(~0), "d", F_ALIAS, 0, 0, v6 }, /* or %g0,%g0,d */ 920 1.3 christos { "clr", F3(2, 0x02, 1), F3(~2, ~0x02, ~1)|RS1_G0|SIMM13(~0), "d", F_ALIAS, 0, 0, v6 }, /* or %g0,0,d */ 921 1.3 christos { "clr", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|RD_G0|ASI(~0), "[1+2]", F_ALIAS, 0, 0, v6 }, 922 1.3 christos { "clr", F3(3, 0x04, 0), F3(~3, ~0x04, ~0)|RD_G0|ASI_RS2(~0), "[1]", F_ALIAS, 0, 0, v6 }, /* st %g0,[rs1+%g0] */ 923 1.3 christos { "clr", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RD_G0, "[1+i]", F_ALIAS, 0, 0, v6 }, 924 1.3 christos { "clr", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RD_G0, "[i+1]", F_ALIAS, 0, 0, v6 }, 925 1.3 christos { "clr", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RD_G0|RS1_G0, "[i]", F_ALIAS, 0, 0, v6 }, 926 1.3 christos { "clr", F3(3, 0x04, 1), F3(~3, ~0x04, ~1)|RD_G0|SIMM13(~0), "[1]", F_ALIAS, 0, 0, v6 }, /* st %g0,[rs1+0] */ 927 1.3 christos 928 1.3 christos { "clrb", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|RD_G0|ASI(~0), "[1+2]", F_ALIAS, 0, 0, v6 }, 929 1.3 christos { "clrb", F3(3, 0x05, 0), F3(~3, ~0x05, ~0)|RD_G0|ASI_RS2(~0), "[1]", F_ALIAS, 0, 0, v6 }, /* stb %g0,[rs1+%g0] */ 930 1.3 christos { "clrb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RD_G0, "[1+i]", F_ALIAS, 0, 0, v6 }, 931 1.3 christos { "clrb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RD_G0, "[i+1]", F_ALIAS, 0, 0, v6 }, 932 1.3 christos { "clrb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RD_G0|RS1_G0, "[i]", F_ALIAS, 0, 0, v6 }, 933 1.3 christos { "clrb", F3(3, 0x05, 1), F3(~3, ~0x05, ~1)|RD_G0|SIMM13(~0), "[1]", F_ALIAS, 0, 0, v6 }, /* stb %g0,[rs1+0] */ 934 1.3 christos 935 1.3 christos { "clrh", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|RD_G0|ASI(~0), "[1+2]", F_ALIAS, 0, 0, v6 }, 936 1.3 christos { "clrh", F3(3, 0x06, 0), F3(~3, ~0x06, ~0)|RD_G0|ASI_RS2(~0), "[1]", F_ALIAS, 0, 0, v6 }, /* sth %g0,[rs1+%g0] */ 937 1.3 christos { "clrh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RD_G0, "[1+i]", F_ALIAS, 0, 0, v6 }, 938 1.3 christos { "clrh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RD_G0, "[i+1]", F_ALIAS, 0, 0, v6 }, 939 1.3 christos { "clrh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RD_G0|RS1_G0, "[i]", F_ALIAS, 0, 0, v6 }, 940 1.3 christos { "clrh", F3(3, 0x06, 1), F3(~3, ~0x06, ~1)|RD_G0|SIMM13(~0), "[1]", F_ALIAS, 0, 0, v6 }, /* sth %g0,[rs1+0] */ 941 1.3 christos 942 1.3 christos { "clrx", F3(3, 0x0e, 0), F3(~3, ~0x0e, ~0)|RD_G0|ASI(~0), "[1+2]", F_ALIAS, 0, 0, v9 }, 943 1.3 christos { "clrx", F3(3, 0x0e, 0), F3(~3, ~0x0e, ~0)|RD_G0|ASI_RS2(~0), "[1]", F_ALIAS, 0, 0, v9 }, /* stx %g0,[rs1+%g0] */ 944 1.3 christos { "clrx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1)|RD_G0, "[1+i]", F_ALIAS, 0, 0, v9 }, 945 1.3 christos { "clrx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1)|RD_G0, "[i+1]", F_ALIAS, 0, 0, v9 }, 946 1.3 christos { "clrx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1)|RD_G0|RS1_G0, "[i]", F_ALIAS, 0, 0, v9 }, 947 1.3 christos { "clrx", F3(3, 0x0e, 1), F3(~3, ~0x0e, ~1)|RD_G0|SIMM13(~0), "[1]", F_ALIAS, 0, 0, v9 }, /* stx %g0,[rs1+0] */ 948 1.3 christos 949 1.3 christos { "orcc", F3(2, 0x12, 0), F3(~2, ~0x12, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 950 1.1 christos { "orcc", F3(2, 0x12, 1), F3(~2, ~0x12, ~1), "1,i,d", 0, 0, 0, v6 }, 951 1.1 christos { "orcc", F3(2, 0x12, 1), F3(~2, ~0x12, ~1), "i,1,d", 0, 0, 0, v6 }, 952 1.3 christos 953 1.3 christos /* This is not a commutative instruction. */ 954 1.1 christos { "orncc", F3(2, 0x16, 0), F3(~2, ~0x16, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 955 1.1 christos { "orncc", F3(2, 0x16, 1), F3(~2, ~0x16, ~1), "1,i,d", 0, 0, 0, v6 }, 956 1.3 christos 957 1.3 christos /* This is not a commutative instruction. */ 958 1.1 christos { "orn", F3(2, 0x06, 0), F3(~2, ~0x06, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 959 1.3 christos { "orn", F3(2, 0x06, 1), F3(~2, ~0x06, ~1), "1,i,d", 0, 0, 0, v6 }, 960 1.3 christos 961 1.3 christos { "tst", F3(2, 0x12, 0), F3(~2, ~0x12, ~0)|RD_G0|ASI_RS2(~0), "1", 0, 0, 0, v6 }, /* orcc rs1, %g0, %g0 */ 962 1.3 christos { "tst", F3(2, 0x12, 0), F3(~2, ~0x12, ~0)|RD_G0|RS1_G0|ASI(~0), "2", 0, 0, 0, v6 }, /* orcc %g0, rs2, %g0 */ 963 1.3 christos { "tst", F3(2, 0x12, 1), F3(~2, ~0x12, ~1)|RD_G0|SIMM13(~0), "1", 0, 0, 0, v6 }, /* orcc rs1, 0, %g0 */ 964 1.3 christos 965 1.3 christos 966 1.3 christos { "wr", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|ASI(~0), "1,2,m", 0, 0, 0, v8 }, /* wr r,r,%asrX */ 967 1.3 christos { "wr", F3(2, 0x30, 1), F3(~2, ~0x30, ~1), "1,i,m", 0, 0, 0, v8 }, /* wr r,i,%asrX */ 968 1.3 christos { "wr", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|RS1_G0|ASI(~0), "2,m", F_PREF_ALIAS, 0, 0, v8 }, /* wr %g0,rs2,%asrX */ 969 1.3 christos { "wr", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|RS1_G0, "i,m", F_PREF_ALIAS, 0, 0, v8 }, /* wr %g0,i,%asrX */ 970 1.3 christos { "wr", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|SIMM13(~0), "1,m", F_PREF_ALIAS, 0, 0, v8 }, /* wr rs1,%asrX */ 971 1.3 christos { "wr", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|ASI_RS2(~0), "1,m", F_PREF_ALIAS, 0, 0, v8 }, /* wr rs1,%g0,%asrX */ 972 1.3 christos { "wr", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|RD_G0|ASI(~0), "1,2,y", 0, 0, 0, v6 }, /* wr r,r,%y */ 973 1.3 christos { "wr", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|RD_G0, "1,i,y", 0, 0, 0, v6 }, /* wr r,i,%y */ 974 1.3 christos { "wr", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|RD_G0|RS1_G0|ASI(~0), "2,y", F_PREF_ALIAS, 0, 0, v6 }, /* wr %g0,rs2,%y */ 975 1.3 christos { "wr", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|RD_G0|RS1_G0, "i,y", F_PREF_ALIAS, 0, 0, v6 }, /* wr %g0,i,%y */ 976 1.3 christos { "wr", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|RD_G0|SIMM13(~0), "1,y", F_PREF_ALIAS, 0, 0, v6 }, /* wr rs1,0,%y */ 977 1.3 christos { "wr", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|RD_G0|ASI_RS2(~0), "1,y", F_PREF_ALIAS, 0, 0, v6 }, /* wr rs1,%g0,%y */ 978 1.3 christos { "wr", F3(2, 0x31, 0), F3(~2, ~0x31, ~0)|RD_G0|ASI(~0), "1,2,p", 0, 0, 0, v6notv9 }, /* wr r,r,%psr */ 979 1.3 christos { "wr", F3(2, 0x31, 1), F3(~2, ~0x31, ~1)|RD_G0, "1,i,p", 0, 0, 0, v6notv9 }, /* wr r,i,%psr */ 980 1.3 christos { "wr", F3(2, 0x31, 0), F3(~2, ~0x31, ~0)|RD_G0|RS1_G0|ASI(~0), "2,p", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr %g0,rs2,%psr */ 981 1.3 christos { "wr", F3(2, 0x31, 1), F3(~2, ~0x31, ~1)|RD_G0|RS1_G0, "i,p", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr %g0,i,%psr */ 982 1.3 christos { "wr", F3(2, 0x31, 1), F3(~2, ~0x31, ~1)|RD_G0|SIMM13(~0), "1,p", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr rs1,0,%psr */ 983 1.3 christos { "wr", F3(2, 0x31, 0), F3(~2, ~0x31, ~0)|RD_G0|ASI_RS2(~0), "1,p", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr rs1,%g0,%psr */ 984 1.3 christos { "wr", F3(2, 0x32, 0), F3(~2, ~0x32, ~0)|RD_G0|ASI(~0), "1,2,w", 0, 0, 0, v6notv9 }, /* wr r,r,%wim */ 985 1.3 christos { "wr", F3(2, 0x32, 1), F3(~2, ~0x32, ~1)|RD_G0, "1,i,w", 0, 0, 0, v6notv9 }, /* wr r,i,%wim */ 986 1.3 christos { "wr", F3(2, 0x32, 0), F3(~2, ~0x32, ~0)|RD_G0|RS1_G0|ASI(~0), "2,w", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr %g0,rs2,%wim */ 987 1.3 christos { "wr", F3(2, 0x32, 1), F3(~2, ~0x32, ~1)|RD_G0|RS1_G0, "i,w", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr %g0,i,%wim */ 988 1.3 christos { "wr", F3(2, 0x32, 1), F3(~2, ~0x32, ~1)|RD_G0|SIMM13(~0), "1,w", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr rs1,0,%wim */ 989 1.3 christos { "wr", F3(2, 0x32, 0), F3(~2, ~0x32, ~0)|RD_G0|ASI_RS2(~0), "1,w", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr rs1,%g0,%wim */ 990 1.3 christos { "wr", F3(2, 0x33, 0), F3(~2, ~0x33, ~0)|RD_G0|ASI(~0), "1,2,t", 0, 0, 0, v6notv9 }, /* wr r,r,%tbr */ 991 1.3 christos { "wr", F3(2, 0x33, 1), F3(~2, ~0x33, ~1)|RD_G0, "1,i,t", 0, 0, 0, v6notv9 }, /* wr r,i,%tbr */ 992 1.3 christos { "wr", F3(2, 0x33, 0), F3(~2, ~0x33, ~0)|RD_G0|RS1_G0|ASI(~0), "2,t", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr %g0,rs2,%tbr */ 993 1.3 christos { "wr", F3(2, 0x33, 1), F3(~2, ~0x33, ~1)|RD_G0|RS1_G0, "i,t", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr %g0,i,%tbr */ 994 1.3 christos { "wr", F3(2, 0x33, 1), F3(~2, ~0x33, ~1)|RD_G0|SIMM13(~0), "1,t", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr rs1,0,%tbr */ 995 1.3 christos { "wr", F3(2, 0x33, 0), F3(~2, ~0x33, ~0)|RD_G0|ASI_RS2(~0), "1,t", F_PREF_ALIAS, 0, 0, v6notv9 }, /* wr rs1,%g0,%tbr */ 996 1.3 christos 997 1.3 christos { "wr", F3(2, 0x30, 0)|RD(2), F3(~2, ~0x30, ~0)|RD(~2)|ASI(~0), "1,2,E", 0, 0, 0, v9 }, /* wr r,r,%ccr */ 998 1.3 christos { "wr", F3(2, 0x30, 1)|RD(2), F3(~2, ~0x30, ~1)|RD(~2), "1,i,E", 0, 0, 0, v9 }, /* wr r,i,%ccr */ 999 1.3 christos { "wr", F3(2, 0x30, 0)|RD(3), F3(~2, ~0x30, ~0)|RD(~3)|ASI(~0), "1,2,o", 0, 0, 0, v9 }, /* wr r,r,%asi */ 1000 1.3 christos { "wr", F3(2, 0x30, 1)|RD(3), F3(~2, ~0x30, ~1)|RD(~3), "1,i,o", 0, 0, 0, v9 }, /* wr r,i,%asi */ 1001 1.6 christos { "wr", F3(2, 0x30, 0)|RD(6), F3(~2, ~0x30, ~0)|RD(~6)|ASI(~0), "1,2,s", 0, 0, 0, v9 }, /* wr r,r,%fprs */ 1002 1.6 christos { "wr", F3(2, 0x30, 1)|RD(6), F3(~2, ~0x30, ~1)|RD(~6), "1,i,s", 0, 0, 0, v9 }, /* wr r,i,%fprs */ 1003 1.3 christos { "wr", F3(2, 0x30, 0)|RD(14), F3(~2, ~0x30, ~0)|RD(~14), "1,2,{", 0, 0, HWCAP2_SPARC5, v9m }, /* wr r,r,%mcdper */ 1004 1.6 christos { "wr", F3(2, 0x30, 1)|RD(14), F3(~2, ~0x30, ~1)|RD(~14), "1,i,{", 0, 0, HWCAP2_SPARC5, v9m }, /* wr r,i,%mcdper */ 1005 1.6 christos 1006 1.6 christos /* Write to ASR registers 16..31, which is the range defined in SPARC 1007 1.6 christos V9 for implementation-dependent uses. Note that the read-only ASR 1008 1.6 christos registers can't be used in a `wr' instruction. */ 1009 1.6 christos 1010 1.6 christos #define wrasr(asr,hwcap,hwcap2,arch) \ 1011 1.6 christos { "wr", F3(2, 0x30, 0)|RD((asr)), F3(~2, ~0x30, ~0)|RD(~(asr))|ASI(~0), "1,2,_", 0, (hwcap), (hwcap2), (arch) }, /* wr r,r,%asr */ \ 1012 1.6 christos { "wr", F3(2, 0x30, 1)|RD((asr)), F3(~2, ~0x30, ~1)|RD(~(asr)), "1,i,_", 0, (hwcap), (hwcap2), (arch) }, /* wr r,i,%asr */ \ 1013 1.6 christos { "wr", F3(2, 0x30, 1)|RD((asr)), F3(~2, ~0x30, ~1)|RD(~(asr)), "i,1,_", F_ALIAS, (hwcap), (hwcap2), (arch) } /* wr i,r,%asr */ 1014 1.6 christos 1015 1.6 christos wrasr (16, HWCAP_VIS, 0, v9a), /* wr ...,%pcr */ 1016 1.6 christos wrasr (17, HWCAP_VIS, 0, v9a), /* wr ...,%pic */ 1017 1.6 christos wrasr (18, HWCAP_VIS, 0, v9a), /* wr ...,%dcr */ 1018 1.6 christos wrasr (19, HWCAP_VIS, 0, v9a), /* wr ...,%gsr */ 1019 1.6 christos wrasr (20, HWCAP_VIS, 0, v9a), /* wr ...,%softint_set */ 1020 1.6 christos wrasr (21, HWCAP_VIS, 0, v9a), /* wr ...,%softint_clear */ 1021 1.6 christos wrasr (22, HWCAP_VIS, 0, v9a), /* wr ...,%softint */ 1022 1.6 christos wrasr (23, HWCAP_VIS, 0, v9a), /* wr ...,%tick_cmpr */ 1023 1.6 christos wrasr (24, HWCAP_VIS2, 0, v9b), /* wr ...,%sys_tick */ 1024 1.6 christos wrasr (25, HWCAP_VIS2, 0, v9b), /* wr ...,%sys_tick_cmpr */ 1025 1.6 christos wrasr (26, HWCAP_CBCOND, 0, v9e), /* wr ...,%cfr */ 1026 1.3 christos wrasr (27, HWCAP_PAUSE, 0, v9e), /* wr ...,%pause */ 1027 1.8 christos wrasr (28, 0, HWCAP2_MWAIT, v9m), /* wr ...,%mwait */ 1028 1.8 christos 1029 1.8 christos { "pwr", F3(2, 0x31, 0)|RD(1), F3(~2, ~0x31, ~0)|RD(~1)|ASI(~0), "1,2,p", 0, 0, 0, leon }, /* pwr r,r,%psr */ 1030 1.8 christos { "pwr", F3(2, 0x31, 1)|RD(1), F3(~2, ~0x31, ~1)|RD(~1), "1,i,p", 0, 0, 0, leon }, /* pwr r,i,%psr */ 1031 1.8 christos { "pwr", F3(2, 0x31, 0)|RD(1), F3(~2, ~0x31, ~0)|RD(~1)|RS1_G0|ASI(~0), "2,p", F_PREF_ALIAS, 0, 0, leon }, /* pwr %g0,rs2,%psr */ 1032 1.8 christos { "pwr", F3(2, 0x31, 1)|RD(1), F3(~2, ~0x31, ~1)|RD(~1)|RS1_G0, "i,p", F_PREF_ALIAS, 0, 0, leon }, /* pwr %g0,i,%psr */ 1033 1.8 christos { "pwr", F3(2, 0x31, 1)|RD(1), F3(~2, ~0x31, ~1)|RD(~1)|SIMM13(~0), "1,p", F_PREF_ALIAS, 0, 0, leon }, /* pwr rs1,0,%psr */ 1034 1.6 christos { "pwr", F3(2, 0x31, 0)|RD(1), F3(~2, ~0x31, ~0)|RD(~1)|ASI_RS2(~0), "1,p", F_PREF_ALIAS, 0, 0, leon }, /* pwr rs1,%g0,%psr */ 1035 1.6 christos 1036 1.6 christos { "pause", F3(2, 0x30, 1)|RD(27)|RS1(0), F3(~2, ~0x30, ~1)|RD(~27)|RS1(~0), "i", 0, HWCAP_PAUSE, 0, v9e }, /* wr %g0,i,%pause */ 1037 1.6 christos 1038 1.6 christos { "rd", F3(2, 0x28, 0)|RS1(2), F3(~2, ~0x28, ~0)|RS1(~2)|SIMM13(~0), "E,d", 0, 0, 0, v9 }, /* rd %ccr,r */ 1039 1.6 christos { "rd", F3(2, 0x28, 0)|RS1(3), F3(~2, ~0x28, ~0)|RS1(~3)|SIMM13(~0), "o,d", 0, 0, 0, v9 }, /* rd %asi,r */ 1040 1.6 christos { "rd", F3(2, 0x28, 0)|RS1(4), F3(~2, ~0x28, ~0)|RS1(~4)|SIMM13(~0), "W,d", 0, 0, 0, v9 }, /* rd %tick,r */ 1041 1.8 christos { "rd", F3(2, 0x28, 0)|RS1(5), F3(~2, ~0x28, ~0)|RS1(~5)|SIMM13(~0), "P,d", 0, 0, 0, v9 }, /* rd %pc,r */ 1042 1.6 christos { "rd", F3(2, 0x28, 0)|RS1(6), F3(~2, ~0x28, ~0)|RS1(~6)|SIMM13(~0), "s,d", 0, 0, 0, v9 }, /* rd %fprs,r */ 1043 1.6 christos { "rd", F3(2, 0x28, 0)|RS1(13), F3(~2, ~0x28, ~0)|RS1(~13)|SIMM13(~0), "&,d", 0, 0, HWCAP2_SPARC6, m8 }, /* rd %entropy,r */ 1044 1.6 christos { "rd", F3(2, 0x28, 0)|RS1(14), F3(~2, ~0x28, ~0)|RS1(~14)|SIMM13(~0), "{,d", 0, 0, HWCAP2_SPARC5, v9m }, /* rd %mcdper,r */ 1045 1.6 christos 1046 1.6 christos /* Read from ASR registers 16..31, which is the range defined in SPARC 1047 1.6 christos V9 for implementation-dependent uses. Note that the write-only ASR 1048 1.6 christos registers can't be used in a `rd' instruction. */ 1049 1.6 christos 1050 1.6 christos #define rdasr(asr,hwcap,hwcap2,arch) \ 1051 1.6 christos { "rd", F3(2, 0x28, 0)|RS1((asr)), F3(~2, ~0x28, ~0)|RS1(~(asr))|SIMM13(~0), "/,d", 0, (hwcap), (hwcap2), (arch) } 1052 1.6 christos 1053 1.6 christos rdasr (16, HWCAP_VIS, 0, v9a), /* rd %pcr,r */ 1054 1.6 christos rdasr (17, HWCAP_VIS, 0, v9a), /* rd %pic,r */ 1055 1.6 christos rdasr (18, HWCAP_VIS, 0, v9a), /* rd %dcr,r */ 1056 1.6 christos rdasr (19, HWCAP_VIS, 0, v9a), /* rd %gsr,r */ 1057 1.6 christos rdasr (22, HWCAP_VIS, 0, v9a), /* rd %softint,r */ 1058 1.6 christos rdasr (23, HWCAP_VIS, 0, v9a), /* rd %tick_cmpr,r */ 1059 1.6 christos rdasr (24, HWCAP_VIS2, 0, v9b), /* rd %sys_tick,r */ 1060 1.3 christos rdasr (25, HWCAP_VIS2, 0, v9b), /* rd %sys_tick_cmpr,r */ 1061 1.3 christos rdasr (26, HWCAP_CBCOND, 0, v9e), /* rd %cfr,r */ 1062 1.3 christos 1063 1.3 christos { "rd", F3(2, 0x28, 0), F3(~2, ~0x28, ~0)|SIMM13(~0), "M,d", 0, 0, 0, v8 }, /* rd %asrX,r */ 1064 1.3 christos { "rd", F3(2, 0x28, 0), F3(~2, ~0x28, ~0)|RS1_G0|SIMM13(~0), "y,d", 0, 0, 0, v6 }, /* rd %y,r */ 1065 1.3 christos { "rd", F3(2, 0x29, 0), F3(~2, ~0x29, ~0)|RS1_G0|SIMM13(~0), "p,d", 0, 0, 0, v6notv9 }, /* rd %psr,r */ 1066 1.3 christos { "rd", F3(2, 0x2a, 0), F3(~2, ~0x2a, ~0)|RS1_G0|SIMM13(~0), "w,d", 0, 0, 0, v6notv9 }, /* rd %wim,r */ 1067 1.6 christos { "rd", F3(2, 0x2b, 0), F3(~2, ~0x2b, ~0)|RS1_G0|SIMM13(~0), "t,d", 0, 0, 0, v6notv9 }, /* rd %tbr,r */ 1068 1.6 christos 1069 1.6 christos /* Instructions to read and write from/to privileged registers. */ 1070 1.6 christos 1071 1.3 christos #define rdpr(reg,hwcap,hwcap2,arch) \ 1072 1.6 christos { "rdpr", F3(2, 0x2a, 0)|RS1((reg)), F3(~2, ~0x2a, ~0)|RS1(~(reg))|SIMM13(~0),"?,d", 0, (hwcap), (hwcap2), (arch) } /* rdpr %priv,r */ 1073 1.6 christos 1074 1.6 christos rdpr (0, 0, 0, v9), /* rdpr %tpc,r */ 1075 1.6 christos rdpr (1, 0, 0, v9), /* rdpr %tnpc,r */ 1076 1.6 christos rdpr (2, 0, 0, v9), /* rdpr %tstate,r */ 1077 1.6 christos rdpr (3, 0, 0, v9), /* rdpr %tt,r */ 1078 1.6 christos rdpr (4, 0, 0, v9), /* rdpr %tick,r */ 1079 1.6 christos rdpr (5, 0, 0, v9), /* rdpr %tba,r */ 1080 1.6 christos rdpr (6, 0, 0, v9), /* rdpr %pstate,r */ 1081 1.6 christos rdpr (7, 0, 0, v9), /* rdpr %tl,r */ 1082 1.6 christos rdpr (8, 0, 0, v9), /* rdpr %pil,r */ 1083 1.6 christos rdpr (9, 0, 0, v9), /* rdpr %cwp,r */ 1084 1.6 christos rdpr (10, 0, 0, v9), /* rdpr %cansave,r */ 1085 1.6 christos rdpr (11, 0, 0, v9), /* rdpr %canrestore,r */ 1086 1.6 christos rdpr (12, 0, 0, v9), /* rdpr %cleanwin,r */ 1087 1.6 christos rdpr (13, 0, 0, v9), /* rdpr %otherwin,r */ 1088 1.6 christos rdpr (14, 0, 0, v9), /* rdpr %wstate,r */ 1089 1.6 christos rdpr (15, 0, 0, v9), /* rdpr %fq,r */ 1090 1.6 christos rdpr (16, 0, 0, v9), /* rdpr %gl,r */ 1091 1.6 christos rdpr (23, 0, HWCAP2_SPARC5, v9m), /* rdpr %pmcdper,r */ 1092 1.6 christos rdpr (31, 0, 0, v9), /* rdpr %ver,r */ 1093 1.6 christos 1094 1.6 christos #define wrpr(reg,hwcap,hwcap2,arch) \ 1095 1.6 christos { "wrpr", F3(2, 0x32, 0)|RD((reg)), F3(~2, ~0x32, ~0)|RD(~(reg)), "1,2,!", 0, (hwcap), (hwcap2), (arch) }, /* wrpr r1,r2,%priv */ \ 1096 1.6 christos { "wrpr", F3(2, 0x32, 0)|RD((reg)), F3(~2, ~0x32, ~0)|RD(~(reg))|SIMM13(~0), "1,!", 0, (hwcap), (hwcap2), (arch) }, /* wrpr r1,%priv */ \ 1097 1.6 christos { "wrpr", F3(2, 0x32, 1)|RD((reg)), F3(~2, ~0x32, ~1)|RD(~(reg)), "1,i,!", 0, (hwcap), (hwcap2), (arch) }, /* wrpr r1,i,%priv */ \ 1098 1.6 christos { "wrpr", F3(2, 0x32, 1)|RD((reg)), F3(~2, ~0x32, ~1)|RD(~(reg)), "i,1,!", F_ALIAS, (hwcap), (hwcap2), (arch) }, /* wrpr i,r1,%priv */ \ 1099 1.6 christos { "wrpr", F3(2, 0x32, 1)|RD((reg)), F3(~2, ~0x32, ~1)|RD(~(reg))|RS1(~0), "i,!", 0, (hwcap), (hwcap2), (arch) } /* wrpr i,%priv */ 1100 1.6 christos 1101 1.6 christos wrpr (0, 0, 0, v9), /* wrpr ...,%tpc */ 1102 1.6 christos wrpr (1, 0, 0, v9), /* wrpr ...,%tnpc */ 1103 1.6 christos wrpr (2, 0, 0, v9), /* wrpr ...,%tstate */ 1104 1.6 christos wrpr (3, 0, 0, v9), /* wrpr ...,%tt */ 1105 1.6 christos wrpr (4, 0, 0, v9), /* wrpr ...,%tick */ 1106 1.6 christos wrpr (5, 0, 0, v9), /* wrpr ...,%tba */ 1107 1.6 christos wrpr (6, 0, 0, v9), /* wrpr ...,%pstate */ 1108 1.6 christos wrpr (7, 0, 0, v9), /* wrpr ...,%tl */ 1109 1.6 christos wrpr (8, 0, 0, v9), /* wrpr ...,%pil */ 1110 1.6 christos wrpr (9, 0, 0, v9), /* wrpr ...,%cwp */ 1111 1.6 christos wrpr (10, 0, 0, v9), /* wrpr ...,%cansave */ 1112 1.6 christos wrpr (11, 0, 0, v9), /* wrpr ...,%canrestore */ 1113 1.6 christos wrpr (12, 0, 0, v9), /* wrpr ...,%cleanwin */ 1114 1.6 christos wrpr (13, 0, 0, v9), /* wrpr ...,%otherwin */ 1115 1.6 christos wrpr (14, 0, 0, v9), /* wrpr ...,%wstate */ 1116 1.6 christos wrpr (15, 0, 0, v9), /* wrpr ...,%fq */ 1117 1.6 christos wrpr (16, 0, 0, v9), /* wrpr ...,%gl */ 1118 1.6 christos wrpr (23, 0, HWCAP2_SPARC5, v9m), /* wdpr ...,%pmcdper */ 1119 1.6 christos wrpr (31, 0, 0, v9), /* wrpr ...,%ver */ 1120 1.6 christos 1121 1.6 christos /* Instructions to read and write from/to hyperprivileged 1122 1.6 christos registers. */ 1123 1.6 christos 1124 1.6 christos #define rdhpr(reg,hwcap,hwcap2,arch) \ 1125 1.6 christos { "rdhpr", F3(2, 0x29, 0)|RS1((reg)), F3(~2, ~0x29, ~0)|RS1(~(reg))|SIMM13(~0), "$,d", 0, (hwcap), (hwcap2), (arch) } 1126 1.6 christos 1127 1.6 christos rdhpr (0, HWCAP_VIS, 0, v9a), /* rdhpr %hpstate,r */ 1128 1.6 christos rdhpr (1, HWCAP_VIS, 0, v9a), /* rdhpr %htstate,r */ 1129 1.6 christos rdhpr (3, HWCAP_VIS, 0, v9a), /* rdhpr %hintp,r */ 1130 1.6 christos rdhpr (5, HWCAP_VIS, 0, v9a), /* rdhpr %htba,r */ 1131 1.6 christos rdhpr (6, HWCAP_VIS, 0, v9a), /* rdhpr %hver,r */ 1132 1.6 christos rdhpr (23, 0, HWCAP2_SPARC5, v9m), /* rdhpr %hmcdper,r */ 1133 1.6 christos rdhpr (24, 0, HWCAP2_SPARC5, v9m), /* rdhpr %hmcddfr,r */ 1134 1.6 christos rdhpr (27, 0, HWCAP2_SPARC5, v9m), /* rdhpr %hva_mask_nz,r */ 1135 1.6 christos rdhpr (28, HWCAP_VIS, 0, v9a), /* rdhpr %hstick_offset,r */ 1136 1.6 christos rdhpr (29, HWCAP_VIS, 0, v9a), /* rdhpar %hstick_enable,r */ 1137 1.6 christos rdhpr (31, HWCAP_VIS, 0, v9a), /* rdhpr %hstick_cmpr,r */ 1138 1.6 christos 1139 1.6 christos #define wrhpr(reg,hwcap,hwcap2,arch) \ 1140 1.6 christos { "wrhpr", F3(2, 0x33, 0)|RD((reg)), F3(~2, ~0x33, ~0)|RD(~(reg)),"1,2,%", 0, (hwcap), (hwcap2), (arch) }, /* wrhpr r1,r2,%hpriv */ \ 1141 1.6 christos { "wrhpr", F3(2, 0x33, 0)|RD((reg)), F3(~2, ~0x33, ~0)|RD(~(reg))|SIMM13(~0), "1,%", 0, (hwcap), (hwcap2), (arch) }, /* wrhpr r1,%hpriv */ \ 1142 1.6 christos { "wrhpr", F3(2, 0x33, 1)|RD((reg)), F3(~2, ~0x33, ~1)|RD(~(reg)), "1,i,%", 0, (hwcap), (hwcap2), (arch) }, /* wrhpr r1,i,%hpriv */ \ 1143 1.6 christos { "wrhpr", F3(2, 0x33, 1)|RD((reg)), F3(~2, ~0x33, ~1)|RD(~(reg)), "i,1,%", F_ALIAS, (hwcap), (hwcap2), (arch) }, /* wrhpr i,r1,%hpriv */ \ 1144 1.6 christos { "wrhpr", F3(2, 0x33, 1)|RD((reg)), F3(~2, ~0x33, ~1)|RD(~(reg))|RS1(~0), "i,%", 0, (hwcap), (hwcap2), (arch) } /* wrhpr i,%hpriv */ 1145 1.6 christos 1146 1.6 christos wrhpr (0, HWCAP_VIS, 0, v9a), /* wrhpr ...,%hpstate */ 1147 1.6 christos wrhpr (1, HWCAP_VIS, 0, v9a), /* wrhpr ...,%htstate */ 1148 1.6 christos wrhpr (3, HWCAP_VIS, 0, v9a), /* wrhpr ...,%hintp */ 1149 1.6 christos wrhpr (5, HWCAP_VIS, 0, v9a), /* wrhpr ...,%htba */ 1150 1.6 christos wrhpr (23, 0, HWCAP2_SPARC5, v9m), /* wrhpr ...,%hmcdper */ 1151 1.6 christos wrhpr (24, 0, HWCAP2_SPARC5, v9m), /* wrhpr ...,%hmcddfr */ 1152 1.6 christos wrhpr (27, 0, HWCAP2_SPARC5, v9m), /* wrhpr ...,%hva_mask_nz */ 1153 1.6 christos wrhpr (28, HWCAP_VIS, 0, v9a), /* wrhpr ...,%hstick_offset */ 1154 1.3 christos wrhpr (29, HWCAP_VIS, 0, v9a), /* wrhpr ...,%hstick_enable */ 1155 1.3 christos wrhpr (31, HWCAP_VIS, 0, v9a), /* wrhpr ...,%hstick_cmpr */ 1156 1.3 christos 1157 1.3 christos { "mov", F3(2, 0x28, 0), F3(~2, ~0x28, ~0)|SIMM13(~0), "M,d", F_ALIAS, 0, 0, v8 }, /* rd %asr1,r */ 1158 1.3 christos { "mov", F3(2, 0x28, 0), F3(~2, ~0x28, ~0)|RS1_G0|SIMM13(~0), "y,d", F_ALIAS, 0, 0, v6 }, /* rd %y,r */ 1159 1.3 christos { "mov", F3(2, 0x29, 0), F3(~2, ~0x29, ~0)|RS1_G0|SIMM13(~0), "p,d", F_ALIAS, 0, 0, v6notv9 }, /* rd %psr,r */ 1160 1.3 christos { "mov", F3(2, 0x2a, 0), F3(~2, ~0x2a, ~0)|RS1_G0|SIMM13(~0), "w,d", F_ALIAS, 0, 0, v6notv9 }, /* rd %wim,r */ 1161 1.3 christos { "mov", F3(2, 0x2b, 0), F3(~2, ~0x2b, ~0)|RS1_G0|SIMM13(~0), "t,d", F_ALIAS, 0, 0, v6notv9 }, /* rd %tbr,r */ 1162 1.3 christos 1163 1.3 christos { "mov", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|RS1_G0|ASI(~0), "2,m", F_ALIAS, 0, 0, v8 }, /* wr %g0,rs2,%asrX */ 1164 1.3 christos { "mov", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|RS1_G0, "i,m", F_ALIAS, 0, 0, v8 }, /* wr %g0,i,%asrX */ 1165 1.3 christos { "mov", F3(2, 0x30, 0), F3(~2, ~0x30, ~0)|RD_G0|RS1_G0|ASI(~0), "2,y", F_ALIAS, 0, 0, v6 }, /* wr %g0,rs2,%y */ 1166 1.3 christos { "mov", F3(2, 0x30, 1), F3(~2, ~0x30, ~1)|RD_G0|RS1_G0, "i,y", F_ALIAS, 0, 0, v6 }, /* wr %g0,i,%y */ 1167 1.3 christos { "mov", F3(2, 0x31, 0), F3(~2, ~0x31, ~0)|RD_G0|RS1_G0|ASI(~0), "2,p", F_ALIAS, 0, 0, v6notv9 }, /* wr %g0,rs2,%psr */ 1168 1.3 christos { "mov", F3(2, 0x31, 1), F3(~2, ~0x31, ~1)|RD_G0|RS1_G0, "i,p", F_ALIAS, 0, 0, v6notv9 }, /* wr %g0,i,%psr */ 1169 1.3 christos { "mov", F3(2, 0x32, 0), F3(~2, ~0x32, ~0)|RD_G0|RS1_G0|ASI(~0), "2,w", F_ALIAS, 0, 0, v6notv9 }, /* wr %g0,rs2,%wim */ 1170 1.3 christos { "mov", F3(2, 0x32, 1), F3(~2, ~0x32, ~1)|RD_G0|RS1_G0, "i,w", F_ALIAS, 0, 0, v6notv9 }, /* wr %g0,i,%wim */ 1171 1.3 christos { "mov", F3(2, 0x33, 0), F3(~2, ~0x33, ~0)|RD_G0|RS1_G0|ASI(~0), "2,t", F_ALIAS, 0, 0, v6notv9 }, /* wr %g0,rs2,%tbr */ 1172 1.3 christos { "mov", F3(2, 0x33, 1), F3(~2, ~0x33, ~1)|RD_G0|RS1_G0, "i,t", F_ALIAS, 0, 0, v6notv9 }, /* wr %g0,i,%tbr */ 1173 1.3 christos 1174 1.3 christos { "mov", F3(2, 0x02, 0), F3(~2, ~0x02, ~0)|RS1_G0|ASI(~0), "2,d", 0, 0, 0, v6 }, /* or %g0,rs2,d */ 1175 1.3 christos { "mov", F3(2, 0x02, 1), F3(~2, ~0x02, ~1)|RS1_G0, "i,d", 0, 0, 0, v6 }, /* or %g0,i,d */ 1176 1.3 christos { "mov", F3(2, 0x02, 0), F3(~2, ~0x02, ~0)|ASI_RS2(~0), "1,d", 0, 0, 0, v6 }, /* or rs1,%g0,d */ 1177 1.3 christos { "mov", F3(2, 0x02, 1), F3(~2, ~0x02, ~1)|SIMM13(~0), "1,d", 0, 0, 0, v6 }, /* or rs1,0,d */ 1178 1.3 christos 1179 1.3 christos { "or", F3(2, 0x02, 0), F3(~2, ~0x02, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1180 1.1 christos { "or", F3(2, 0x02, 1), F3(~2, ~0x02, ~1), "1,i,d", 0, 0, 0, v6 }, 1181 1.3 christos { "or", F3(2, 0x02, 1), F3(~2, ~0x02, ~1), "i,1,d", 0, 0, 0, v6 }, 1182 1.3 christos 1183 1.1 christos { "bset", F3(2, 0x02, 0), F3(~2, ~0x02, ~0)|ASI(~0), "2,r", F_ALIAS, 0, 0, v6 }, /* or rd,rs2,rd */ 1184 1.1 christos { "bset", F3(2, 0x02, 1), F3(~2, ~0x02, ~1), "i,r", F_ALIAS, 0, 0, v6 }, /* or rd,i,rd */ 1185 1.3 christos 1186 1.3 christos /* This is not a commutative instruction. */ 1187 1.1 christos { "andn", F3(2, 0x05, 0), F3(~2, ~0x05, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1188 1.1 christos { "andn", F3(2, 0x05, 1), F3(~2, ~0x05, ~1), "1,i,d", 0, 0, 0, v6 }, 1189 1.3 christos 1190 1.3 christos /* This is not a commutative instruction. */ 1191 1.1 christos { "andncc", F3(2, 0x15, 0), F3(~2, ~0x15, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1192 1.3 christos { "andncc", F3(2, 0x15, 1), F3(~2, ~0x15, ~1), "1,i,d", 0, 0, 0, v6 }, 1193 1.3 christos 1194 1.1 christos { "bclr", F3(2, 0x05, 0), F3(~2, ~0x05, ~0)|ASI(~0), "2,r", F_ALIAS, 0, 0, v6 }, /* andn rd,rs2,rd */ 1195 1.3 christos { "bclr", F3(2, 0x05, 1), F3(~2, ~0x05, ~1), "i,r", F_ALIAS, 0, 0, v6 }, /* andn rd,i,rd */ 1196 1.3 christos 1197 1.1 christos { "cmp", F3(2, 0x14, 0), F3(~2, ~0x14, ~0)|RD_G0|ASI(~0), "1,2", 0, 0, 0, v6 }, /* subcc rs1,rs2,%g0 */ 1198 1.3 christos { "cmp", F3(2, 0x14, 1), F3(~2, ~0x14, ~1)|RD_G0, "1,i", 0, 0, 0, v6 }, /* subcc rs1,i,%g0 */ 1199 1.3 christos 1200 1.3 christos { "sub", F3(2, 0x04, 0), F3(~2, ~0x04, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1201 1.3 christos { "sub", F3(2, 0x04, 1), F3(~2, ~0x04, ~1), "1,i,d", 0, 0, 0, v6 }, 1202 1.3 christos 1203 1.3 christos { "subcc", F3(2, 0x14, 0), F3(~2, ~0x14, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1204 1.3 christos { "subcc", F3(2, 0x14, 1), F3(~2, ~0x14, ~1), "1,i,d", 0, 0, 0, v6 }, 1205 1.3 christos 1206 1.3 christos { "subx", F3(2, 0x0c, 0), F3(~2, ~0x0c, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6notv9 }, 1207 1.3 christos { "subx", F3(2, 0x0c, 1), F3(~2, ~0x0c, ~1), "1,i,d", 0, 0, 0, v6notv9 }, 1208 1.3 christos { "subc", F3(2, 0x0c, 0), F3(~2, ~0x0c, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1209 1.3 christos { "subc", F3(2, 0x0c, 1), F3(~2, ~0x0c, ~1), "1,i,d", 0, 0, 0, v9 }, 1210 1.3 christos 1211 1.3 christos { "subxcc", F3(2, 0x1c, 0), F3(~2, ~0x1c, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6notv9 }, 1212 1.3 christos { "subxcc", F3(2, 0x1c, 1), F3(~2, ~0x1c, ~1), "1,i,d", 0, 0, 0, v6notv9 }, 1213 1.3 christos { "subccc", F3(2, 0x1c, 0), F3(~2, ~0x1c, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1214 1.3 christos { "subccc", F3(2, 0x1c, 1), F3(~2, ~0x1c, ~1), "1,i,d", 0, 0, 0, v9 }, 1215 1.3 christos 1216 1.3 christos { "and", F3(2, 0x01, 0), F3(~2, ~0x01, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1217 1.3 christos { "and", F3(2, 0x01, 1), F3(~2, ~0x01, ~1), "1,i,d", 0, 0, 0, v6 }, 1218 1.3 christos { "and", F3(2, 0x01, 1), F3(~2, ~0x01, ~1), "i,1,d", 0, 0, 0, v6 }, 1219 1.3 christos 1220 1.3 christos { "andcc", F3(2, 0x11, 0), F3(~2, ~0x11, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1221 1.3 christos { "andcc", F3(2, 0x11, 1), F3(~2, ~0x11, ~1), "1,i,d", 0, 0, 0, v6 }, 1222 1.3 christos { "andcc", F3(2, 0x11, 1), F3(~2, ~0x11, ~1), "i,1,d", 0, 0, 0, v6 }, 1223 1.3 christos 1224 1.3 christos { "dec", F3(2, 0x04, 1)|SIMM13(0x1), F3(~2, ~0x04, ~1)|SIMM13(~0x0001), "r", F_ALIAS, 0, 0, v6 }, /* sub rd,1,rd */ 1225 1.3 christos { "dec", F3(2, 0x04, 1), F3(~2, ~0x04, ~1), "i,r", F_ALIAS, 0, 0, v8 }, /* sub rd,imm,rd */ 1226 1.3 christos { "deccc", F3(2, 0x14, 1)|SIMM13(0x1), F3(~2, ~0x14, ~1)|SIMM13(~0x0001), "r", F_ALIAS, 0, 0, v6 }, /* subcc rd,1,rd */ 1227 1.3 christos { "deccc", F3(2, 0x14, 1), F3(~2, ~0x14, ~1), "i,r", F_ALIAS, 0, 0, v8 }, /* subcc rd,imm,rd */ 1228 1.3 christos { "inc", F3(2, 0x00, 1)|SIMM13(0x1), F3(~2, ~0x00, ~1)|SIMM13(~0x0001), "r", F_ALIAS, 0, 0, v6 }, /* add rd,1,rd */ 1229 1.3 christos { "inc", F3(2, 0x00, 1), F3(~2, ~0x00, ~1), "i,r", F_ALIAS, 0, 0, v8 }, /* add rd,imm,rd */ 1230 1.3 christos { "inccc", F3(2, 0x10, 1)|SIMM13(0x1), F3(~2, ~0x10, ~1)|SIMM13(~0x0001), "r", F_ALIAS, 0, 0, v6 }, /* addcc rd,1,rd */ 1231 1.3 christos { "inccc", F3(2, 0x10, 1), F3(~2, ~0x10, ~1), "i,r", F_ALIAS, 0, 0, v8 }, /* addcc rd,imm,rd */ 1232 1.3 christos 1233 1.3 christos { "btst", F3(2, 0x11, 0), F3(~2, ~0x11, ~0)|RD_G0|ASI(~0), "1,2", F_ALIAS, 0, 0, v6 }, /* andcc rs1,rs2,%g0 */ 1234 1.3 christos { "btst", F3(2, 0x11, 1), F3(~2, ~0x11, ~1)|RD_G0, "i,1", F_ALIAS, 0, 0, v6 }, /* andcc rs1,i,%g0 */ 1235 1.3 christos 1236 1.3 christos { "neg", F3(2, 0x04, 0), F3(~2, ~0x04, ~0)|RS1_G0|ASI(~0), "2,d", F_ALIAS, 0, 0, v6 }, /* sub %g0,rs2,rd */ 1237 1.3 christos { "neg", F3(2, 0x04, 0), F3(~2, ~0x04, ~0)|RS1_G0|ASI(~0), "O", F_ALIAS, 0, 0, v6 }, /* sub %g0,rd,rd */ 1238 1.3 christos 1239 1.3 christos { "add", F3(2, 0x00, 0), F3(~2, ~0x00, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1240 1.3 christos { "add", F3(2, 0x00, 1), F3(~2, ~0x00, ~1), "1,i,d", 0, 0, 0, v6 }, 1241 1.3 christos { "add", F3(2, 0x00, 1), F3(~2, ~0x00, ~1), "i,1,d", 0, 0, 0, v6 }, 1242 1.3 christos { "addcc", F3(2, 0x10, 0), F3(~2, ~0x10, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1243 1.3 christos { "addcc", F3(2, 0x10, 1), F3(~2, ~0x10, ~1), "1,i,d", 0, 0, 0, v6 }, 1244 1.3 christos { "addcc", F3(2, 0x10, 1), F3(~2, ~0x10, ~1), "i,1,d", 0, 0, 0, v6 }, 1245 1.3 christos 1246 1.3 christos { "addx", F3(2, 0x08, 0), F3(~2, ~0x08, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6notv9 }, 1247 1.3 christos { "addx", F3(2, 0x08, 1), F3(~2, ~0x08, ~1), "1,i,d", 0, 0, 0, v6notv9 }, 1248 1.3 christos { "addx", F3(2, 0x08, 1), F3(~2, ~0x08, ~1), "i,1,d", 0, 0, 0, v6notv9 }, 1249 1.3 christos { "addc", F3(2, 0x08, 0), F3(~2, ~0x08, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1250 1.3 christos { "addc", F3(2, 0x08, 1), F3(~2, ~0x08, ~1), "1,i,d", 0, 0, 0, v9 }, 1251 1.3 christos { "addc", F3(2, 0x08, 1), F3(~2, ~0x08, ~1), "i,1,d", 0, 0, 0, v9 }, 1252 1.3 christos 1253 1.3 christos { "addxcc", F3(2, 0x18, 0), F3(~2, ~0x18, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6notv9 }, 1254 1.3 christos { "addxcc", F3(2, 0x18, 1), F3(~2, ~0x18, ~1), "1,i,d", 0, 0, 0, v6notv9 }, 1255 1.3 christos { "addxcc", F3(2, 0x18, 1), F3(~2, ~0x18, ~1), "i,1,d", 0, 0, 0, v6notv9 }, 1256 1.3 christos { "addccc", F3(2, 0x18, 0), F3(~2, ~0x18, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1257 1.3 christos { "addccc", F3(2, 0x18, 1), F3(~2, ~0x18, ~1), "1,i,d", 0, 0, 0, v9 }, 1258 1.3 christos { "addccc", F3(2, 0x18, 1), F3(~2, ~0x18, ~1), "i,1,d", 0, 0, 0, v9 }, 1259 1.3 christos 1260 1.3 christos { "smul", F3(2, 0x0b, 0), F3(~2, ~0x0b, ~0)|ASI(~0), "1,2,d", 0, HWCAP_MUL32, 0, v8 }, 1261 1.3 christos { "smul", F3(2, 0x0b, 1), F3(~2, ~0x0b, ~1), "1,i,d", 0, HWCAP_MUL32, 0, v8 }, 1262 1.3 christos { "smul", F3(2, 0x0b, 1), F3(~2, ~0x0b, ~1), "i,1,d", 0, HWCAP_MUL32, 0, v8 }, 1263 1.3 christos { "smulcc", F3(2, 0x1b, 0), F3(~2, ~0x1b, ~0)|ASI(~0), "1,2,d", 0, HWCAP_MUL32, 0, v8 }, 1264 1.3 christos { "smulcc", F3(2, 0x1b, 1), F3(~2, ~0x1b, ~1), "1,i,d", 0, HWCAP_MUL32, 0, v8 }, 1265 1.3 christos { "smulcc", F3(2, 0x1b, 1), F3(~2, ~0x1b, ~1), "i,1,d", 0, HWCAP_MUL32, 0, v8 }, 1266 1.3 christos { "umul", F3(2, 0x0a, 0), F3(~2, ~0x0a, ~0)|ASI(~0), "1,2,d", 0, HWCAP_MUL32, 0, v8 }, 1267 1.3 christos { "umul", F3(2, 0x0a, 1), F3(~2, ~0x0a, ~1), "1,i,d", 0, HWCAP_MUL32, 0, v8 }, 1268 1.3 christos { "umul", F3(2, 0x0a, 1), F3(~2, ~0x0a, ~1), "i,1,d", 0, HWCAP_MUL32, 0, v8 }, 1269 1.3 christos { "umulcc", F3(2, 0x1a, 0), F3(~2, ~0x1a, ~0)|ASI(~0), "1,2,d", 0, HWCAP_MUL32, 0, v8 }, 1270 1.3 christos { "umulcc", F3(2, 0x1a, 1), F3(~2, ~0x1a, ~1), "1,i,d", 0, HWCAP_MUL32, 0, v8 }, 1271 1.3 christos { "umulcc", F3(2, 0x1a, 1), F3(~2, ~0x1a, ~1), "i,1,d", 0, HWCAP_MUL32, 0, v8 }, 1272 1.3 christos { "sdiv", F3(2, 0x0f, 0), F3(~2, ~0x0f, ~0)|ASI(~0), "1,2,d", 0, HWCAP_DIV32, 0, v8 }, 1273 1.3 christos { "sdiv", F3(2, 0x0f, 1), F3(~2, ~0x0f, ~1), "1,i,d", 0, HWCAP_DIV32, 0, v8 }, 1274 1.3 christos { "sdiv", F3(2, 0x0f, 1), F3(~2, ~0x0f, ~1), "i,1,d", 0, HWCAP_DIV32, 0, v8 }, 1275 1.3 christos { "sdivcc", F3(2, 0x1f, 0), F3(~2, ~0x1f, ~0)|ASI(~0), "1,2,d", 0, HWCAP_DIV32, 0, v8 }, 1276 1.3 christos { "sdivcc", F3(2, 0x1f, 1), F3(~2, ~0x1f, ~1), "1,i,d", 0, HWCAP_DIV32, 0, v8 }, 1277 1.3 christos { "sdivcc", F3(2, 0x1f, 1), F3(~2, ~0x1f, ~1), "i,1,d", 0, HWCAP_DIV32, 0, v8 }, 1278 1.3 christos { "udiv", F3(2, 0x0e, 0), F3(~2, ~0x0e, ~0)|ASI(~0), "1,2,d", 0, HWCAP_DIV32, 0, v8 }, 1279 1.3 christos { "udiv", F3(2, 0x0e, 1), F3(~2, ~0x0e, ~1), "1,i,d", 0, HWCAP_DIV32, 0, v8 }, 1280 1.3 christos { "udiv", F3(2, 0x0e, 1), F3(~2, ~0x0e, ~1), "i,1,d", 0, HWCAP_DIV32, 0, v8 }, 1281 1.3 christos { "udivcc", F3(2, 0x1e, 0), F3(~2, ~0x1e, ~0)|ASI(~0), "1,2,d", 0, HWCAP_DIV32, 0, v8 }, 1282 1.3 christos { "udivcc", F3(2, 0x1e, 1), F3(~2, ~0x1e, ~1), "1,i,d", 0, HWCAP_DIV32, 0, v8 }, 1283 1.3 christos { "udivcc", F3(2, 0x1e, 1), F3(~2, ~0x1e, ~1), "i,1,d", 0, HWCAP_DIV32, 0, v8 }, 1284 1.3 christos 1285 1.3 christos { "mulx", F3(2, 0x09, 0), F3(~2, ~0x09, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1286 1.3 christos { "mulx", F3(2, 0x09, 1), F3(~2, ~0x09, ~1), "1,i,d", 0, 0, 0, v9 }, 1287 1.3 christos { "sdivx", F3(2, 0x2d, 0), F3(~2, ~0x2d, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1288 1.3 christos { "sdivx", F3(2, 0x2d, 1), F3(~2, ~0x2d, ~1), "1,i,d", 0, 0, 0, v9 }, 1289 1.3 christos { "udivx", F3(2, 0x0d, 0), F3(~2, ~0x0d, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9 }, 1290 1.3 christos { "udivx", F3(2, 0x0d, 1), F3(~2, ~0x0d, ~1), "1,i,d", 0, 0, 0, v9 }, 1291 1.3 christos 1292 1.3 christos { "call", F1(0x1), F1(~0x1), "L", F_JSR|F_DELAYED, 0, 0, v6 }, 1293 1.3 christos { "call", F1(0x1), F1(~0x1), "L,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1294 1.3 christos 1295 1.3 christos { "call", F3(2, 0x38, 0)|RD(0xf), F3(~2, ~0x38, ~0)|RD(~0xf)|ASI(~0), "1+2", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+rs2,%o7 */ 1296 1.3 christos { "call", F3(2, 0x38, 0)|RD(0xf), F3(~2, ~0x38, ~0)|RD(~0xf)|ASI(~0), "1+2,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1297 1.3 christos { "call", F3(2, 0x38, 0)|RD(0xf), F3(~2, ~0x38, ~0)|RD(~0xf)|ASI_RS2(~0), "1", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+%g0,%o7 */ 1298 1.3 christos { "call", F3(2, 0x38, 0)|RD(0xf), F3(~2, ~0x38, ~0)|RD(~0xf)|ASI_RS2(~0), "1,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1299 1.3 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf), "1+i", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+i,%o7 */ 1300 1.3 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf), "1+i,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1301 1.3 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf), "i+1", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl i+rs1,%o7 */ 1302 1.3 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf), "i+1,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1303 1.3 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf)|RS1_G0, "i", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl %g0+i,%o7 */ 1304 1.3 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf)|RS1_G0, "i,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1305 1.1 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf)|SIMM13(~0), "1", F_JSR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+0,%o7 */ 1306 1.1 christos { "call", F3(2, 0x38, 1)|RD(0xf), F3(~2, ~0x38, ~1)|RD(~0xf)|SIMM13(~0), "1,#", F_JSR|F_DELAYED, 0, 0, v6 }, 1307 1.1 christos 1308 1.1 christos /* Conditional instructions. 1309 1.1 christos 1310 1.1 christos Because this part of the table was such a mess earlier, I have 1311 1.1 christos macrofied it so that all the branches and traps are generated from 1312 1.1 christos a single-line description of each condition value. John Gilmore. */ 1313 1.1 christos 1314 1.3 christos /* Define branches -- one annulled, one without, etc. */ 1315 1.3 christos #define br(opcode, mask, lose, flags) \ 1316 1.1 christos { opcode, (mask)|ANNUL, (lose), ",a l", (flags), 0, 0, v6 }, \ 1317 1.1 christos { opcode, (mask) , (lose)|ANNUL, "l", (flags), 0, 0, v6 } 1318 1.3 christos 1319 1.3 christos #define brx(opcode, mask, lose, flags) /* v9 */ \ 1320 1.3 christos { opcode, (mask)|(2<<20)|BPRED, ANNUL|(lose), "Z,G", (flags), 0, 0, v9 }, \ 1321 1.3 christos { opcode, (mask)|(2<<20)|BPRED, ANNUL|(lose), ",T Z,G", (flags), 0, 0, v9 }, \ 1322 1.3 christos { opcode, (mask)|(2<<20)|BPRED|ANNUL, (lose), ",a Z,G", (flags), 0, 0, v9 }, \ 1323 1.3 christos { opcode, (mask)|(2<<20)|BPRED|ANNUL, (lose), ",a,T Z,G", (flags), 0, 0, v9 }, \ 1324 1.3 christos { opcode, (mask)|(2<<20), ANNUL|BPRED|(lose), ",N Z,G", (flags), 0, 0, v9 }, \ 1325 1.3 christos { opcode, (mask)|(2<<20)|ANNUL, BPRED|(lose), ",a,N Z,G", (flags), 0, 0, v9 }, \ 1326 1.3 christos { opcode, (mask)|BPRED, ANNUL|(lose)|(2<<20), "z,G", (flags), 0, 0, v9 }, \ 1327 1.3 christos { opcode, (mask)|BPRED, ANNUL|(lose)|(2<<20), ",T z,G", (flags), 0, 0, v9 }, \ 1328 1.3 christos { opcode, (mask)|BPRED|ANNUL, (lose)|(2<<20), ",a z,G", (flags), 0, 0, v9 }, \ 1329 1.3 christos { opcode, (mask)|BPRED|ANNUL, (lose)|(2<<20), ",a,T z,G", (flags), 0, 0, v9 }, \ 1330 1.1 christos { opcode, (mask), ANNUL|BPRED|(lose)|(2<<20), ",N z,G", (flags), 0, 0, v9 }, \ 1331 1.1 christos { opcode, (mask)|ANNUL, BPRED|(lose)|(2<<20), ",a,N z,G", (flags), 0, 0, v9 } 1332 1.1 christos 1333 1.3 christos /* Define four traps: reg+reg, reg + immediate, immediate alone, reg alone. */ 1334 1.3 christos #define tr(opcode, mask, lose, flags) \ 1335 1.3 christos { opcode, (mask)|(2<<11)|IMMED, (lose)|RS1_G0, "Z,i", (flags), 0, 0, v9 }, /* %g0 + imm */ \ 1336 1.3 christos { opcode, (mask)|(2<<11)|IMMED, (lose), "Z,1+i", (flags), 0, 0, v9 }, /* rs1 + imm */ \ 1337 1.3 christos { opcode, (mask)|(2<<11), IMMED|(lose), "Z,1+2", (flags), 0, 0, v9 }, /* rs1 + rs2 */ \ 1338 1.3 christos { opcode, (mask)|(2<<11), IMMED|(lose)|RS2_G0, "Z,1", (flags), 0, 0, v9 }, /* rs1 + %g0 */ \ 1339 1.3 christos { opcode, (mask)|IMMED, (lose)|RS1_G0, "z,i", (flags)|F_ALIAS, 0, 0, v9 }, /* %g0 + imm */ \ 1340 1.3 christos { opcode, (mask)|IMMED, (lose), "z,1+i", (flags)|F_ALIAS, 0, 0, v9 }, /* rs1 + imm */ \ 1341 1.3 christos { opcode, (mask), IMMED|(lose), "z,1+2", (flags)|F_ALIAS, 0, 0, v9 }, /* rs1 + rs2 */ \ 1342 1.3 christos { opcode, (mask), IMMED|(lose)|RS2_G0, "z,1", (flags)|F_ALIAS, 0, 0, v9 }, /* rs1 + %g0 */ \ 1343 1.3 christos { opcode, (mask)|IMMED, (lose)|RS1_G0, "i", (flags), 0, 0, v6 }, /* %g0 + imm */ \ 1344 1.3 christos { opcode, (mask)|IMMED, (lose), "1+i", (flags), 0, 0, v6 }, /* rs1 + imm */ \ 1345 1.3 christos { opcode, (mask)|IMMED, (lose), "i+1", (flags), 0, 0, v6 }, /* imm + rs1 */ \ 1346 1.1 christos { opcode, (mask), IMMED|(lose), "1+2", (flags), 0, 0, v6 }, /* rs1 + rs2 */ \ 1347 1.1 christos { opcode, (mask), IMMED|(lose)|RS2_G0, "1", (flags), 0, 0, v6 } /* rs1 + %g0 */ 1348 1.1 christos 1349 1.1 christos /* v9: We must put `brx' before `br', to ensure that we never match something 1350 1.1 christos v9: against an expression unless it is an expression. Otherwise, we end 1351 1.1 christos v9: up with undefined symbol tables entries, because they get added, but 1352 1.1 christos v9: are not deleted if the pattern fails to match. */ 1353 1.1 christos 1354 1.1 christos /* Define both branches and traps based on condition mask */ 1355 1.1 christos #define cond(bop, top, mask, flags) \ 1356 1.1 christos brx(bop, F2(0, 1)|(mask), F2(~0, ~1)|((~mask)&COND(~0)), F_DELAYED|(flags)), /* v9 */ \ 1357 1.1 christos br(bop, F2(0, 2)|(mask), F2(~0, ~2)|((~mask)&COND(~0)), F_DELAYED|(flags)), \ 1358 1.1 christos tr(top, F3(2, 0x3a, 0)|(mask), F3(~2, ~0x3a, 0)|((~mask)&COND(~0)), ((flags) & ~(F_UNBR|F_CONDBR))) 1359 1.1 christos 1360 1.1 christos /* Define all the conditions, all the branches, all the traps. */ 1361 1.1 christos 1362 1.1 christos /* Standard branch, trap mnemonics */ 1363 1.1 christos cond ("b", "ta", CONDA, F_UNBR), 1364 1.1 christos /* Alternative form (just for assembly, not for disassembly) */ 1365 1.1 christos cond ("ba", "t", CONDA, F_UNBR|F_ALIAS), 1366 1.1 christos 1367 1.1 christos cond ("bcc", "tcc", CONDCC, F_CONDBR), 1368 1.1 christos cond ("bcs", "tcs", CONDCS, F_CONDBR), 1369 1.1 christos cond ("be", "te", CONDE, F_CONDBR), 1370 1.1 christos cond ("beq", "teq", CONDE, F_CONDBR|F_ALIAS), 1371 1.1 christos cond ("bg", "tg", CONDG, F_CONDBR), 1372 1.1 christos cond ("bgt", "tgt", CONDG, F_CONDBR|F_ALIAS), 1373 1.1 christos cond ("bge", "tge", CONDGE, F_CONDBR), 1374 1.1 christos cond ("bgeu", "tgeu", CONDGEU, F_CONDBR|F_ALIAS), /* for cc */ 1375 1.1 christos cond ("bgu", "tgu", CONDGU, F_CONDBR), 1376 1.1 christos cond ("bl", "tl", CONDL, F_CONDBR), 1377 1.1 christos cond ("blt", "tlt", CONDL, F_CONDBR|F_ALIAS), 1378 1.1 christos cond ("ble", "tle", CONDLE, F_CONDBR), 1379 1.1 christos cond ("bleu", "tleu", CONDLEU, F_CONDBR), 1380 1.1 christos cond ("blu", "tlu", CONDLU, F_CONDBR|F_ALIAS), /* for cs */ 1381 1.1 christos cond ("bn", "tn", CONDN, F_CONDBR), 1382 1.1 christos cond ("bne", "tne", CONDNE, F_CONDBR), 1383 1.1 christos cond ("bneg", "tneg", CONDNEG, F_CONDBR), 1384 1.1 christos cond ("bnz", "tnz", CONDNZ, F_CONDBR|F_ALIAS), /* for ne */ 1385 1.1 christos cond ("bpos", "tpos", CONDPOS, F_CONDBR), 1386 1.1 christos cond ("bvc", "tvc", CONDVC, F_CONDBR), 1387 1.1 christos cond ("bvs", "tvs", CONDVS, F_CONDBR), 1388 1.1 christos cond ("bz", "tz", CONDZ, F_CONDBR|F_ALIAS), /* for e */ 1389 1.1 christos 1390 1.1 christos #undef cond 1391 1.1 christos #undef br 1392 1.1 christos #undef brr /* v9 */ 1393 1.1 christos #undef tr 1394 1.3 christos 1395 1.3 christos #define brr(opcode, mask, lose, flags) /* v9 */ \ 1396 1.3 christos { opcode, (mask)|BPRED, ANNUL|(lose), "1,k", F_DELAYED|(flags), 0, 0, v9 }, \ 1397 1.3 christos { opcode, (mask)|BPRED, ANNUL|(lose), ",T 1,k", F_DELAYED|(flags), 0, 0, v9 }, \ 1398 1.3 christos { opcode, (mask)|BPRED|ANNUL, (lose), ",a 1,k", F_DELAYED|(flags), 0, 0, v9 }, \ 1399 1.3 christos { opcode, (mask)|BPRED|ANNUL, (lose), ",a,T 1,k", F_DELAYED|(flags), 0, 0, v9 }, \ 1400 1.1 christos { opcode, (mask), ANNUL|BPRED|(lose), ",N 1,k", F_DELAYED|(flags), 0, 0, v9 }, \ 1401 1.1 christos { opcode, (mask)|ANNUL, BPRED|(lose), ",a,N 1,k", F_DELAYED|(flags), 0, 0, v9 } 1402 1.1 christos 1403 1.1 christos #define condr(bop, mask, flags) /* v9 */ \ 1404 1.1 christos brr(bop, F2(0, 3)|COND(mask), F2(~0, ~3)|COND(~(mask)), (flags)) /* v9 */ 1405 1.1 christos 1406 1.1 christos /* v9 */ condr("brnz", 0x5, F_CONDBR), 1407 1.1 christos /* v9 */ condr("brz", 0x1, F_CONDBR), 1408 1.1 christos /* v9 */ condr("brgez", 0x7, F_CONDBR), 1409 1.1 christos /* v9 */ condr("brlz", 0x3, F_CONDBR), 1410 1.1 christos /* v9 */ condr("brlez", 0x2, F_CONDBR), 1411 1.1 christos /* v9 */ condr("brgz", 0x6, F_CONDBR), 1412 1.1 christos 1413 1.6 christos #define cbcond(cop, cmask, flgs) \ 1414 1.1 christos { "cw" cop, F2(0, 3)|CBCOND(cmask)|F3I(0),F2(~0,~3)|CBCOND(~(cmask))|F3I(~0)|CBCOND_XCC, \ 1415 1.6 christos "1,2,=", flgs, HWCAP_CBCOND, 0, v9e}, \ 1416 1.1 christos { "cw" cop, F2(0, 3)|CBCOND(cmask)|F3I(1),F2(~0,~3)|CBCOND(~(cmask))|F3I(~1)|CBCOND_XCC, \ 1417 1.6 christos "1,X,=", flgs, HWCAP_CBCOND, 0, v9e}, \ 1418 1.1 christos { "cx" cop, F2(0, 3)|CBCOND(cmask)|F3I(0)|CBCOND_XCC,F2(~0,~3)|CBCOND(~(cmask))|F3I(~0), \ 1419 1.6 christos "1,2,=", flgs, HWCAP_CBCOND, 0, v9e}, \ 1420 1.1 christos { "cx" cop, F2(0, 3)|CBCOND(cmask)|F3I(1)|CBCOND_XCC,F2(~0,~3)|CBCOND(~(cmask))|F3I(~1), \ 1421 1.1 christos "1,X,=", flgs, HWCAP_CBCOND, 0, v9e}, 1422 1.1 christos 1423 1.1 christos cbcond("be", 0x09, F_CONDBR) 1424 1.1 christos cbcond("bz", 0x09, F_CONDBR|F_ALIAS) 1425 1.1 christos cbcond("ble", 0x0a, F_CONDBR) 1426 1.1 christos cbcond("bl", 0x0b, F_CONDBR) 1427 1.1 christos cbcond("bleu", 0x0c, F_CONDBR) 1428 1.1 christos cbcond("bcs", 0x0d, F_CONDBR) 1429 1.1 christos cbcond("blu", 0x0d, F_CONDBR|F_ALIAS) 1430 1.1 christos cbcond("bneg", 0x0e, F_CONDBR) 1431 1.1 christos cbcond("bvs", 0x0f, F_CONDBR) 1432 1.1 christos cbcond("bne", 0x19, F_CONDBR) 1433 1.1 christos cbcond("bnz", 0x19, F_CONDBR|F_ALIAS) 1434 1.1 christos cbcond("bg", 0x1a, F_CONDBR) 1435 1.1 christos cbcond("bge", 0x1b, F_CONDBR) 1436 1.1 christos cbcond("bgu", 0x1c, F_CONDBR) 1437 1.1 christos cbcond("bcc", 0x1d, F_CONDBR) 1438 1.1 christos cbcond("bgeu", 0x1d, F_CONDBR|F_ALIAS) 1439 1.1 christos cbcond("bpos", 0x1e, F_CONDBR) 1440 1.1 christos cbcond("bvc", 0x1f, F_CONDBR) 1441 1.1 christos 1442 1.1 christos #undef cbcond 1443 1.1 christos #undef condr /* v9 */ 1444 1.1 christos #undef brr /* v9 */ 1445 1.3 christos 1446 1.3 christos #define movr(opcode, mask, flags) /* v9 */ \ 1447 1.1 christos { opcode, F3(2, 0x2f, 0)|RCOND(mask), F3(~2, ~0x2f, ~0)|RCOND(~(mask)), "1,2,d", (flags), 0, 0, v9 }, \ 1448 1.1 christos { opcode, F3(2, 0x2f, 1)|RCOND(mask), F3(~2, ~0x2f, ~1)|RCOND(~(mask)), "1,j,d", (flags), 0, 0, v9 } 1449 1.3 christos 1450 1.1 christos #define fmrrs(opcode, mask, lose, flags) /* v9 */ \ 1451 1.3 christos { opcode, (mask), (lose), "1,f,g", (flags) | F_FLOAT, 0, 0, v9 } 1452 1.1 christos #define fmrrd(opcode, mask, lose, flags) /* v9 */ \ 1453 1.3 christos { opcode, (mask), (lose), "1,B,H", (flags) | F_FLOAT, 0, 0, v9 } 1454 1.1 christos #define fmrrq(opcode, mask, lose, flags) /* v9 */ \ 1455 1.1 christos { opcode, (mask), (lose), "1,R,J", (flags) | F_FLOAT, 0, 0, v9 } 1456 1.1 christos 1457 1.1 christos #define fmovrs(mop, mask, flags) /* v9 */ \ 1458 1.1 christos fmrrs(mop, F3(2, 0x35, 0)|OPF_LOW5(5)|RCOND(mask), F3(~2, ~0x35, 0)|OPF_LOW5(~5)|RCOND(~(mask)), (flags)) /* v9 */ 1459 1.1 christos #define fmovrd(mop, mask, flags) /* v9 */ \ 1460 1.1 christos fmrrd(mop, F3(2, 0x35, 0)|OPF_LOW5(6)|RCOND(mask), F3(~2, ~0x35, 0)|OPF_LOW5(~6)|RCOND(~(mask)), (flags)) /* v9 */ 1461 1.1 christos #define fmovrq(mop, mask, flags) /* v9 */ \ 1462 1.1 christos fmrrq(mop, F3(2, 0x35, 0)|OPF_LOW5(7)|RCOND(mask), F3(~2, ~0x35, 0)|OPF_LOW5(~7)|RCOND(~(mask)), (flags)) /* v9 */ 1463 1.1 christos 1464 1.1 christos /* v9 */ movr("movrne", 0x5, 0), 1465 1.1 christos /* v9 */ movr("movre", 0x1, 0), 1466 1.1 christos /* v9 */ movr("movrgez", 0x7, 0), 1467 1.1 christos /* v9 */ movr("movrlz", 0x3, 0), 1468 1.1 christos /* v9 */ movr("movrlez", 0x2, 0), 1469 1.1 christos /* v9 */ movr("movrgz", 0x6, 0), 1470 1.1 christos /* v9 */ movr("movrnz", 0x5, F_ALIAS), 1471 1.1 christos /* v9 */ movr("movrz", 0x1, F_ALIAS), 1472 1.1 christos 1473 1.1 christos /* v9 */ fmovrs("fmovrsne", 0x5, 0), 1474 1.1 christos /* v9 */ fmovrs("fmovrse", 0x1, 0), 1475 1.1 christos /* v9 */ fmovrs("fmovrsgez", 0x7, 0), 1476 1.1 christos /* v9 */ fmovrs("fmovrslz", 0x3, 0), 1477 1.1 christos /* v9 */ fmovrs("fmovrslez", 0x2, 0), 1478 1.1 christos /* v9 */ fmovrs("fmovrsgz", 0x6, 0), 1479 1.1 christos /* v9 */ fmovrs("fmovrsnz", 0x5, F_ALIAS), 1480 1.1 christos /* v9 */ fmovrs("fmovrsz", 0x1, F_ALIAS), 1481 1.1 christos 1482 1.1 christos /* v9 */ fmovrd("fmovrdne", 0x5, 0), 1483 1.1 christos /* v9 */ fmovrd("fmovrde", 0x1, 0), 1484 1.1 christos /* v9 */ fmovrd("fmovrdgez", 0x7, 0), 1485 1.1 christos /* v9 */ fmovrd("fmovrdlz", 0x3, 0), 1486 1.1 christos /* v9 */ fmovrd("fmovrdlez", 0x2, 0), 1487 1.1 christos /* v9 */ fmovrd("fmovrdgz", 0x6, 0), 1488 1.1 christos /* v9 */ fmovrd("fmovrdnz", 0x5, F_ALIAS), 1489 1.1 christos /* v9 */ fmovrd("fmovrdz", 0x1, F_ALIAS), 1490 1.1 christos 1491 1.1 christos /* v9 */ fmovrq("fmovrqne", 0x5, 0), 1492 1.1 christos /* v9 */ fmovrq("fmovrqe", 0x1, 0), 1493 1.1 christos /* v9 */ fmovrq("fmovrqgez", 0x7, 0), 1494 1.1 christos /* v9 */ fmovrq("fmovrqlz", 0x3, 0), 1495 1.1 christos /* v9 */ fmovrq("fmovrqlez", 0x2, 0), 1496 1.1 christos /* v9 */ fmovrq("fmovrqgz", 0x6, 0), 1497 1.1 christos /* v9 */ fmovrq("fmovrqnz", 0x5, F_ALIAS), 1498 1.1 christos /* v9 */ fmovrq("fmovrqz", 0x1, F_ALIAS), 1499 1.1 christos 1500 1.1 christos #undef movr /* v9 */ 1501 1.1 christos #undef fmovr /* v9 */ 1502 1.1 christos #undef fmrr /* v9 */ 1503 1.3 christos 1504 1.3 christos #define movicc(opcode, cond, flags) /* v9 */ \ 1505 1.3 christos { opcode, F3(2, 0x2c, 0)|MCOND(cond,1)|ICC, F3(~2, ~0x2c, ~0)|MCOND(~cond,~1)|XCC|(1<<11), "z,2,d", flags, 0, 0, v9 }, \ 1506 1.3 christos { opcode, F3(2, 0x2c, 1)|MCOND(cond,1)|ICC, F3(~2, ~0x2c, ~1)|MCOND(~cond,~1)|XCC|(1<<11), "z,I,d", flags, 0, 0, v9 }, \ 1507 1.1 christos { opcode, F3(2, 0x2c, 0)|MCOND(cond,1)|XCC, F3(~2, ~0x2c, ~0)|MCOND(~cond,~1)|(1<<11), "Z,2,d", flags, 0, 0, v9 }, \ 1508 1.1 christos { opcode, F3(2, 0x2c, 1)|MCOND(cond,1)|XCC, F3(~2, ~0x2c, ~1)|MCOND(~cond,~1)|(1<<11), "Z,I,d", flags, 0, 0, v9 } 1509 1.3 christos 1510 1.3 christos #define movfcc(opcode, fcond, flags) /* v9 */ \ 1511 1.3 christos { opcode, F3(2, 0x2c, 0)|FCC(0)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~0)|F3(~2, ~0x2c, ~0), "6,2,d", flags, 0, 0, v9 }, \ 1512 1.3 christos { opcode, F3(2, 0x2c, 1)|FCC(0)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~0)|F3(~2, ~0x2c, ~1), "6,I,d", flags, 0, 0, v9 }, \ 1513 1.3 christos { opcode, F3(2, 0x2c, 0)|FCC(1)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~1)|F3(~2, ~0x2c, ~0), "7,2,d", flags, 0, 0, v9 }, \ 1514 1.3 christos { opcode, F3(2, 0x2c, 1)|FCC(1)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~1)|F3(~2, ~0x2c, ~1), "7,I,d", flags, 0, 0, v9 }, \ 1515 1.3 christos { opcode, F3(2, 0x2c, 0)|FCC(2)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~2)|F3(~2, ~0x2c, ~0), "8,2,d", flags, 0, 0, v9 }, \ 1516 1.3 christos { opcode, F3(2, 0x2c, 1)|FCC(2)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~2)|F3(~2, ~0x2c, ~1), "8,I,d", flags, 0, 0, v9 }, \ 1517 1.1 christos { opcode, F3(2, 0x2c, 0)|FCC(3)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~3)|F3(~2, ~0x2c, ~0), "9,2,d", flags, 0, 0, v9 }, \ 1518 1.1 christos { opcode, F3(2, 0x2c, 1)|FCC(3)|MCOND(fcond,0), MCOND(~fcond,~0)|FCC(~3)|F3(~2, ~0x2c, ~1), "9,I,d", flags, 0, 0, v9 } 1519 1.1 christos 1520 1.1 christos #define movcc(opcode, cond, fcond, flags) /* v9 */ \ 1521 1.1 christos movfcc (opcode, fcond, flags), /* v9 */ \ 1522 1.1 christos movicc (opcode, cond, flags) /* v9 */ 1523 1.1 christos 1524 1.1 christos /* v9 */ movcc ("mova", CONDA, FCONDA, 0), 1525 1.1 christos /* v9 */ movicc ("movcc", CONDCC, 0), 1526 1.1 christos /* v9 */ movicc ("movgeu", CONDGEU, F_ALIAS), 1527 1.1 christos /* v9 */ movicc ("movcs", CONDCS, 0), 1528 1.1 christos /* v9 */ movicc ("movlu", CONDLU, F_ALIAS), 1529 1.1 christos /* v9 */ movcc ("move", CONDE, FCONDE, 0), 1530 1.1 christos /* v9 */ movcc ("movg", CONDG, FCONDG, 0), 1531 1.1 christos /* v9 */ movcc ("movge", CONDGE, FCONDGE, 0), 1532 1.1 christos /* v9 */ movicc ("movgu", CONDGU, 0), 1533 1.1 christos /* v9 */ movcc ("movl", CONDL, FCONDL, 0), 1534 1.1 christos /* v9 */ movcc ("movle", CONDLE, FCONDLE, 0), 1535 1.1 christos /* v9 */ movicc ("movleu", CONDLEU, 0), 1536 1.1 christos /* v9 */ movfcc ("movlg", FCONDLG, 0), 1537 1.1 christos /* v9 */ movcc ("movn", CONDN, FCONDN, 0), 1538 1.1 christos /* v9 */ movcc ("movne", CONDNE, FCONDNE, 0), 1539 1.1 christos /* v9 */ movicc ("movneg", CONDNEG, 0), 1540 1.1 christos /* v9 */ movcc ("movnz", CONDNZ, FCONDNZ, F_ALIAS), 1541 1.1 christos /* v9 */ movfcc ("movo", FCONDO, 0), 1542 1.1 christos /* v9 */ movicc ("movpos", CONDPOS, 0), 1543 1.1 christos /* v9 */ movfcc ("movu", FCONDU, 0), 1544 1.1 christos /* v9 */ movfcc ("movue", FCONDUE, 0), 1545 1.1 christos /* v9 */ movfcc ("movug", FCONDUG, 0), 1546 1.1 christos /* v9 */ movfcc ("movuge", FCONDUGE, 0), 1547 1.1 christos /* v9 */ movfcc ("movul", FCONDUL, 0), 1548 1.1 christos /* v9 */ movfcc ("movule", FCONDULE, 0), 1549 1.1 christos /* v9 */ movicc ("movvc", CONDVC, 0), 1550 1.1 christos /* v9 */ movicc ("movvs", CONDVS, 0), 1551 1.1 christos /* v9 */ movcc ("movz", CONDZ, FCONDZ, F_ALIAS), 1552 1.1 christos 1553 1.1 christos #undef movicc /* v9 */ 1554 1.1 christos #undef movfcc /* v9 */ 1555 1.1 christos #undef movcc /* v9 */ 1556 1.1 christos 1557 1.1 christos #define FM_SF 1 /* v9 - values for fpsize */ 1558 1.1 christos #define FM_DF 2 /* v9 */ 1559 1.1 christos #define FM_QF 3 /* v9 */ 1560 1.3 christos 1561 1.3 christos #define fmoviccx(opcode, fpsize, args, cond, flags) /* v9 */ \ 1562 1.1 christos { opcode, F3F(2, 0x35, 0x100+fpsize)|MCOND(cond,0), F3F(~2, ~0x35, ~(0x100+fpsize))|MCOND(~cond,~0), "z," args, flags, 0, 0, v9 }, \ 1563 1.1 christos { opcode, F3F(2, 0x35, 0x180+fpsize)|MCOND(cond,0), F3F(~2, ~0x35, ~(0x180+fpsize))|MCOND(~cond,~0), "Z," args, flags, 0, 0, v9 } 1564 1.3 christos 1565 1.3 christos #define fmovfccx(opcode, fpsize, args, fcond, flags) /* v9 */ \ 1566 1.3 christos { opcode, F3F(2, 0x35, 0x000+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x000+fpsize))|MCOND(~fcond,~0), "6," args, flags, 0, 0, v9 }, \ 1567 1.3 christos { opcode, F3F(2, 0x35, 0x040+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x040+fpsize))|MCOND(~fcond,~0), "7," args, flags, 0, 0, v9 }, \ 1568 1.1 christos { opcode, F3F(2, 0x35, 0x080+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x080+fpsize))|MCOND(~fcond,~0), "8," args, flags, 0, 0, v9 }, \ 1569 1.1 christos { opcode, F3F(2, 0x35, 0x0c0+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x0c0+fpsize))|MCOND(~fcond,~0), "9," args, flags, 0, 0, v9 } 1570 1.1 christos 1571 1.3 christos /* FIXME: use fmovicc/fmovfcc? */ /* v9 */ 1572 1.3 christos #define fmovccx(opcode, fpsize, args, cond, fcond, flags) /* v9 */ \ 1573 1.3 christos { opcode, F3F(2, 0x35, 0x100+fpsize)|MCOND(cond,0), F3F(~2, ~0x35, ~(0x100+fpsize))|MCOND(~cond,~0), "z," args, flags | F_FLOAT, 0, 0, v9 }, \ 1574 1.3 christos { opcode, F3F(2, 0x35, 0x000+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x000+fpsize))|MCOND(~fcond,~0), "6," args, flags | F_FLOAT, 0, 0, v9 }, \ 1575 1.3 christos { opcode, F3F(2, 0x35, 0x180+fpsize)|MCOND(cond,0), F3F(~2, ~0x35, ~(0x180+fpsize))|MCOND(~cond,~0), "Z," args, flags | F_FLOAT, 0, 0, v9 }, \ 1576 1.3 christos { opcode, F3F(2, 0x35, 0x040+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x040+fpsize))|MCOND(~fcond,~0), "7," args, flags | F_FLOAT, 0, 0, v9 }, \ 1577 1.1 christos { opcode, F3F(2, 0x35, 0x080+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x080+fpsize))|MCOND(~fcond,~0), "8," args, flags | F_FLOAT, 0, 0, v9 }, \ 1578 1.1 christos { opcode, F3F(2, 0x35, 0x0c0+fpsize)|MCOND(fcond,0), F3F(~2, ~0x35, ~(0x0c0+fpsize))|MCOND(~fcond,~0), "9," args, flags | F_FLOAT, 0, 0, v9 } 1579 1.1 christos 1580 1.1 christos #define fmovicc(suffix, cond, flags) /* v9 */ \ 1581 1.1 christos fmoviccx("fmovd" suffix, FM_DF, "B,H", cond, flags), \ 1582 1.1 christos fmoviccx("fmovq" suffix, FM_QF, "R,J", cond, flags), \ 1583 1.1 christos fmoviccx("fmovs" suffix, FM_SF, "f,g", cond, flags) 1584 1.1 christos 1585 1.1 christos #define fmovfcc(suffix, fcond, flags) /* v9 */ \ 1586 1.1 christos fmovfccx("fmovd" suffix, FM_DF, "B,H", fcond, flags), \ 1587 1.1 christos fmovfccx("fmovq" suffix, FM_QF, "R,J", fcond, flags), \ 1588 1.1 christos fmovfccx("fmovs" suffix, FM_SF, "f,g", fcond, flags) 1589 1.1 christos 1590 1.1 christos #define fmovcc(suffix, cond, fcond, flags) /* v9 */ \ 1591 1.1 christos fmovccx("fmovd" suffix, FM_DF, "B,H", cond, fcond, flags), \ 1592 1.1 christos fmovccx("fmovq" suffix, FM_QF, "R,J", cond, fcond, flags), \ 1593 1.1 christos fmovccx("fmovs" suffix, FM_SF, "f,g", cond, fcond, flags) 1594 1.1 christos 1595 1.1 christos /* v9 */ fmovcc ("a", CONDA, FCONDA, 0), 1596 1.1 christos /* v9 */ fmovicc ("cc", CONDCC, 0), 1597 1.1 christos /* v9 */ fmovicc ("cs", CONDCS, 0), 1598 1.1 christos /* v9 */ fmovcc ("e", CONDE, FCONDE, 0), 1599 1.1 christos /* v9 */ fmovcc ("g", CONDG, FCONDG, 0), 1600 1.1 christos /* v9 */ fmovcc ("ge", CONDGE, FCONDGE, 0), 1601 1.1 christos /* v9 */ fmovicc ("geu", CONDGEU, F_ALIAS), 1602 1.1 christos /* v9 */ fmovicc ("gu", CONDGU, 0), 1603 1.1 christos /* v9 */ fmovcc ("l", CONDL, FCONDL, 0), 1604 1.1 christos /* v9 */ fmovcc ("le", CONDLE, FCONDLE, 0), 1605 1.1 christos /* v9 */ fmovicc ("leu", CONDLEU, 0), 1606 1.1 christos /* v9 */ fmovfcc ("lg", FCONDLG, 0), 1607 1.1 christos /* v9 */ fmovicc ("lu", CONDLU, F_ALIAS), 1608 1.1 christos /* v9 */ fmovcc ("n", CONDN, FCONDN, 0), 1609 1.1 christos /* v9 */ fmovcc ("ne", CONDNE, FCONDNE, 0), 1610 1.1 christos /* v9 */ fmovicc ("neg", CONDNEG, 0), 1611 1.1 christos /* v9 */ fmovcc ("nz", CONDNZ, FCONDNZ, F_ALIAS), 1612 1.1 christos /* v9 */ fmovfcc ("o", FCONDO, 0), 1613 1.1 christos /* v9 */ fmovicc ("pos", CONDPOS, 0), 1614 1.1 christos /* v9 */ fmovfcc ("u", FCONDU, 0), 1615 1.1 christos /* v9 */ fmovfcc ("ue", FCONDUE, 0), 1616 1.1 christos /* v9 */ fmovfcc ("ug", FCONDUG, 0), 1617 1.1 christos /* v9 */ fmovfcc ("uge", FCONDUGE, 0), 1618 1.1 christos /* v9 */ fmovfcc ("ul", FCONDUL, 0), 1619 1.1 christos /* v9 */ fmovfcc ("ule", FCONDULE, 0), 1620 1.1 christos /* v9 */ fmovicc ("vc", CONDVC, 0), 1621 1.1 christos /* v9 */ fmovicc ("vs", CONDVS, 0), 1622 1.1 christos /* v9 */ fmovcc ("z", CONDZ, FCONDZ, F_ALIAS), 1623 1.1 christos 1624 1.1 christos #undef fmoviccx /* v9 */ 1625 1.1 christos #undef fmovfccx /* v9 */ 1626 1.1 christos #undef fmovccx /* v9 */ 1627 1.1 christos #undef fmovicc /* v9 */ 1628 1.1 christos #undef fmovfcc /* v9 */ 1629 1.1 christos #undef fmovcc /* v9 */ 1630 1.1 christos #undef FM_DF /* v9 */ 1631 1.1 christos #undef FM_QF /* v9 */ 1632 1.1 christos #undef FM_SF /* v9 */ 1633 1.1 christos 1634 1.3 christos /* Coprocessor branches. */ 1635 1.3 christos #define CBR(opcode, mask, lose, flags, arch) \ 1636 1.1 christos { opcode, (mask), ANNUL | (lose), "l", flags | F_DELAYED, 0, 0, arch }, \ 1637 1.1 christos { opcode, (mask) | ANNUL, (lose), ",a l", flags | F_DELAYED, 0, 0, arch } 1638 1.1 christos 1639 1.3 christos /* Floating point branches. */ 1640 1.3 christos #define FBR(opcode, mask, lose, flags) \ 1641 1.1 christos { opcode, (mask), ANNUL | (lose), "l", flags | F_DELAYED | F_FBR, 0, 0, v6 }, \ 1642 1.1 christos { opcode, (mask) | ANNUL, (lose), ",a l", flags | F_DELAYED | F_FBR, 0, 0, v6 } 1643 1.1 christos 1644 1.3 christos /* V9 extended floating point branches. */ 1645 1.3 christos #define FBRX(opcode, mask, lose, flags) /* v9 */ \ 1646 1.3 christos { opcode, FBFCC(0)|(mask)|BPRED, ANNUL|FBFCC(~0)|(lose), "6,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1647 1.3 christos { opcode, FBFCC(0)|(mask)|BPRED, ANNUL|FBFCC(~0)|(lose), ",T 6,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1648 1.3 christos { opcode, FBFCC(0)|(mask)|BPRED|ANNUL, FBFCC(~0)|(lose), ",a 6,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1649 1.3 christos { opcode, FBFCC(0)|(mask)|BPRED|ANNUL, FBFCC(~0)|(lose), ",a,T 6,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1650 1.3 christos { opcode, FBFCC(0)|(mask), ANNUL|BPRED|FBFCC(~0)|(lose), ",N 6,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1651 1.3 christos { opcode, FBFCC(0)|(mask)|ANNUL, BPRED|FBFCC(~0)|(lose), ",a,N 6,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1652 1.3 christos { opcode, FBFCC(1)|(mask)|BPRED, ANNUL|FBFCC(~1)|(lose), "7,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1653 1.3 christos { opcode, FBFCC(1)|(mask)|BPRED, ANNUL|FBFCC(~1)|(lose), ",T 7,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1654 1.3 christos { opcode, FBFCC(1)|(mask)|BPRED|ANNUL, FBFCC(~1)|(lose), ",a 7,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1655 1.3 christos { opcode, FBFCC(1)|(mask)|BPRED|ANNUL, FBFCC(~1)|(lose), ",a,T 7,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1656 1.3 christos { opcode, FBFCC(1)|(mask), ANNUL|BPRED|FBFCC(~1)|(lose), ",N 7,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1657 1.3 christos { opcode, FBFCC(1)|(mask)|ANNUL, BPRED|FBFCC(~1)|(lose), ",a,N 7,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1658 1.3 christos { opcode, FBFCC(2)|(mask)|BPRED, ANNUL|FBFCC(~2)|(lose), "8,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1659 1.3 christos { opcode, FBFCC(2)|(mask)|BPRED, ANNUL|FBFCC(~2)|(lose), ",T 8,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1660 1.3 christos { opcode, FBFCC(2)|(mask)|BPRED|ANNUL, FBFCC(~2)|(lose), ",a 8,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1661 1.3 christos { opcode, FBFCC(2)|(mask)|BPRED|ANNUL, FBFCC(~2)|(lose), ",a,T 8,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1662 1.3 christos { opcode, FBFCC(2)|(mask), ANNUL|BPRED|FBFCC(~2)|(lose), ",N 8,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1663 1.3 christos { opcode, FBFCC(2)|(mask)|ANNUL, BPRED|FBFCC(~2)|(lose), ",a,N 8,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1664 1.3 christos { opcode, FBFCC(3)|(mask)|BPRED, ANNUL|FBFCC(~3)|(lose), "9,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1665 1.3 christos { opcode, FBFCC(3)|(mask)|BPRED, ANNUL|FBFCC(~3)|(lose), ",T 9,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1666 1.3 christos { opcode, FBFCC(3)|(mask)|BPRED|ANNUL, FBFCC(~3)|(lose), ",a 9,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1667 1.3 christos { opcode, FBFCC(3)|(mask)|BPRED|ANNUL, FBFCC(~3)|(lose), ",a,T 9,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1668 1.1 christos { opcode, FBFCC(3)|(mask), ANNUL|BPRED|FBFCC(~3)|(lose), ",N 9,G", flags|F_DELAYED|F_FBR, 0, 0, v9 }, \ 1669 1.1 christos { opcode, FBFCC(3)|(mask)|ANNUL, BPRED|FBFCC(~3)|(lose), ",a,N 9,G", flags|F_DELAYED|F_FBR, 0, 0, v9 } 1670 1.1 christos 1671 1.1 christos /* v9: We must put `FBRX' before `FBR', to ensure that we never match 1672 1.1 christos v9: something against an expression unless it is an expression. Otherwise, 1673 1.1 christos v9: we end up with undefined symbol tables entries, because they get added, 1674 1.1 christos v9: but are not deleted if the pattern fails to match. */ 1675 1.1 christos 1676 1.1 christos #define CONDFC(fop, cop, mask, flags) \ 1677 1.1 christos FBRX(fop, F2(0, 5)|COND(mask), F2(~0, ~5)|COND(~(mask)), flags), /* v9 */ \ 1678 1.1 christos FBR(fop, F2(0, 6)|COND(mask), F2(~0, ~6)|COND(~(mask)), flags), \ 1679 1.1 christos CBR(cop, F2(0, 7)|COND(mask), F2(~0, ~7)|COND(~(mask)), flags, v6notlet) 1680 1.1 christos 1681 1.1 christos #define CONDFCL(fop, cop, mask, flags) \ 1682 1.1 christos FBRX(fop, F2(0, 5)|COND(mask), F2(~0, ~5)|COND(~(mask)), flags), /* v9 */ \ 1683 1.1 christos FBR(fop, F2(0, 6)|COND(mask), F2(~0, ~6)|COND(~(mask)), flags), \ 1684 1.1 christos CBR(cop, F2(0, 7)|COND(mask), F2(~0, ~7)|COND(~(mask)), flags, v6) 1685 1.1 christos 1686 1.1 christos #define CONDF(fop, mask, flags) \ 1687 1.1 christos FBRX(fop, F2(0, 5)|COND(mask), F2(~0, ~5)|COND(~(mask)), flags), /* v9 */ \ 1688 1.1 christos FBR(fop, F2(0, 6)|COND(mask), F2(~0, ~6)|COND(~(mask)), flags) 1689 1.1 christos 1690 1.1 christos CONDFC ("fb", "cb", 0x8, F_UNBR), 1691 1.1 christos CONDFCL ("fba", "cba", 0x8, F_UNBR|F_ALIAS), 1692 1.1 christos CONDFC ("fbe", "cb0", 0x9, F_CONDBR), 1693 1.1 christos CONDF ("fbz", 0x9, F_CONDBR|F_ALIAS), 1694 1.1 christos CONDFC ("fbg", "cb2", 0x6, F_CONDBR), 1695 1.1 christos CONDFC ("fbge", "cb02", 0xb, F_CONDBR), 1696 1.1 christos CONDFC ("fbl", "cb1", 0x4, F_CONDBR), 1697 1.1 christos CONDFC ("fble", "cb01", 0xd, F_CONDBR), 1698 1.1 christos CONDFC ("fblg", "cb12", 0x2, F_CONDBR), 1699 1.1 christos CONDFCL ("fbn", "cbn", 0x0, F_UNBR), 1700 1.1 christos CONDFC ("fbne", "cb123", 0x1, F_CONDBR), 1701 1.1 christos CONDF ("fbnz", 0x1, F_CONDBR|F_ALIAS), 1702 1.1 christos CONDFC ("fbo", "cb012", 0xf, F_CONDBR), 1703 1.1 christos CONDFC ("fbu", "cb3", 0x7, F_CONDBR), 1704 1.1 christos CONDFC ("fbue", "cb03", 0xa, F_CONDBR), 1705 1.1 christos CONDFC ("fbug", "cb23", 0x5, F_CONDBR), 1706 1.1 christos CONDFC ("fbuge", "cb023", 0xc, F_CONDBR), 1707 1.1 christos CONDFC ("fbul", "cb13", 0x3, F_CONDBR), 1708 1.1 christos CONDFC ("fbule", "cb013", 0xe, F_CONDBR), 1709 1.1 christos 1710 1.1 christos #undef CONDFC 1711 1.1 christos #undef CONDFCL 1712 1.1 christos #undef CONDF 1713 1.1 christos #undef CBR 1714 1.1 christos #undef FBR 1715 1.3 christos #undef FBRX /* v9 */ 1716 1.3 christos 1717 1.3 christos { "jmp", F3(2, 0x38, 0), F3(~2, ~0x38, ~0)|RD_G0|ASI(~0), "1+2", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+rs2,%g0 */ 1718 1.3 christos { "jmp", F3(2, 0x38, 0), F3(~2, ~0x38, ~0)|RD_G0|ASI_RS2(~0), "1", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+%g0,%g0 */ 1719 1.3 christos { "jmp", F3(2, 0x38, 1), F3(~2, ~0x38, ~1)|RD_G0, "1+i", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+i,%g0 */ 1720 1.3 christos { "jmp", F3(2, 0x38, 1), F3(~2, ~0x38, ~1)|RD_G0, "i+1", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl i+rs1,%g0 */ 1721 1.3 christos { "jmp", F3(2, 0x38, 1), F3(~2, ~0x38, ~1)|RD_G0|RS1_G0, "i", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl %g0+i,%g0 */ 1722 1.3 christos { "jmp", F3(2, 0x38, 1), F3(~2, ~0x38, ~1)|RD_G0|SIMM13(~0), "1", F_UNBR|F_DELAYED, 0, 0, v6 }, /* jmpl rs1+0,%g0 */ 1723 1.3 christos 1724 1.3 christos { "nop", F2(0, 4), 0xfeffffff, "", 0, 0, 0, v6 }, /* sethi 0, %g0 */ 1725 1.3 christos 1726 1.3 christos { "set", F2(0x0, 0x4), F2(~0x0, ~0x4), "S0,d", F_ALIAS, 0, 0, v6 }, 1727 1.3 christos { "setuw", F2(0x0, 0x4), F2(~0x0, ~0x4), "S0,d", F_ALIAS, 0, 0, v9 }, 1728 1.3 christos { "setsw", F2(0x0, 0x4), F2(~0x0, ~0x4), "S0,d", F_ALIAS, 0, 0, v9 }, 1729 1.3 christos { "setx", F2(0x0, 0x4), F2(~0x0, ~0x4), "S0,1,d", F_ALIAS, 0, 0, v9 }, 1730 1.3 christos 1731 1.3 christos { "sethi", F2(0x0, 0x4), F2(~0x0, ~0x4), "h,d", 0, 0, 0, v6 }, 1732 1.3 christos 1733 1.3 christos { "taddcc", F3(2, 0x20, 0), F3(~2, ~0x20, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1734 1.3 christos { "taddcc", F3(2, 0x20, 1), F3(~2, ~0x20, ~1), "1,i,d", 0, 0, 0, v6 }, 1735 1.3 christos { "taddcc", F3(2, 0x20, 1), F3(~2, ~0x20, ~1), "i,1,d", 0, 0, 0, v6 }, 1736 1.3 christos { "taddcctv", F3(2, 0x22, 0), F3(~2, ~0x22, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1737 1.3 christos { "taddcctv", F3(2, 0x22, 1), F3(~2, ~0x22, ~1), "1,i,d", 0, 0, 0, v6 }, 1738 1.3 christos { "taddcctv", F3(2, 0x22, 1), F3(~2, ~0x22, ~1), "i,1,d", 0, 0, 0, v6 }, 1739 1.3 christos 1740 1.3 christos { "tsubcc", F3(2, 0x21, 0), F3(~2, ~0x21, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1741 1.3 christos { "tsubcc", F3(2, 0x21, 1), F3(~2, ~0x21, ~1), "1,i,d", 0, 0, 0, v6 }, 1742 1.1 christos { "tsubcctv", F3(2, 0x23, 0), F3(~2, ~0x23, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1743 1.3 christos { "tsubcctv", F3(2, 0x23, 1), F3(~2, ~0x23, ~1), "1,i,d", 0, 0, 0, v6 }, 1744 1.3 christos 1745 1.1 christos { "unimp", F2(0x0, 0x0), 0xffc00000, "n", 0, 0, 0, v6notv9 }, 1746 1.1 christos { "illtrap", F2(0, 0), F2(~0, ~0)|RD_G0, "n", 0, 0, 0, v9 }, 1747 1.3 christos 1748 1.3 christos /* This *is* a commutative instruction. */ 1749 1.3 christos { "xnor", F3(2, 0x07, 0), F3(~2, ~0x07, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1750 1.1 christos { "xnor", F3(2, 0x07, 1), F3(~2, ~0x07, ~1), "1,i,d", 0, 0, 0, v6 }, 1751 1.3 christos { "xnor", F3(2, 0x07, 1), F3(~2, ~0x07, ~1), "i,1,d", 0, 0, 0, v6 }, 1752 1.3 christos /* This *is* a commutative instruction. */ 1753 1.3 christos { "xnorcc", F3(2, 0x17, 0), F3(~2, ~0x17, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1754 1.3 christos { "xnorcc", F3(2, 0x17, 1), F3(~2, ~0x17, ~1), "1,i,d", 0, 0, 0, v6 }, 1755 1.3 christos { "xnorcc", F3(2, 0x17, 1), F3(~2, ~0x17, ~1), "i,1,d", 0, 0, 0, v6 }, 1756 1.3 christos { "xor", F3(2, 0x03, 0), F3(~2, ~0x03, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1757 1.3 christos { "xor", F3(2, 0x03, 1), F3(~2, ~0x03, ~1), "1,i,d", 0, 0, 0, v6 }, 1758 1.3 christos { "xor", F3(2, 0x03, 1), F3(~2, ~0x03, ~1), "i,1,d", 0, 0, 0, v6 }, 1759 1.3 christos { "xorcc", F3(2, 0x13, 0), F3(~2, ~0x13, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v6 }, 1760 1.1 christos { "xorcc", F3(2, 0x13, 1), F3(~2, ~0x13, ~1), "1,i,d", 0, 0, 0, v6 }, 1761 1.3 christos { "xorcc", F3(2, 0x13, 1), F3(~2, ~0x13, ~1), "i,1,d", 0, 0, 0, v6 }, 1762 1.3 christos 1763 1.1 christos { "not", F3(2, 0x07, 0), F3(~2, ~0x07, ~0)|ASI(~0), "1,d", F_ALIAS, 0, 0, v6 }, /* xnor rs1,%0,rd */ 1764 1.3 christos { "not", F3(2, 0x07, 0), F3(~2, ~0x07, ~0)|ASI(~0), "r", F_ALIAS, 0, 0, v6 }, /* xnor rd,%0,rd */ 1765 1.3 christos 1766 1.1 christos { "btog", F3(2, 0x03, 0), F3(~2, ~0x03, ~0)|ASI(~0), "2,r", F_ALIAS, 0, 0, v6 }, /* xor rd,rs2,rd */ 1767 1.1 christos { "btog", F3(2, 0x03, 1), F3(~2, ~0x03, ~1), "i,r", F_ALIAS, 0, 0, v6 }, /* xor rd,i,rd */ 1768 1.1 christos 1769 1.3 christos /* FPop1 and FPop2 are not instructions. Don't accept them. */ 1770 1.3 christos 1771 1.3 christos { "fdtoi", F3F(2, 0x34, 0x0d2), F3F(~2, ~0x34, ~0x0d2)|RS1_G0, "B,g", F_FLOAT, 0, 0, v6 }, 1772 1.3 christos { "fstoi", F3F(2, 0x34, 0x0d1), F3F(~2, ~0x34, ~0x0d1)|RS1_G0, "f,g", F_FLOAT, 0, 0, v6 }, 1773 1.3 christos { "fqtoi", F3F(2, 0x34, 0x0d3), F3F(~2, ~0x34, ~0x0d3)|RS1_G0, "R,g", F_FLOAT, 0, 0, v8 }, 1774 1.3 christos 1775 1.3 christos { "fdtox", F3F(2, 0x34, 0x082), F3F(~2, ~0x34, ~0x082)|RS1_G0, "B,H", F_FLOAT, 0, 0, v9 }, 1776 1.3 christos { "fstox", F3F(2, 0x34, 0x081), F3F(~2, ~0x34, ~0x081)|RS1_G0, "f,H", F_FLOAT, 0, 0, v9 }, 1777 1.3 christos { "fqtox", F3F(2, 0x34, 0x083), F3F(~2, ~0x34, ~0x083)|RS1_G0, "R,H", F_FLOAT, 0, 0, v9 }, 1778 1.3 christos 1779 1.3 christos { "fitod", F3F(2, 0x34, 0x0c8), F3F(~2, ~0x34, ~0x0c8)|RS1_G0, "f,H", F_FLOAT, 0, 0, v6 }, 1780 1.3 christos { "fitos", F3F(2, 0x34, 0x0c4), F3F(~2, ~0x34, ~0x0c4)|RS1_G0, "f,g", F_FLOAT, 0, 0, v6 }, 1781 1.3 christos { "fitoq", F3F(2, 0x34, 0x0cc), F3F(~2, ~0x34, ~0x0cc)|RS1_G0, "f,J", F_FLOAT, 0, 0, v8 }, 1782 1.3 christos 1783 1.3 christos { "fxtod", F3F(2, 0x34, 0x088), F3F(~2, ~0x34, ~0x088)|RS1_G0, "B,H", F_FLOAT, 0, 0, v9 }, 1784 1.3 christos { "fxtos", F3F(2, 0x34, 0x084), F3F(~2, ~0x34, ~0x084)|RS1_G0, "B,g", F_FLOAT, 0, 0, v9 }, 1785 1.3 christos { "fxtoq", F3F(2, 0x34, 0x08c), F3F(~2, ~0x34, ~0x08c)|RS1_G0, "B,J", F_FLOAT, 0, 0, v9 }, 1786 1.3 christos 1787 1.3 christos { "fdtoq", F3F(2, 0x34, 0x0ce), F3F(~2, ~0x34, ~0x0ce)|RS1_G0, "B,J", F_FLOAT, 0, 0, v8 }, 1788 1.3 christos { "fdtos", F3F(2, 0x34, 0x0c6), F3F(~2, ~0x34, ~0x0c6)|RS1_G0, "B,g", F_FLOAT, 0, 0, v6 }, 1789 1.3 christos { "fqtod", F3F(2, 0x34, 0x0cb), F3F(~2, ~0x34, ~0x0cb)|RS1_G0, "R,H", F_FLOAT, 0, 0, v8 }, 1790 1.3 christos { "fqtos", F3F(2, 0x34, 0x0c7), F3F(~2, ~0x34, ~0x0c7)|RS1_G0, "R,g", F_FLOAT, 0, 0, v8 }, 1791 1.3 christos { "fstod", F3F(2, 0x34, 0x0c9), F3F(~2, ~0x34, ~0x0c9)|RS1_G0, "f,H", F_FLOAT, 0, 0, v6 }, 1792 1.3 christos { "fstoq", F3F(2, 0x34, 0x0cd), F3F(~2, ~0x34, ~0x0cd)|RS1_G0, "f,J", F_FLOAT, 0, 0, v8 }, 1793 1.3 christos 1794 1.3 christos { "fdivd", F3F(2, 0x34, 0x04e), F3F(~2, ~0x34, ~0x04e), "v,B,H", F_FLOAT, 0, 0, v6 }, 1795 1.3 christos { "fdivq", F3F(2, 0x34, 0x04f), F3F(~2, ~0x34, ~0x04f), "V,R,J", F_FLOAT, 0, 0, v8 }, 1796 1.3 christos { "fdivx", F3F(2, 0x34, 0x04f), F3F(~2, ~0x34, ~0x04f), "V,R,J", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1797 1.3 christos { "fdivs", F3F(2, 0x34, 0x04d), F3F(~2, ~0x34, ~0x04d), "e,f,g", F_FLOAT, 0, 0, v6 }, 1798 1.3 christos { "fmuld", F3F(2, 0x34, 0x04a), F3F(~2, ~0x34, ~0x04a), "v,B,H", F_FLOAT, 0, 0, v6 }, 1799 1.3 christos { "fmulq", F3F(2, 0x34, 0x04b), F3F(~2, ~0x34, ~0x04b), "V,R,J", F_FLOAT, 0, 0, v8 }, 1800 1.3 christos { "fmulx", F3F(2, 0x34, 0x04b), F3F(~2, ~0x34, ~0x04b), "V,R,J", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1801 1.3 christos { "fmuls", F3F(2, 0x34, 0x049), F3F(~2, ~0x34, ~0x049), "e,f,g", F_FLOAT, 0, 0, v6 }, 1802 1.3 christos 1803 1.3 christos { "fdmulq", F3F(2, 0x34, 0x06e), F3F(~2, ~0x34, ~0x06e), "v,B,J", F_FLOAT, 0, 0, v8 }, 1804 1.3 christos { "fdmulx", F3F(2, 0x34, 0x06e), F3F(~2, ~0x34, ~0x06e), "v,B,J", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1805 1.3 christos { "fsmuld", F3F(2, 0x34, 0x069), F3F(~2, ~0x34, ~0x069), "e,f,H", F_FLOAT, HWCAP_FSMULD, 0, v8 }, 1806 1.3 christos 1807 1.3 christos { "fsqrtd", F3F(2, 0x34, 0x02a), F3F(~2, ~0x34, ~0x02a)|RS1_G0, "B,H", F_FLOAT, 0, 0, v7 }, 1808 1.3 christos { "fsqrtq", F3F(2, 0x34, 0x02b), F3F(~2, ~0x34, ~0x02b)|RS1_G0, "R,J", F_FLOAT, 0, 0, v8 }, 1809 1.3 christos { "fsqrtx", F3F(2, 0x34, 0x02b), F3F(~2, ~0x34, ~0x02b)|RS1_G0, "R,J", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1810 1.3 christos { "fsqrts", F3F(2, 0x34, 0x029), F3F(~2, ~0x34, ~0x029)|RS1_G0, "f,g", F_FLOAT, 0, 0, v7 }, 1811 1.3 christos 1812 1.3 christos { "fabsd", F3F(2, 0x34, 0x00a), F3F(~2, ~0x34, ~0x00a)|RS1_G0, "B,H", F_FLOAT, 0, 0, v9 }, 1813 1.3 christos { "fabsq", F3F(2, 0x34, 0x00b), F3F(~2, ~0x34, ~0x00b)|RS1_G0, "R,J", F_FLOAT, 0, 0, v9 }, 1814 1.3 christos { "fabsx", F3F(2, 0x34, 0x00b), F3F(~2, ~0x34, ~0x00b)|RS1_G0, "R,J", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1815 1.3 christos { "fabss", F3F(2, 0x34, 0x009), F3F(~2, ~0x34, ~0x009)|RS1_G0, "f,g", F_FLOAT, 0, 0, v6 }, 1816 1.3 christos { "fmovd", F3F(2, 0x34, 0x002), F3F(~2, ~0x34, ~0x002)|RS1_G0, "B,H", F_FLOAT, 0, 0, v9 }, 1817 1.3 christos { "fmovq", F3F(2, 0x34, 0x003), F3F(~2, ~0x34, ~0x003)|RS1_G0, "R,J", F_FLOAT, 0, 0, v9 }, 1818 1.3 christos { "fmovx", F3F(2, 0x34, 0x003), F3F(~2, ~0x34, ~0x003)|RS1_G0, "R,J", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1819 1.3 christos { "fmovs", F3F(2, 0x34, 0x001), F3F(~2, ~0x34, ~0x001)|RS1_G0, "f,g", F_FLOAT, 0, 0, v6 }, 1820 1.3 christos { "fnegd", F3F(2, 0x34, 0x006), F3F(~2, ~0x34, ~0x006)|RS1_G0, "B,H", F_FLOAT, 0, 0, v9 }, 1821 1.3 christos { "fnegq", F3F(2, 0x34, 0x007), F3F(~2, ~0x34, ~0x007)|RS1_G0, "R,J", F_FLOAT, 0, 0, v9 }, 1822 1.3 christos { "fnegx", F3F(2, 0x34, 0x007), F3F(~2, ~0x34, ~0x007)|RS1_G0, "R,J", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1823 1.3 christos { "fnegs", F3F(2, 0x34, 0x005), F3F(~2, ~0x34, ~0x005)|RS1_G0, "f,g", F_FLOAT, 0, 0, v6 }, 1824 1.3 christos 1825 1.3 christos { "faddd", F3F(2, 0x34, 0x042), F3F(~2, ~0x34, ~0x042), "v,B,H", F_FLOAT, 0, 0, v6 }, 1826 1.3 christos { "faddq", F3F(2, 0x34, 0x043), F3F(~2, ~0x34, ~0x043), "V,R,J", F_FLOAT, 0, 0, v8 }, 1827 1.3 christos { "faddx", F3F(2, 0x34, 0x043), F3F(~2, ~0x34, ~0x043), "V,R,J", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1828 1.3 christos { "fadds", F3F(2, 0x34, 0x041), F3F(~2, ~0x34, ~0x041), "e,f,g", F_FLOAT, 0, 0, v6 }, 1829 1.3 christos { "fsubd", F3F(2, 0x34, 0x046), F3F(~2, ~0x34, ~0x046), "v,B,H", F_FLOAT, 0, 0, v6 }, 1830 1.3 christos { "fsubq", F3F(2, 0x34, 0x047), F3F(~2, ~0x34, ~0x047), "V,R,J", F_FLOAT, 0, 0, v8 }, 1831 1.1 christos { "fsubx", F3F(2, 0x34, 0x047), F3F(~2, ~0x34, ~0x047), "V,R,J", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1832 1.1 christos { "fsubs", F3F(2, 0x34, 0x045), F3F(~2, ~0x34, ~0x045), "e,f,g", F_FLOAT, 0, 0, v6 }, 1833 1.1 christos 1834 1.3 christos #define CMPFCC(x) (((x)&0x3)<<25) 1835 1.3 christos 1836 1.3 christos { "fcmpd", F3F(2, 0x35, 0x052), F3F(~2, ~0x35, ~0x052)|RD_G0, "v,B", F_FLOAT, 0, 0, v6 }, 1837 1.3 christos { "fcmpd", CMPFCC(0)|F3F(2, 0x35, 0x052), CMPFCC(~0)|F3F(~2, ~0x35, ~0x052), "6,v,B", F_FLOAT, 0, 0, v9 }, 1838 1.3 christos { "fcmpd", CMPFCC(1)|F3F(2, 0x35, 0x052), CMPFCC(~1)|F3F(~2, ~0x35, ~0x052), "7,v,B", F_FLOAT, 0, 0, v9 }, 1839 1.3 christos { "fcmpd", CMPFCC(2)|F3F(2, 0x35, 0x052), CMPFCC(~2)|F3F(~2, ~0x35, ~0x052), "8,v,B", F_FLOAT, 0, 0, v9 }, 1840 1.3 christos { "fcmpd", CMPFCC(3)|F3F(2, 0x35, 0x052), CMPFCC(~3)|F3F(~2, ~0x35, ~0x052), "9,v,B", F_FLOAT, 0, 0, v9 }, 1841 1.3 christos { "fcmped", F3F(2, 0x35, 0x056), F3F(~2, ~0x35, ~0x056)|RD_G0, "v,B", F_FLOAT, 0, 0, v6 }, 1842 1.3 christos { "fcmped", CMPFCC(0)|F3F(2, 0x35, 0x056), CMPFCC(~0)|F3F(~2, ~0x35, ~0x056), "6,v,B", F_FLOAT, 0, 0, v9 }, 1843 1.3 christos { "fcmped", CMPFCC(1)|F3F(2, 0x35, 0x056), CMPFCC(~1)|F3F(~2, ~0x35, ~0x056), "7,v,B", F_FLOAT, 0, 0, v9 }, 1844 1.3 christos { "fcmped", CMPFCC(2)|F3F(2, 0x35, 0x056), CMPFCC(~2)|F3F(~2, ~0x35, ~0x056), "8,v,B", F_FLOAT, 0, 0, v9 }, 1845 1.3 christos { "fcmped", CMPFCC(3)|F3F(2, 0x35, 0x056), CMPFCC(~3)|F3F(~2, ~0x35, ~0x056), "9,v,B", F_FLOAT, 0, 0, v9 }, 1846 1.3 christos { "fcmpq", F3F(2, 0x35, 0x053), F3F(~2, ~0x35, ~0x053)|RD_G0, "V,R", F_FLOAT, 0, 0, v8 }, 1847 1.3 christos { "fcmpq", CMPFCC(0)|F3F(2, 0x35, 0x053), CMPFCC(~0)|F3F(~2, ~0x35, ~0x053), "6,V,R", F_FLOAT, 0, 0, v9 }, 1848 1.3 christos { "fcmpq", CMPFCC(1)|F3F(2, 0x35, 0x053), CMPFCC(~1)|F3F(~2, ~0x35, ~0x053), "7,V,R", F_FLOAT, 0, 0, v9 }, 1849 1.3 christos { "fcmpq", CMPFCC(2)|F3F(2, 0x35, 0x053), CMPFCC(~2)|F3F(~2, ~0x35, ~0x053), "8,V,R", F_FLOAT, 0, 0, v9 }, 1850 1.3 christos { "fcmpq", CMPFCC(3)|F3F(2, 0x35, 0x053), CMPFCC(~3)|F3F(~2, ~0x35, ~0x053), "9,V,R", F_FLOAT, 0, 0, v9 }, 1851 1.3 christos { "fcmpeq", F3F(2, 0x35, 0x057), F3F(~2, ~0x35, ~0x057)|RD_G0, "V,R", F_FLOAT, 0, 0, v8 }, 1852 1.3 christos { "fcmpeq", CMPFCC(0)|F3F(2, 0x35, 0x057), CMPFCC(~0)|F3F(~2, ~0x35, ~0x057), "6,V,R", F_FLOAT, 0, 0, v9 }, 1853 1.3 christos { "fcmpeq", CMPFCC(1)|F3F(2, 0x35, 0x057), CMPFCC(~1)|F3F(~2, ~0x35, ~0x057), "7,V,R", F_FLOAT, 0, 0, v9 }, 1854 1.3 christos { "fcmpeq", CMPFCC(2)|F3F(2, 0x35, 0x057), CMPFCC(~2)|F3F(~2, ~0x35, ~0x057), "8,V,R", F_FLOAT, 0, 0, v9 }, 1855 1.3 christos { "fcmpeq", CMPFCC(3)|F3F(2, 0x35, 0x057), CMPFCC(~3)|F3F(~2, ~0x35, ~0x057), "9,V,R", F_FLOAT, 0, 0, v9 }, 1856 1.3 christos { "fcmpx", F3F(2, 0x35, 0x053), F3F(~2, ~0x35, ~0x053)|RD_G0, "V,R", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1857 1.3 christos { "fcmpx", CMPFCC(0)|F3F(2, 0x35, 0x053), CMPFCC(~0)|F3F(~2, ~0x35, ~0x053), "6,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1858 1.3 christos { "fcmpx", CMPFCC(1)|F3F(2, 0x35, 0x053), CMPFCC(~1)|F3F(~2, ~0x35, ~0x053), "7,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1859 1.3 christos { "fcmpx", CMPFCC(2)|F3F(2, 0x35, 0x053), CMPFCC(~2)|F3F(~2, ~0x35, ~0x053), "8,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1860 1.3 christos { "fcmpx", CMPFCC(3)|F3F(2, 0x35, 0x053), CMPFCC(~3)|F3F(~2, ~0x35, ~0x053), "9,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1861 1.3 christos { "fcmpex", F3F(2, 0x35, 0x057), F3F(~2, ~0x35, ~0x057)|RD_G0, "V,R", F_FLOAT|F_ALIAS, 0, 0, v8 }, 1862 1.3 christos { "fcmpex", CMPFCC(0)|F3F(2, 0x35, 0x057), CMPFCC(~0)|F3F(~2, ~0x35, ~0x057), "6,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1863 1.3 christos { "fcmpex", CMPFCC(1)|F3F(2, 0x35, 0x057), CMPFCC(~1)|F3F(~2, ~0x35, ~0x057), "7,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1864 1.3 christos { "fcmpex", CMPFCC(2)|F3F(2, 0x35, 0x057), CMPFCC(~2)|F3F(~2, ~0x35, ~0x057), "8,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1865 1.3 christos { "fcmpex", CMPFCC(3)|F3F(2, 0x35, 0x057), CMPFCC(~3)|F3F(~2, ~0x35, ~0x057), "9,V,R", F_FLOAT|F_ALIAS, 0, 0, v9 }, 1866 1.3 christos { "fcmps", F3F(2, 0x35, 0x051), F3F(~2, ~0x35, ~0x051)|RD_G0, "e,f", F_FLOAT, 0, 0, v6 }, 1867 1.3 christos { "fcmps", CMPFCC(0)|F3F(2, 0x35, 0x051), CMPFCC(~0)|F3F(~2, ~0x35, ~0x051), "6,e,f", F_FLOAT, 0, 0, v9 }, 1868 1.3 christos { "fcmps", CMPFCC(1)|F3F(2, 0x35, 0x051), CMPFCC(~1)|F3F(~2, ~0x35, ~0x051), "7,e,f", F_FLOAT, 0, 0, v9 }, 1869 1.3 christos { "fcmps", CMPFCC(2)|F3F(2, 0x35, 0x051), CMPFCC(~2)|F3F(~2, ~0x35, ~0x051), "8,e,f", F_FLOAT, 0, 0, v9 }, 1870 1.3 christos { "fcmps", CMPFCC(3)|F3F(2, 0x35, 0x051), CMPFCC(~3)|F3F(~2, ~0x35, ~0x051), "9,e,f", F_FLOAT, 0, 0, v9 }, 1871 1.3 christos { "fcmpes", F3F(2, 0x35, 0x055), F3F(~2, ~0x35, ~0x055)|RD_G0, "e,f", F_FLOAT, 0, 0, v6 }, 1872 1.3 christos { "fcmpes", CMPFCC(0)|F3F(2, 0x35, 0x055), CMPFCC(~0)|F3F(~2, ~0x35, ~0x055), "6,e,f", F_FLOAT, 0, 0, v9 }, 1873 1.3 christos { "fcmpes", CMPFCC(1)|F3F(2, 0x35, 0x055), CMPFCC(~1)|F3F(~2, ~0x35, ~0x055), "7,e,f", F_FLOAT, 0, 0, v9 }, 1874 1.1 christos { "fcmpes", CMPFCC(2)|F3F(2, 0x35, 0x055), CMPFCC(~2)|F3F(~2, ~0x35, ~0x055), "8,e,f", F_FLOAT, 0, 0, v9 }, 1875 1.1 christos { "fcmpes", CMPFCC(3)|F3F(2, 0x35, 0x055), CMPFCC(~3)|F3F(~2, ~0x35, ~0x055), "9,e,f", F_FLOAT, 0, 0, v9 }, 1876 1.1 christos 1877 1.1 christos /* These Extended FPop (FIFO) instructions are new in the Fujitsu 1878 1.1 christos MB86934, replacing the CPop instructions from v6 and later 1879 1.3 christos processors. */ 1880 1.3 christos 1881 1.3 christos #define EFPOP1_2(name, op, args) { name, F3F(2, 0x36, op), F3F(~2, ~0x36, ~op)|RS1_G0, args, 0, 0, 0, sparclite } 1882 1.1 christos #define EFPOP1_3(name, op, args) { name, F3F(2, 0x36, op), F3F(~2, ~0x36, ~op), args, 0, 0, 0, sparclite } 1883 1.1 christos #define EFPOP2_2(name, op, args) { name, F3F(2, 0x37, op), F3F(~2, ~0x37, ~op)|RD_G0, args, 0, 0, 0, sparclite } 1884 1.1 christos 1885 1.1 christos EFPOP1_2 ("efitod", 0x0c8, "f,H"), 1886 1.1 christos EFPOP1_2 ("efitos", 0x0c4, "f,g"), 1887 1.1 christos EFPOP1_2 ("efdtoi", 0x0d2, "B,g"), 1888 1.1 christos EFPOP1_2 ("efstoi", 0x0d1, "f,g"), 1889 1.1 christos EFPOP1_2 ("efstod", 0x0c9, "f,H"), 1890 1.1 christos EFPOP1_2 ("efdtos", 0x0c6, "B,g"), 1891 1.1 christos EFPOP1_2 ("efmovs", 0x001, "f,g"), 1892 1.1 christos EFPOP1_2 ("efnegs", 0x005, "f,g"), 1893 1.1 christos EFPOP1_2 ("efabss", 0x009, "f,g"), 1894 1.1 christos EFPOP1_2 ("efsqrtd", 0x02a, "B,H"), 1895 1.1 christos EFPOP1_2 ("efsqrts", 0x029, "f,g"), 1896 1.1 christos EFPOP1_3 ("efaddd", 0x042, "v,B,H"), 1897 1.1 christos EFPOP1_3 ("efadds", 0x041, "e,f,g"), 1898 1.1 christos EFPOP1_3 ("efsubd", 0x046, "v,B,H"), 1899 1.1 christos EFPOP1_3 ("efsubs", 0x045, "e,f,g"), 1900 1.1 christos EFPOP1_3 ("efdivd", 0x04e, "v,B,H"), 1901 1.1 christos EFPOP1_3 ("efdivs", 0x04d, "e,f,g"), 1902 1.1 christos EFPOP1_3 ("efmuld", 0x04a, "v,B,H"), 1903 1.1 christos EFPOP1_3 ("efmuls", 0x049, "e,f,g"), 1904 1.1 christos EFPOP1_3 ("efsmuld", 0x069, "e,f,H"), 1905 1.1 christos EFPOP2_2 ("efcmpd", 0x052, "v,B"), 1906 1.1 christos EFPOP2_2 ("efcmped", 0x056, "v,B"), 1907 1.1 christos EFPOP2_2 ("efcmps", 0x051, "e,f"), 1908 1.1 christos EFPOP2_2 ("efcmpes", 0x055, "e,f"), 1909 1.1 christos 1910 1.1 christos #undef EFPOP1_2 1911 1.1 christos #undef EFPOP1_3 1912 1.1 christos #undef EFPOP2_2 1913 1.1 christos 1914 1.3 christos /* These are marked F_ALIAS, so that they won't conflict with sparclite insns 1915 1.3 christos present. Otherwise, the F_ALIAS flag is ignored. */ 1916 1.1 christos { "cpop1", F3(2, 0x36, 0), F3(~2, ~0x36, ~1), "[1+2],d", F_ALIAS, 0, 0, v6notv9 }, 1917 1.1 christos { "cpop2", F3(2, 0x37, 0), F3(~2, ~0x37, ~1), "[1+2],d", F_ALIAS, 0, 0, v6notv9 }, 1918 1.1 christos 1919 1.1 christos /* sparclet specific insns */ 1920 1.1 christos 1921 1.1 christos COMMUTEOP ("umac", 0x3e, letandleon), 1922 1.1 christos COMMUTEOP ("smac", 0x3f, letandleon), 1923 1.1 christos 1924 1.1 christos COMMUTEOP ("umacd", 0x2e, sparclet), 1925 1.1 christos COMMUTEOP ("smacd", 0x2f, sparclet), 1926 1.1 christos COMMUTEOP ("umuld", 0x09, sparclet), 1927 1.3 christos COMMUTEOP ("smuld", 0x0d, sparclet), 1928 1.3 christos 1929 1.1 christos { "shuffle", F3(2, 0x2d, 0), F3(~2, ~0x2d, ~0)|ASI(~0), "1,2,d", 0, 0, 0, sparclet }, 1930 1.1 christos { "shuffle", F3(2, 0x2d, 1), F3(~2, ~0x2d, ~1), "1,i,d", 0, 0, 0, sparclet }, 1931 1.1 christos 1932 1.1 christos /* The manual isn't completely accurate on these insns. The `rs2' field is 1933 1.1 christos treated as being 6 bits to account for 6 bit immediates to cpush. It is 1934 1.3 christos assumed that it is intended that bit 5 is 0 when rs2 contains a reg. */ 1935 1.3 christos #define BIT5 (1<<5) 1936 1.3 christos { "crdcxt", F3(2, 0x36, 0)|SLCPOP(4), F3(~2, ~0x36, ~0)|SLCPOP(~4)|BIT5|RS2(~0), "U,d", 0, 0, 0, sparclet }, 1937 1.3 christos { "cwrcxt", F3(2, 0x36, 0)|SLCPOP(3), F3(~2, ~0x36, ~0)|SLCPOP(~3)|BIT5|RS2(~0), "1,u", 0, 0, 0, sparclet }, 1938 1.3 christos { "cpush", F3(2, 0x36, 0)|SLCPOP(0), F3(~2, ~0x36, ~0)|SLCPOP(~0)|BIT5|RD(~0), "1,2", 0, 0, 0, sparclet }, 1939 1.3 christos { "cpush", F3(2, 0x36, 1)|SLCPOP(0), F3(~2, ~0x36, ~1)|SLCPOP(~0)|RD(~0), "1,Y", 0, 0, 0, sparclet }, 1940 1.3 christos { "cpusha", F3(2, 0x36, 0)|SLCPOP(1), F3(~2, ~0x36, ~0)|SLCPOP(~1)|BIT5|RD(~0), "1,2", 0, 0, 0, sparclet }, 1941 1.1 christos { "cpusha", F3(2, 0x36, 1)|SLCPOP(1), F3(~2, ~0x36, ~1)|SLCPOP(~1)|RD(~0), "1,Y", 0, 0, 0, sparclet }, 1942 1.1 christos { "cpull", F3(2, 0x36, 0)|SLCPOP(2), F3(~2, ~0x36, ~0)|SLCPOP(~2)|BIT5|RS1(~0)|RS2(~0), "d", 0, 0, 0, sparclet }, 1943 1.1 christos #undef BIT5 1944 1.1 christos 1945 1.3 christos /* sparclet coprocessor branch insns */ 1946 1.3 christos #define SLCBCC2(opcode, mask, lose) \ 1947 1.1 christos { opcode, (mask), ANNUL|(lose), "l", F_DELAYED|F_CONDBR, 0, 0, sparclet }, \ 1948 1.1 christos { opcode, (mask)|ANNUL, (lose), ",a l", F_DELAYED|F_CONDBR, 0, 0, sparclet } 1949 1.1 christos #define SLCBCC(opcode, mask) \ 1950 1.1 christos SLCBCC2(opcode, F2(0, 7)|COND(mask), F2(~0, ~7)|COND(~(mask))) 1951 1.1 christos 1952 1.1 christos /* cbn,cba can't be defined here because they're defined elsewhere and GAS 1953 1.1 christos requires all mnemonics of the same name to be consecutive. */ 1954 1.1 christos /*SLCBCC("cbn", 0), - already defined */ 1955 1.1 christos SLCBCC("cbe", 1), 1956 1.1 christos SLCBCC("cbf", 2), 1957 1.1 christos SLCBCC("cbef", 3), 1958 1.1 christos SLCBCC("cbr", 4), 1959 1.1 christos SLCBCC("cber", 5), 1960 1.1 christos SLCBCC("cbfr", 6), 1961 1.1 christos SLCBCC("cbefr", 7), 1962 1.1 christos /*SLCBCC("cba", 8), - already defined */ 1963 1.1 christos SLCBCC("cbne", 9), 1964 1.1 christos SLCBCC("cbnf", 10), 1965 1.1 christos SLCBCC("cbnef", 11), 1966 1.1 christos SLCBCC("cbnr", 12), 1967 1.1 christos SLCBCC("cbner", 13), 1968 1.1 christos SLCBCC("cbnfr", 14), 1969 1.1 christos SLCBCC("cbnefr", 15), 1970 1.1 christos 1971 1.1 christos #undef SLCBCC2 1972 1.3 christos #undef SLCBCC 1973 1.3 christos 1974 1.3 christos { "casa", F3(3, 0x3c, 0), F3(~3, ~0x3c, ~0), "[1]A,2,d", 0, 0, 0, v9andleon }, 1975 1.3 christos { "casa", F3(3, 0x3c, 1), F3(~3, ~0x3c, ~1), "[1]o,2,d", 0, 0, 0, v9andleon }, 1976 1.1 christos { "casxa", F3(3, 0x3e, 0), F3(~3, ~0x3e, ~0), "[1]A,2,d", 0, 0, 0, v9 }, 1977 1.1 christos { "casxa", F3(3, 0x3e, 1), F3(~3, ~0x3e, ~1), "[1]o,2,d", 0, 0, 0, v9 }, 1978 1.3 christos 1979 1.3 christos /* v9 synthetic insns */ 1980 1.3 christos { "iprefetch", F2(0, 1)|(2<<20)|BPRED, F2(~0, ~1)|(1<<20)|ANNUL|COND(~0), "G", 0, 0, 0, v9 }, /* bn,a,pt %xcc,label */ 1981 1.3 christos { "signx", F3(2, 0x27, 0), F3(~2, ~0x27, ~0)|(1<<12)|ASI(~0)|RS2_G0, "1,d", F_ALIAS, 0, 0, v9 }, /* sra rs1,%g0,rd */ 1982 1.3 christos { "signx", F3(2, 0x27, 0), F3(~2, ~0x27, ~0)|(1<<12)|ASI(~0)|RS2_G0, "r", F_ALIAS, 0, 0, v9 }, /* sra rd,%g0,rd */ 1983 1.3 christos { "clruw", F3(2, 0x26, 0), F3(~2, ~0x26, ~0)|(1<<12)|ASI(~0)|RS2_G0, "1,d", F_ALIAS, 0, 0, v9 }, /* srl rs1,%g0,rd */ 1984 1.3 christos { "clruw", F3(2, 0x26, 0), F3(~2, ~0x26, ~0)|(1<<12)|ASI(~0)|RS2_G0, "r", F_ALIAS, 0, 0, v9 }, /* srl rd,%g0,rd */ 1985 1.3 christos { "cas", F3(3, 0x3c, 0)|ASI(0x80), F3(~3, ~0x3c, ~0)|ASI(~0x80), "[1],2,d", F_ALIAS, 0, 0, v9 }, /* casa [rs1]ASI_P,rs2,rd */ 1986 1.3 christos { "casl", F3(3, 0x3c, 0)|ASI(0x88), F3(~3, ~0x3c, ~0)|ASI(~0x88), "[1],2,d", F_ALIAS, 0, 0, v9 }, /* casa [rs1]ASI_P_L,rs2,rd */ 1987 1.1 christos { "casx", F3(3, 0x3e, 0)|ASI(0x80), F3(~3, ~0x3e, ~0)|ASI(~0x80), "[1],2,d", F_ALIAS, 0, 0, v9 }, /* casxa [rs1]ASI_P,rs2,rd */ 1988 1.1 christos { "casxl", F3(3, 0x3e, 0)|ASI(0x88), F3(~3, ~0x3e, ~0)|ASI(~0x88), "[1],2,d", F_ALIAS, 0, 0, v9 }, /* casxa [rs1]ASI_P_L,rs2,rd */ 1989 1.3 christos 1990 1.1 christos /* Ultrasparc extensions */ 1991 1.1 christos { "shutdown", F3F(2, 0x36, 0x080), F3F(~2, ~0x36, ~0x080)|RD_G0|RS1_G0|RS2_G0, "", 0, HWCAP_VIS, 0, v9a }, 1992 1.3 christos 1993 1.3 christos /* FIXME: Do we want to mark these as F_FLOAT, or something similar? */ 1994 1.3 christos { "fpadd16", F3F(2, 0x36, 0x050), F3F(~2, ~0x36, ~0x050), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 1995 1.3 christos { "fpadd16s", F3F(2, 0x36, 0x051), F3F(~2, ~0x36, ~0x051), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 1996 1.3 christos { "fpadd32", F3F(2, 0x36, 0x052), F3F(~2, ~0x36, ~0x052), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 1997 1.3 christos { "fpadd32s", F3F(2, 0x36, 0x053), F3F(~2, ~0x36, ~0x053), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 1998 1.3 christos { "fpsub16", F3F(2, 0x36, 0x054), F3F(~2, ~0x36, ~0x054), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 1999 1.3 christos { "fpsub16s", F3F(2, 0x36, 0x055), F3F(~2, ~0x36, ~0x055), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2000 1.3 christos { "fpsub32", F3F(2, 0x36, 0x056), F3F(~2, ~0x36, ~0x056), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2001 1.3 christos { "fpsub32s", F3F(2, 0x36, 0x057), F3F(~2, ~0x36, ~0x057), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2002 1.3 christos 2003 1.3 christos { "fpack32", F3F(2, 0x36, 0x03a), F3F(~2, ~0x36, ~0x03a), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2004 1.3 christos { "fpack16", F3F(2, 0x36, 0x03b), F3F(~2, ~0x36, ~0x03b)|RS1_G0, "B,g", 0, HWCAP_VIS, 0, v9a }, 2005 1.3 christos { "fpackfix", F3F(2, 0x36, 0x03d), F3F(~2, ~0x36, ~0x03d)|RS1_G0, "B,g", 0, HWCAP_VIS, 0, v9a }, 2006 1.1 christos { "fexpand", F3F(2, 0x36, 0x04d), F3F(~2, ~0x36, ~0x04d)|RS1_G0, "f,H", 0, HWCAP_VIS, 0, v9a }, 2007 1.1 christos { "fpmerge", F3F(2, 0x36, 0x04b), F3F(~2, ~0x36, ~0x04b), "e,f,H", 0, HWCAP_VIS, 0, v9a }, 2008 1.3 christos 2009 1.3 christos /* Note that the mixing of 32/64 bit regs is intentional. */ 2010 1.3 christos { "fmul8x16", F3F(2, 0x36, 0x031), F3F(~2, ~0x36, ~0x031), "e,B,H", 0, HWCAP_VIS, 0, v9a }, 2011 1.3 christos { "fmul8x16au", F3F(2, 0x36, 0x033), F3F(~2, ~0x36, ~0x033), "e,f,H", 0, HWCAP_VIS, 0, v9a }, 2012 1.3 christos { "fmul8x16al", F3F(2, 0x36, 0x035), F3F(~2, ~0x36, ~0x035), "e,f,H", 0, HWCAP_VIS, 0, v9a }, 2013 1.3 christos { "fmul8sux16", F3F(2, 0x36, 0x036), F3F(~2, ~0x36, ~0x036), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2014 1.3 christos { "fmul8ulx16", F3F(2, 0x36, 0x037), F3F(~2, ~0x36, ~0x037), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2015 1.3 christos { "fmuld8sux16", F3F(2, 0x36, 0x038), F3F(~2, ~0x36, ~0x038), "e,f,H", 0, HWCAP_VIS, 0, v9a }, 2016 1.3 christos { "fmuld8ulx16", F3F(2, 0x36, 0x039), F3F(~2, ~0x36, ~0x039), "e,f,H", 0, HWCAP_VIS, 0, v9a }, 2017 1.3 christos 2018 1.6 christos { "alignaddr", F3F(2, 0x36, 0x018), F3F(~2, ~0x36, ~0x018), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2019 1.6 christos { "alignaddrl", F3F(2, 0x36, 0x01a), F3F(~2, ~0x36, ~0x01a), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2020 1.3 christos { "faligndata", F3F(2, 0x36, 0x048), F3F(~2, ~0x36, ~0x048), "v,B,H", 0, HWCAP_VIS, 0, v9a }, /* faligndatag */ 2021 1.3 christos { "faligndata", F3F(2, 0x36, 0x049), F3F(~2, ~0x36, ~0x049), "v,B,5,}", 0, 0, HWCAP2_SPARC5, v9m }, /* faligndatai */ 2022 1.3 christos 2023 1.3 christos { "fzerod", F3F(2, 0x36, 0x060), F3F(~2, ~0x36, ~0x060), "H", 0, HWCAP_VIS, 0, v9a }, 2024 1.3 christos { "fzero", F3F(2, 0x36, 0x060), F3F(~2, ~0x36, ~0x060), "H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2025 1.3 christos { "fzeros", F3F(2, 0x36, 0x061), F3F(~2, ~0x36, ~0x061), "g", 0, HWCAP_VIS, 0, v9a }, 2026 1.3 christos { "foned", F3F(2, 0x36, 0x07e), F3F(~2, ~0x36, ~0x07e), "H", 0, HWCAP_VIS, 0, v9a }, 2027 1.3 christos { "fone", F3F(2, 0x36, 0x07e), F3F(~2, ~0x36, ~0x07e), "H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2028 1.3 christos { "fones", F3F(2, 0x36, 0x07f), F3F(~2, ~0x36, ~0x07f), "g", 0, HWCAP_VIS, 0, v9a }, 2029 1.3 christos { "fsrc1d", F3F(2, 0x36, 0x074), F3F(~2, ~0x36, ~0x074), "v,H", 0, HWCAP_VIS, 0, v9a }, 2030 1.3 christos { "fsrc1", F3F(2, 0x36, 0x074), F3F(~2, ~0x36, ~0x074), "v,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2031 1.3 christos { "fsrc1s", F3F(2, 0x36, 0x075), F3F(~2, ~0x36, ~0x075), "e,g", 0, HWCAP_VIS, 0, v9a }, 2032 1.3 christos { "fsrc2d", F3F(2, 0x36, 0x078), F3F(~2, ~0x36, ~0x078), "B,H", 0, HWCAP_VIS, 0, v9a }, 2033 1.3 christos { "fsrc2", F3F(2, 0x36, 0x078), F3F(~2, ~0x36, ~0x078), "B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2034 1.3 christos { "fsrc2s", F3F(2, 0x36, 0x079), F3F(~2, ~0x36, ~0x079), "f,g", 0, HWCAP_VIS, 0, v9a }, 2035 1.3 christos { "fnot1d", F3F(2, 0x36, 0x06a), F3F(~2, ~0x36, ~0x06a), "v,H", 0, HWCAP_VIS, 0, v9a }, 2036 1.3 christos { "fnot1", F3F(2, 0x36, 0x06a), F3F(~2, ~0x36, ~0x06a), "v,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2037 1.3 christos { "fnot1s", F3F(2, 0x36, 0x06b), F3F(~2, ~0x36, ~0x06b), "e,g", 0, HWCAP_VIS, 0, v9a }, 2038 1.3 christos { "fnot2d", F3F(2, 0x36, 0x066), F3F(~2, ~0x36, ~0x066), "B,H", 0, HWCAP_VIS, 0, v9a }, 2039 1.3 christos { "fnot2", F3F(2, 0x36, 0x066), F3F(~2, ~0x36, ~0x066), "B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2040 1.3 christos { "fnot2s", F3F(2, 0x36, 0x067), F3F(~2, ~0x36, ~0x067), "f,g", 0, HWCAP_VIS, 0, v9a }, 2041 1.3 christos { "ford", F3F(2, 0x36, 0x07c), F3F(~2, ~0x36, ~0x07c), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2042 1.3 christos { "for", F3F(2, 0x36, 0x07c), F3F(~2, ~0x36, ~0x07c), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2043 1.3 christos { "fors", F3F(2, 0x36, 0x07d), F3F(~2, ~0x36, ~0x07d), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2044 1.3 christos { "fnord", F3F(2, 0x36, 0x062), F3F(~2, ~0x36, ~0x062), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2045 1.3 christos { "fnor", F3F(2, 0x36, 0x062), F3F(~2, ~0x36, ~0x062), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2046 1.3 christos { "fnors", F3F(2, 0x36, 0x063), F3F(~2, ~0x36, ~0x063), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2047 1.3 christos { "fandd", F3F(2, 0x36, 0x070), F3F(~2, ~0x36, ~0x070), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2048 1.3 christos { "fand", F3F(2, 0x36, 0x070), F3F(~2, ~0x36, ~0x070), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2049 1.3 christos { "fands", F3F(2, 0x36, 0x071), F3F(~2, ~0x36, ~0x071), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2050 1.3 christos { "fnandd", F3F(2, 0x36, 0x06e), F3F(~2, ~0x36, ~0x06e), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2051 1.3 christos { "fnand", F3F(2, 0x36, 0x06e), F3F(~2, ~0x36, ~0x06e), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2052 1.3 christos { "fnands", F3F(2, 0x36, 0x06f), F3F(~2, ~0x36, ~0x06f), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2053 1.3 christos { "fxord", F3F(2, 0x36, 0x06c), F3F(~2, ~0x36, ~0x06c), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2054 1.3 christos { "fxor", F3F(2, 0x36, 0x06c), F3F(~2, ~0x36, ~0x06c), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2055 1.3 christos { "fxors", F3F(2, 0x36, 0x06d), F3F(~2, ~0x36, ~0x06d), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2056 1.3 christos { "fxnord", F3F(2, 0x36, 0x072), F3F(~2, ~0x36, ~0x072), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2057 1.3 christos { "fxnor", F3F(2, 0x36, 0x072), F3F(~2, ~0x36, ~0x072), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2058 1.3 christos { "fxnors", F3F(2, 0x36, 0x073), F3F(~2, ~0x36, ~0x073), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2059 1.3 christos { "fornot1d", F3F(2, 0x36, 0x07a), F3F(~2, ~0x36, ~0x07a), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2060 1.3 christos { "fornot1", F3F(2, 0x36, 0x07a), F3F(~2, ~0x36, ~0x07a), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2061 1.3 christos { "fornot1s", F3F(2, 0x36, 0x07b), F3F(~2, ~0x36, ~0x07b), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2062 1.3 christos { "fornot2d", F3F(2, 0x36, 0x076), F3F(~2, ~0x36, ~0x076), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2063 1.3 christos { "fornot2", F3F(2, 0x36, 0x076), F3F(~2, ~0x36, ~0x076), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2064 1.3 christos { "fornot2s", F3F(2, 0x36, 0x077), F3F(~2, ~0x36, ~0x077), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2065 1.3 christos { "fandnot1d", F3F(2, 0x36, 0x068), F3F(~2, ~0x36, ~0x068), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2066 1.3 christos { "fandnot1", F3F(2, 0x36, 0x068), F3F(~2, ~0x36, ~0x068), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2067 1.3 christos { "fandnot1s", F3F(2, 0x36, 0x069), F3F(~2, ~0x36, ~0x069), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2068 1.3 christos { "fandnot2d", F3F(2, 0x36, 0x064), F3F(~2, ~0x36, ~0x064), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2069 1.3 christos { "fandnot2", F3F(2, 0x36, 0x064), F3F(~2, ~0x36, ~0x064), "v,B,H", F_ALIAS, HWCAP_VIS, 0, v9a }, 2070 1.3 christos { "fandnot2s", F3F(2, 0x36, 0x065), F3F(~2, ~0x36, ~0x065), "e,f,g", 0, HWCAP_VIS, 0, v9a }, 2071 1.3 christos 2072 1.3 christos { "fpcmpgt16", F3F(2, 0x36, 0x028), F3F(~2, ~0x36, ~0x028), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2073 1.3 christos { "fcmpgt16", F3F(2, 0x36, 0x028), F3F(~2, ~0x36, ~0x028), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2074 1.3 christos { "fpcmpgt32", F3F(2, 0x36, 0x02c), F3F(~2, ~0x36, ~0x02c), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2075 1.3 christos { "fcmpgt32", F3F(2, 0x36, 0x02c), F3F(~2, ~0x36, ~0x02c), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2076 1.3 christos { "fpcmple16", F3F(2, 0x36, 0x020), F3F(~2, ~0x36, ~0x020), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2077 1.3 christos { "fcmple16", F3F(2, 0x36, 0x020), F3F(~2, ~0x36, ~0x020), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2078 1.3 christos { "fpcmple32", F3F(2, 0x36, 0x024), F3F(~2, ~0x36, ~0x024), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2079 1.3 christos { "fcmple32", F3F(2, 0x36, 0x024), F3F(~2, ~0x36, ~0x024), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2080 1.3 christos { "fpcmpne16", F3F(2, 0x36, 0x022), F3F(~2, ~0x36, ~0x022), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2081 1.3 christos { "fpcmpune16", F3F(2, 0x36, 0x022), F3F(~2, ~0x36, ~0x022), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2082 1.3 christos { "fcmpne16", F3F(2, 0x36, 0x022), F3F(~2, ~0x36, ~0x022), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2083 1.3 christos { "fpcmpne32", F3F(2, 0x36, 0x026), F3F(~2, ~0x36, ~0x026), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2084 1.3 christos { "fpcmpune32", F3F(2, 0x36, 0x026), F3F(~2, ~0x36, ~0x026), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2085 1.3 christos { "fcmpne32", F3F(2, 0x36, 0x026), F3F(~2, ~0x36, ~0x026), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2086 1.3 christos { "fpcmpeq16", F3F(2, 0x36, 0x02a), F3F(~2, ~0x36, ~0x02a), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2087 1.3 christos { "fpcmpueq16", F3F(2, 0x36, 0x02a), F3F(~2, ~0x36, ~0x02a), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2088 1.3 christos { "fcmpeq16", F3F(2, 0x36, 0x02a), F3F(~2, ~0x36, ~0x02a), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2089 1.3 christos { "fpcmpeq32", F3F(2, 0x36, 0x02e), F3F(~2, ~0x36, ~0x02e), "v,B,d", 0, HWCAP_VIS, 0, v9a }, 2090 1.3 christos { "fpcmpueq32", F3F(2, 0x36, 0x02e), F3F(~2, ~0x36, ~0x02e), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2091 1.3 christos { "fcmpeq32", F3F(2, 0x36, 0x02e), F3F(~2, ~0x36, ~0x02e), "v,B,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2092 1.3 christos 2093 1.3 christos { "edge8cc", F3F(2, 0x36, 0x000), F3F(~2, ~0x36, ~0x000), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2094 1.3 christos { "edge8lcc", F3F(2, 0x36, 0x002), F3F(~2, ~0x36, ~0x002), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2095 1.3 christos { "edge16cc", F3F(2, 0x36, 0x004), F3F(~2, ~0x36, ~0x004), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2096 1.3 christos { "edge16lcc", F3F(2, 0x36, 0x006), F3F(~2, ~0x36, ~0x006), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2097 1.3 christos { "edge32cc", F3F(2, 0x36, 0x008), F3F(~2, ~0x36, ~0x008), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2098 1.3 christos { "edge32lcc", F3F(2, 0x36, 0x00a), F3F(~2, ~0x36, ~0x00a), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2099 1.3 christos 2100 1.3 christos { "edge8", F3F(2, 0x36, 0x000), F3F(~2, ~0x36, ~0x000), "1,2,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2101 1.3 christos { "edge8l", F3F(2, 0x36, 0x002), F3F(~2, ~0x36, ~0x002), "1,2,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2102 1.3 christos { "edge16", F3F(2, 0x36, 0x004), F3F(~2, ~0x36, ~0x004), "1,2,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2103 1.3 christos { "edge16l", F3F(2, 0x36, 0x006), F3F(~2, ~0x36, ~0x006), "1,2,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2104 1.3 christos { "edge32", F3F(2, 0x36, 0x008), F3F(~2, ~0x36, ~0x008), "1,2,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2105 1.3 christos { "edge32l", F3F(2, 0x36, 0x00a), F3F(~2, ~0x36, ~0x00a), "1,2,d", F_ALIAS, HWCAP_VIS, 0, v9a }, 2106 1.3 christos 2107 1.3 christos { "pdist", F3F(2, 0x36, 0x03e), F3F(~2, ~0x36, ~0x03e), "v,B,H", 0, HWCAP_VIS, 0, v9a }, 2108 1.3 christos 2109 1.3 christos { "array8", F3F(2, 0x36, 0x010), F3F(~2, ~0x36, ~0x010), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2110 1.1 christos { "array16", F3F(2, 0x36, 0x012), F3F(~2, ~0x36, ~0x012), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2111 1.1 christos { "array32", F3F(2, 0x36, 0x014), F3F(~2, ~0x36, ~0x014), "1,2,d", 0, HWCAP_VIS, 0, v9a }, 2112 1.3 christos 2113 1.3 christos /* Cheetah instructions */ 2114 1.3 christos { "edge8n", F3F(2, 0x36, 0x001), F3F(~2, ~0x36, ~0x001), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2115 1.3 christos { "edge8ln", F3F(2, 0x36, 0x003), F3F(~2, ~0x36, ~0x003), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2116 1.3 christos { "edge16n", F3F(2, 0x36, 0x005), F3F(~2, ~0x36, ~0x005), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2117 1.3 christos { "edge16ln", F3F(2, 0x36, 0x007), F3F(~2, ~0x36, ~0x007), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2118 1.3 christos { "edge32n", F3F(2, 0x36, 0x009), F3F(~2, ~0x36, ~0x009), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2119 1.3 christos { "edge32ln", F3F(2, 0x36, 0x00b), F3F(~2, ~0x36, ~0x00b), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2120 1.3 christos 2121 1.3 christos { "bmask", F3F(2, 0x36, 0x019), F3F(~2, ~0x36, ~0x019), "1,2,d", 0, HWCAP_VIS2, 0, v9b }, 2122 1.3 christos { "bshuffle", F3F(2, 0x36, 0x04c), F3F(~2, ~0x36, ~0x04c), "v,B,H", 0, HWCAP_VIS2, 0, v9b }, 2123 1.3 christos 2124 1.6 christos { "siam", F3F(2, 0x36, 0x081), F3F(~2, ~0x36, ~0x081)|RD_G0|RS1_G0|RS2(~7), "3", 0, HWCAP_VIS2, 0, v9b }, 2125 1.6 christos 2126 1.6 christos { "fnadds", F3F(2, 0x34, 0x051), F3F(~2, ~0x34, ~0x051), "e,f,g", F_FLOAT, HWCAP_HPC, 0, v9d }, 2127 1.6 christos { "fnaddd", F3F(2, 0x34, 0x052), F3F(~2, ~0x34, ~0x052), "v,B,H", F_FLOAT, HWCAP_HPC, 0, v9d }, 2128 1.6 christos { "fnmuls", F3F(2, 0x34, 0x059), F3F(~2, ~0x34, ~0x059), "e,f,g", F_FLOAT, HWCAP_HPC, 0, v9d }, 2129 1.6 christos { "fnmuld", F3F(2, 0x34, 0x05a), F3F(~2, ~0x34, ~0x05a), "v,B,H", F_FLOAT, HWCAP_HPC, 0, v9d }, 2130 1.6 christos { "fhadds", F3F(2, 0x34, 0x061), F3F(~2, ~0x34, ~0x061), "e,f,g", F_FLOAT, HWCAP_HPC, 0, v9d }, 2131 1.6 christos { "fhaddd", F3F(2, 0x34, 0x062), F3F(~2, ~0x34, ~0x062), "v,B,H", F_FLOAT, HWCAP_HPC, 0, v9d }, 2132 1.6 christos { "fhsubs", F3F(2, 0x34, 0x065), F3F(~2, ~0x34, ~0x065), "e,f,g", F_FLOAT, HWCAP_HPC, 0, v9d }, 2133 1.6 christos { "fhsubd", F3F(2, 0x34, 0x066), F3F(~2, ~0x34, ~0x066), "v,B,H", F_FLOAT, HWCAP_HPC, 0, v9d }, 2134 1.6 christos { "fnhadds", F3F(2, 0x34, 0x071), F3F(~2, ~0x34, ~0x071), "e,f,g", F_FLOAT, HWCAP_HPC, 0, v9d }, 2135 1.6 christos { "fnhaddd", F3F(2, 0x34, 0x072), F3F(~2, ~0x34, ~0x072), "v,B,H", F_FLOAT, HWCAP_HPC, 0, v9d }, 2136 1.6 christos { "fnsmuld", F3F(2, 0x34, 0x079), F3F(~2, ~0x34, ~0x079), "e,f,H", F_FLOAT, HWCAP_HPC, 0, v9d }, 2137 1.6 christos { "fpmaddx", F3(2, 0x37, 0)|OPF_LOW4(0), F3(~2, ~0x37, 0)|OPF_LOW4(~0), "v,B,5,H", F_FLOAT, HWCAP_IMA, 0, v9v }, 2138 1.6 christos { "fmadds", F3(2, 0x37, 0)|OPF_LOW4(1), F3(~2, ~0x37, 0)|OPF_LOW4(~1), "e,f,4,g", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2139 1.6 christos { "fmaddd", F3(2, 0x37, 0)|OPF_LOW4(2), F3(~2, ~0x37, 0)|OPF_LOW4(~2), "v,B,5,H", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2140 1.6 christos { "fpmaddxhi", F3(2, 0x37, 0)|OPF_LOW4(4), F3(~2, ~0x37, 0)|OPF_LOW4(~4), "v,B,5,H", F_FLOAT, HWCAP_IMA, 0, v9v }, 2141 1.6 christos { "fmsubs", F3(2, 0x37, 0)|OPF_LOW4(5), F3(~2, ~0x37, 0)|OPF_LOW4(~5), "e,f,4,g", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2142 1.6 christos { "fmsubd", F3(2, 0x37, 0)|OPF_LOW4(6), F3(~2, ~0x37, 0)|OPF_LOW4(~6), "v,B,5,H", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2143 1.6 christos { "fnmsubs", F3(2, 0x37, 0)|OPF_LOW4(9), F3(~2, ~0x37, 0)|OPF_LOW4(~9), "e,f,4,g", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2144 1.6 christos { "fnmsubd", F3(2, 0x37, 0)|OPF_LOW4(10), F3(~2, ~0x37, 0)|OPF_LOW4(~10), "v,B,5,H", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2145 1.6 christos { "fnmadds", F3(2, 0x37, 0)|OPF_LOW4(13), F3(~2, ~0x37, 0)|OPF_LOW4(~13), "e,f,4,g", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2146 1.6 christos { "fnmaddd", F3(2, 0x37, 0)|OPF_LOW4(14), F3(~2, ~0x37, 0)|OPF_LOW4(~14), "v,B,5,H", F_FLOAT, HWCAP_FMAF, 0, v9d }, 2147 1.6 christos { "fumadds", F3(2, 0x3f, 0)|OPF_LOW4(1), F3(~2, ~0x3f, 0)|OPF_LOW4(~1), "e,f,4,g", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2148 1.6 christos { "fumaddd", F3(2, 0x3f, 0)|OPF_LOW4(2), F3(~2, ~0x3f, 0)|OPF_LOW4(~2), "v,B,5,H", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2149 1.6 christos { "fumsubs", F3(2, 0x3f, 0)|OPF_LOW4(5), F3(~2, ~0x3f, 0)|OPF_LOW4(~5), "e,f,4,g", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2150 1.6 christos { "fumsubd", F3(2, 0x3f, 0)|OPF_LOW4(6), F3(~2, ~0x3f, 0)|OPF_LOW4(~6), "v,B,5,H", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2151 1.6 christos { "fnumsubs", F3(2, 0x3f, 0)|OPF_LOW4(9), F3(~2, ~0x3f, 0)|OPF_LOW4(~9), "e,f,4,g", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2152 1.6 christos { "fnumsubd", F3(2, 0x3f, 0)|OPF_LOW4(10), F3(~2, ~0x3f, 0)|OPF_LOW4(~10), "v,B,5,H", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2153 1.6 christos { "fnumadds", F3(2, 0x3f, 0)|OPF_LOW4(13), F3(~2, ~0x3f, 0)|OPF_LOW4(~13), "e,f,4,g", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2154 1.6 christos { "fnumaddd", F3(2, 0x3f, 0)|OPF_LOW4(14), F3(~2, ~0x3f, 0)|OPF_LOW4(~14), "v,B,5,H", F_FLOAT, HWCAP_FJFMAU, 0, v9v }, 2155 1.6 christos { "addxc", F3F(2, 0x36, 0x011), F3F(~2, ~0x36, ~0x011), "1,2,d", 0, HWCAP_VIS3, 0, v9d }, 2156 1.6 christos { "addxccc", F3F(2, 0x36, 0x013), F3F(~2, ~0x36, ~0x013), "1,2,d", 0, HWCAP_VIS3, 0, v9d }, 2157 1.6 christos { "umulxhi", F3F(2, 0x36, 0x016), F3F(~2, ~0x36, ~0x016), "1,2,d", 0, HWCAP_VIS3, 0, v9d }, 2158 1.6 christos { "lzcnt", F3F(2, 0x36, 0x017), F3F(~2, ~0x36, ~0x017), "2,d", 0, HWCAP_VIS3, 0, v9d }, 2159 1.6 christos { "lzd", F3F(2, 0x36, 0x017), F3F(~2, ~0x36, ~0x017), "2,d", F_ALIAS, HWCAP_VIS3, 0, v9d }, 2160 1.6 christos { "cmask8", F3F(2, 0x36, 0x01b), F3F(~2, ~0x36, ~0x01b), "2", 0, HWCAP_VIS3, 0, v9d }, 2161 1.6 christos { "cmask16", F3F(2, 0x36, 0x01d), F3F(~2, ~0x36, ~0x01d), "2", 0, HWCAP_VIS3, 0, v9d }, 2162 1.6 christos { "cmask32", F3F(2, 0x36, 0x01f), F3F(~2, ~0x36, ~0x01f), "2", 0, HWCAP_VIS3, 0, v9d }, 2163 1.6 christos { "fsll16", F3F(2, 0x36, 0x021), F3F(~2, ~0x36, ~0x021), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2164 1.6 christos { "fsrl16", F3F(2, 0x36, 0x023), F3F(~2, ~0x36, ~0x023), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2165 1.6 christos { "fsll32", F3F(2, 0x36, 0x025), F3F(~2, ~0x36, ~0x025), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2166 1.6 christos { "fsrl32", F3F(2, 0x36, 0x027), F3F(~2, ~0x36, ~0x027), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2167 1.6 christos { "fslas16", F3F(2, 0x36, 0x029), F3F(~2, ~0x36, ~0x029), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2168 1.6 christos { "fsra16", F3F(2, 0x36, 0x02b), F3F(~2, ~0x36, ~0x02b), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2169 1.6 christos { "fslas32", F3F(2, 0x36, 0x02d), F3F(~2, ~0x36, ~0x02d), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2170 1.6 christos { "fsra32", F3F(2, 0x36, 0x02f), F3F(~2, ~0x36, ~0x02f), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2171 1.6 christos { "pdistn", F3F(2, 0x36, 0x03f), F3F(~2, ~0x36, ~0x03f), "v,B,d", 0, HWCAP_VIS3, 0, v9d }, 2172 1.6 christos { "fmean16", F3F(2, 0x36, 0x040), F3F(~2, ~0x36, ~0x040), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2173 1.6 christos { "fpadd64", F3F(2, 0x36, 0x042), F3F(~2, ~0x36, ~0x042), "v,B,H", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, 2174 1.6 christos { "fchksm16", F3F(2, 0x36, 0x044), F3F(~2, ~0x36, ~0x044), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2175 1.6 christos { "fpsub64", F3F(2, 0x36, 0x046), F3F(~2, ~0x36, ~0x046), "v,B,H", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, 2176 1.6 christos { "fpadds16", F3F(2, 0x36, 0x058), F3F(~2, ~0x36, ~0x058), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2177 1.6 christos { "fpadds16s", F3F(2, 0x36, 0x059), F3F(~2, ~0x36, ~0x059), "e,f,g", 0, HWCAP_VIS3, 0, v9d }, 2178 1.6 christos { "fpadds32", F3F(2, 0x36, 0x05a), F3F(~2, ~0x36, ~0x05a), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2179 1.6 christos { "fpadds32s", F3F(2, 0x36, 0x05b), F3F(~2, ~0x36, ~0x05b), "e,f,g", 0, HWCAP_VIS3, 0, v9d }, 2180 1.6 christos { "fpsubs16", F3F(2, 0x36, 0x05c), F3F(~2, ~0x36, ~0x05c), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2181 1.6 christos { "fpsubs16s", F3F(2, 0x36, 0x05d), F3F(~2, ~0x36, ~0x05d), "e,f,g", 0, HWCAP_VIS3, 0, v9d }, 2182 1.6 christos { "fpsubs32", F3F(2, 0x36, 0x05e), F3F(~2, ~0x36, ~0x05e), "v,B,H", 0, HWCAP_VIS3, 0, v9d }, 2183 1.6 christos { "fpsubs32s", F3F(2, 0x36, 0x05f), F3F(~2, ~0x36, ~0x05f), "e,f,g", 0, HWCAP_VIS3, 0, v9d }, 2184 1.6 christos { "movdtox", F3F(2, 0x36, 0x110), F3F(~2, ~0x36, ~0x110), "B,d", F_FLOAT, HWCAP_VIS3, 0, v9d }, 2185 1.6 christos { "movstouw", F3F(2, 0x36, 0x111), F3F(~2, ~0x36, ~0x111), "f,d", F_FLOAT, HWCAP_VIS3, 0, v9d }, 2186 1.6 christos { "movstosw", F3F(2, 0x36, 0x113), F3F(~2, ~0x36, ~0x113), "f,d", F_FLOAT, HWCAP_VIS3, 0, v9d }, 2187 1.6 christos { "movxtod", F3F(2, 0x36, 0x118), F3F(~2, ~0x36, ~0x118), "2,H", F_FLOAT, HWCAP_VIS3, 0, v9d }, 2188 1.6 christos { "movwtos", F3F(2, 0x36, 0x119), F3F(~2, ~0x36, ~0x119), "2,g", F_FLOAT, HWCAP_VIS3, 0, v9d }, 2189 1.6 christos { "xmulx", F3F(2, 0x36, 0x115), F3F(~2, ~0x36, ~0x115), "1,2,d", 0, HWCAP_VIS3, 0, v9d }, 2190 1.6 christos { "xmulxhi", F3F(2, 0x36, 0x116), F3F(~2, ~0x36, ~0x116), "1,2,d", 0, HWCAP_VIS3, 0, v9d }, 2191 1.6 christos { "fpcmpule8", F3F(2, 0x36, 0x120), F3F(~2, ~0x36, ~0x120), "v,B,d", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, 2192 1.6 christos { "fucmple8", F3F(2, 0x36, 0x120), F3F(~2, ~0x36, ~0x120), "v,B,d", F_ALIAS, HWCAP_VIS3, 0, v9d }, 2193 1.6 christos { "fpcmpune8", F3F(2, 0x36, 0x122), F3F(~2, ~0x36, ~0x122), "v,B,d", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, 2194 1.6 christos { "fpcmpne8", F3F(2, 0x36, 0x122), F3F(~2, ~0x36, ~0x122), "v,B,d", F_PREF_ALIAS, HWCAP_VIS3, 0, v9d }, 2195 1.6 christos { "fucmpne8", F3F(2, 0x36, 0x122), F3F(~2, ~0x36, ~0x122), "v,B,d", F_ALIAS, HWCAP_VIS3, 0, v9d }, 2196 1.6 christos { "fpcmpugt8", F3F(2, 0x36, 0x128), F3F(~2, ~0x36, ~0x128), "v,B,d", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, 2197 1.6 christos { "fucmpgt8", F3F(2, 0x36, 0x128), F3F(~2, ~0x36, ~0x128), "v,B,d", F_ALIAS, HWCAP_VIS3, 0, v9d }, 2198 1.6 christos { "fpcmpueq8", F3F(2, 0x36, 0x12a), F3F(~2, ~0x36, ~0x12a), "v,B,d", 0, HWCAP_VIS3, HWCAP2_VIS3B, v9d }, 2199 1.6 christos { "fpcmpeq8", F3F(2, 0x36, 0x12a), F3F(~2, ~0x36, ~0x12a), "v,B,d", F_PREF_ALIAS, HWCAP_VIS3, 0, v9d }, 2200 1.6 christos { "fucmpeq8", F3F(2, 0x36, 0x12a), F3F(~2, ~0x36, ~0x12a), "v,B,d", F_ALIAS, HWCAP_VIS3, 0, v9d }, 2201 1.6 christos {"aes_kexpand0",F3F(2, 0x36, 0x130), F3F(~2, ~0x36, ~0x130), "v,B,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2202 1.6 christos {"aes_kexpand2",F3F(2, 0x36, 0x131), F3F(~2, ~0x36, ~0x131), "v,B,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2203 1.6 christos { "des_ip", F3F(2, 0x36, 0x134), F3F(~2, ~0x36, ~0x134), "v,H", F_FLOAT, HWCAP_DES, 0, v9e }, 2204 1.6 christos { "des_iip", F3F(2, 0x36, 0x135), F3F(~2, ~0x36, ~0x135), "v,H", F_FLOAT, HWCAP_DES, 0, v9e }, 2205 1.7 christos { "des_kexpand",F3F(2, 0x36, 0x136), F3F(~2, ~0x36, ~0x136), "v,X,H", F_FLOAT, HWCAP_DES, 0, v9e }, 2206 1.6 christos {"kasumi_fi_fi",F3F(2, 0x36, 0x138), F3F(~2, ~0x36, ~0x138), "v,B,H", F_FLOAT, HWCAP_KASUMI, 0, v9e }, 2207 1.6 christos { "camellia_fl",F3F(2, 0x36, 0x13c), F3F(~2, ~0x36, ~0x13c), "v,B,H", F_FLOAT, HWCAP_CAMELLIA, 0, v9e }, 2208 1.6 christos {"camellia_fli",F3F(2, 0x36, 0x13d), F3F(~2, ~0x36, ~0x13d), "v,B,H", F_FLOAT, HWCAP_CAMELLIA, 0, v9e }, 2209 1.6 christos { "md5", F3F(2, 0x36, 0x140), F3F(~2, ~0x36, ~0x140), "", F_FLOAT, HWCAP_MD5, 0, v9e }, 2210 1.6 christos { "sha1", F3F(2, 0x36, 0x141), F3F(~2, ~0x36, ~0x141), "", F_FLOAT, HWCAP_SHA1, 0, v9e }, 2211 1.8 christos { "sha256", F3F(2, 0x36, 0x142), F3F(~2, ~0x36, ~0x142), "", F_FLOAT, HWCAP_SHA256, 0, v9e }, 2212 1.6 christos { "sha512", F3F(2, 0x36, 0x143), F3F(~2, ~0x36, ~0x143), "", F_FLOAT, HWCAP_SHA512, 0, v9e }, 2213 1.6 christos { "sha3", F3F(2, 0x36, 0x144), F3F(~2, ~0x36, ~0x144), "", F_FLOAT, 0, HWCAP2_SHA3, m8 }, 2214 1.6 christos { "crc32c", F3F(2, 0x36, 0x147), F3F(~2, ~0x36, ~0x147), "v,B,H", F_FLOAT, HWCAP_CRC32C, 0, v9e }, 2215 1.6 christos { "xmpmul", F3F(2, 0x36, 0x148)|RD(1), F3F(~2, ~0x36, ~0x148)|RD(~1), "X", F_FLOAT, 0, HWCAP2_XMPMUL, v9m }, 2216 1.6 christos { "mpmul", F3F(2, 0x36, 0x148), F3F(~2, ~0x36, ~0x148), "X", F_FLOAT, HWCAP_MPMUL, 0, v9e }, 2217 1.6 christos { "xmontmul", F3F(2, 0x36, 0x149)|RD(1), F3F(~2, ~0x36, ~0x149)|RD(~1), "X", F_FLOAT, 0, HWCAP2_XMONT, v9m }, 2218 1.6 christos { "montmul", F3F(2, 0x36, 0x149), F3F(~2, ~0x36, ~0x149), "X", F_FLOAT, HWCAP_MONT, 0, v9e }, 2219 1.6 christos { "xmontsqr", F3F(2, 0x36, 0x14a)|RD(1), F3F(~2, ~0x36, ~0x14a)|RD(~1), "X", F_FLOAT, 0, HWCAP2_XMONT, v9m }, 2220 1.6 christos { "montsqr", F3F(2, 0x36, 0x14a), F3F(~2, ~0x36, ~0x14a), "X", F_FLOAT, HWCAP_MONT, 0, v9e }, 2221 1.6 christos {"aes_eround01", F3F4(2, 0x19, 0), F3F4(~2, ~0x19, ~0), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2222 1.6 christos {"aes_eround23", F3F4(2, 0x19, 1), F3F4(~2, ~0x19, ~1), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2223 1.6 christos {"aes_dround01", F3F4(2, 0x19, 2), F3F4(~2, ~0x19, ~2), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2224 1.6 christos {"aes_dround23", F3F4(2, 0x19, 3), F3F4(~2, ~0x19, ~3), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2225 1.6 christos {"aes_eround01_l",F3F4(2, 0x19, 4), F3F4(~2, ~0x19, ~4), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2226 1.6 christos {"aes_eround23_l",F3F4(2, 0x19, 5), F3F4(~2, ~0x19, ~5), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2227 1.6 christos {"aes_dround01_l",F3F4(2, 0x19, 6), F3F4(~2, ~0x19, ~6), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2228 1.6 christos {"aes_dround23_l",F3F4(2, 0x19, 7), F3F4(~2, ~0x19, ~7), "v,B,5,H", F_FLOAT, HWCAP_AES, 0, v9e }, 2229 1.6 christos {"aes_kexpand1", F3F4(2, 0x19, 8), F3F4(~2, ~0x19, ~8), "v,B,),H", F_FLOAT, HWCAP_AES, 0, v9e }, 2230 1.6 christos {"des_round", F3F4(2, 0x19, 9), F3F4(~2, ~0x19, ~9), "v,B,5,H", F_FLOAT, HWCAP_DES, 0, v9e }, 2231 1.6 christos {"kasumi_fl_xor", F3F4(2, 0x19, 10), F3F4(~2, ~0x19, ~10), "v,B,5,H", F_FLOAT, HWCAP_KASUMI, 0, v9e }, 2232 1.6 christos {"kasumi_fi_xor", F3F4(2, 0x19, 11), F3F4(~2, ~0x19, ~11), "v,B,5,H", F_FLOAT, HWCAP_KASUMI, 0, v9e }, 2233 1.6 christos {"camellia_f", F3F4(2, 0x19, 12), F3F4(~2, ~0x19, ~12), "v,B,5,H", F_FLOAT, HWCAP_CAMELLIA, 0, v9e }, 2234 1.6 christos { "flcmps", CMPFCC(0)|F3F(2, 0x36, 0x151), CMPFCC(~0)|F3F(~2, ~0x36, ~0x151), "6,e,f", F_FLOAT, HWCAP_HPC, 0, v9d }, 2235 1.6 christos { "flcmps", CMPFCC(1)|F3F(2, 0x36, 0x151), CMPFCC(~1)|F3F(~2, ~0x36, ~0x151), "7,e,f", F_FLOAT, HWCAP_HPC, 0, v9d }, 2236 1.6 christos { "flcmps", CMPFCC(2)|F3F(2, 0x36, 0x151), CMPFCC(~2)|F3F(~2, ~0x36, ~0x151), "8,e,f", F_FLOAT, HWCAP_HPC, 0, v9d }, 2237 1.6 christos { "flcmps", CMPFCC(3)|F3F(2, 0x36, 0x151), CMPFCC(~3)|F3F(~2, ~0x36, ~0x151), "9,e,f", F_FLOAT, HWCAP_HPC, 0, v9d }, 2238 1.6 christos { "flcmpd", CMPFCC(0)|F3F(2, 0x36, 0x152), CMPFCC(~0)|F3F(~2, ~0x36, ~0x152), "6,v,B", F_FLOAT, HWCAP_HPC, 0, v9d }, 2239 1.6 christos { "flcmpd", CMPFCC(1)|F3F(2, 0x36, 0x152), CMPFCC(~1)|F3F(~2, ~0x36, ~0x152), "7,v,B", F_FLOAT, HWCAP_HPC, 0, v9d }, 2240 1.6 christos { "flcmpd", CMPFCC(2)|F3F(2, 0x36, 0x152), CMPFCC(~2)|F3F(~2, ~0x36, ~0x152), "8,v,B", F_FLOAT, HWCAP_HPC, 0, v9d }, 2241 1.6 christos { "flcmpd", CMPFCC(3)|F3F(2, 0x36, 0x152), CMPFCC(~3)|F3F(~2, ~0x36, ~0x152), "9,v,B", F_FLOAT, HWCAP_HPC, 0, v9d }, 2242 1.6 christos 2243 1.6 christos { "mwait", F3(2, 0x30, 0)|RD(28), F3(~2, ~0x30, ~0)|RD(~28)|RS1_G0|ASI(~0), "2", 0, 0, HWCAP2_MWAIT, v9m }, /* mwait r */ 2244 1.6 christos { "mwait", F3(2, 0x30, 1)|RD(28), F3(~2, ~0x30, ~1)|RD(~28)|RS1_G0, "i", 0, 0, HWCAP2_MWAIT, v9m }, /* mwait imm */ 2245 1.6 christos 2246 1.6 christos /* Other SPARC5 and VIS4.0 instructions. */ 2247 1.6 christos 2248 1.6 christos { "subxc", F3(2, 0x36, 0)|OPF(0x41), F3(~2, ~0x36, ~0)|OPF(~0x41), "1,2,d", 0, 0, HWCAP2_SPARC5, v9m }, 2249 1.6 christos { "subxccc", F3(2, 0x36, 0)|OPF(0x43), F3(~2, ~0x36, ~0)|OPF(~0x43), "1,2,d", 0, 0, HWCAP2_SPARC5, v9m }, 2250 1.6 christos 2251 1.6 christos { "fpadd8", F3F(2, 0x36, 0x124), F3F(~2, ~0x36, ~0x124), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2252 1.6 christos { "fpadds8", F3F(2, 0x36, 0x126), F3F(~2, ~0x36, ~0x126), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2253 1.6 christos { "fpaddus8", F3F(2, 0x36, 0x127), F3F(~2, ~0x36, ~0x127), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2254 1.6 christos { "fpaddus16", F3F(2, 0x36, 0x123), F3F(~2, ~0x36, ~0x123), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2255 1.6 christos { "fpcmple8", F3F(2, 0x36, 0x034), F3F(~2, ~0x36, ~0x034), "v,B,d", 0, 0, HWCAP2_SPARC5, v9m }, 2256 1.6 christos { "fpcmpgt8", F3F(2, 0x36, 0x03c), F3F(~2, ~0x36, ~0x03c), "v,B,d", 0, 0, HWCAP2_SPARC5, v9m }, 2257 1.6 christos { "fpcmpule16", F3F(2, 0x36, 0x12e), F3F(~2, ~0x36, ~0x12e), "v,B,d", 0, 0, HWCAP2_SPARC5, v9m }, 2258 1.6 christos { "fpcmpugt16", F3F(2, 0x36, 0x12b), F3F(~2, ~0x36, ~0x12b), "v,B,d", 0, 0, HWCAP2_SPARC5, v9m }, 2259 1.6 christos { "fpcmpule32", F3F(2, 0x36, 0x12f), F3F(~2, ~0x36, ~0x12f), "v,B,d", 0, 0, HWCAP2_SPARC5, v9m }, 2260 1.6 christos { "fpcmpugt32", F3F(2, 0x36, 0x12c), F3F(~2, ~0x36, ~0x12c), "v,B,d", 0, 0, HWCAP2_SPARC5, v9m }, 2261 1.6 christos { "fpmax8", F3F(2, 0x36, 0x11d), F3F(~2, ~0x36, ~0x11d), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2262 1.6 christos { "fpmax16", F3F(2, 0x36, 0x11e), F3F(~2, ~0x36, ~0x11e), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2263 1.6 christos { "fpmax32", F3F(2, 0x36, 0x11f), F3F(~2, ~0x36, ~0x11f), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2264 1.6 christos { "fpmaxu8", F3F(2, 0x36, 0x15d), F3F(~2, ~0x36, ~0x15d), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2265 1.6 christos { "fpmaxu16", F3F(2, 0x36, 0x15e), F3F(~2, ~0x36, ~0x15e), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2266 1.6 christos { "fpmaxu32", F3F(2, 0x36, 0x15f), F3F(~2, ~0x36, ~0x15f), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2267 1.6 christos { "fpmin8", F3F(2, 0x36, 0x11a), F3F(~2, ~0x36, ~0x11a), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2268 1.6 christos { "fpmin16", F3F(2, 0x36, 0x11b), F3F(~2, ~0x36, ~0x11b), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2269 1.6 christos { "fpmin32", F3F(2, 0x36, 0x11c), F3F(~2, ~0x36, ~0x11c), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2270 1.6 christos { "fpminu8", F3F(2, 0x36, 0x15a), F3F(~2, ~0x36, ~0x15a), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2271 1.6 christos { "fpminu16", F3F(2, 0x36, 0x15b), F3F(~2, ~0x36, ~0x15b), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2272 1.6 christos { "fpminu32", F3F(2, 0x36, 0x15c), F3F(~2, ~0x36, ~0x15c), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2273 1.6 christos { "fpsub8", F3F(2, 0x36, 0x154), F3F(~2, ~0x36, ~0x154), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2274 1.6 christos { "fpsubs8", F3F(2, 0x36, 0x156), F3F(~2, ~0x36, ~0x156), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2275 1.1 christos { "fpsubus8", F3F(2, 0x36, 0x157), F3F(~2, ~0x36, ~0x157), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2276 1.8 christos { "fpsubus16", F3F(2, 0x36, 0x153), F3F(~2, ~0x36, ~0x153), "v,B,H", 0, 0, HWCAP2_SPARC5, v9m }, 2277 1.8 christos 2278 1.8 christos /* Other OSA2017 and M8 instructions. */ 2279 1.8 christos 2280 1.8 christos { "dictunpack", F3F(2, 0x36, 0x1c), F3F(~2, ~0x36, ~0x1c), "v,X,H", 0, 0, HWCAP2_DICTUNP, m8 }, 2281 1.8 christos 2282 1.8 christos #define fpcmpshl(cbits, opf) \ 2283 1.8 christos { "fpcmp" cbits "shl", F3F(2, 0x36, (opf)), F3F(~2, ~0x36, ~(opf)), "v,',|,d", 0, 0, HWCAP2_FPCMPSHL, m8 } 2284 1.8 christos 2285 1.8 christos fpcmpshl ("ule8", 0x190), 2286 1.8 christos fpcmpshl ("ugt8", 0x191), 2287 1.8 christos fpcmpshl ("eq8", 0x192), 2288 1.8 christos fpcmpshl ("ne8", 0x193), 2289 1.8 christos 2290 1.8 christos fpcmpshl ("ule16", 0x194), 2291 1.8 christos fpcmpshl ("ugt16", 0x195), 2292 1.8 christos fpcmpshl ("eq16", 0x196), 2293 1.8 christos fpcmpshl ("ne16", 0x197), 2294 1.8 christos 2295 1.8 christos fpcmpshl ("ule32", 0x198), 2296 1.8 christos fpcmpshl ("ugt32", 0x199), 2297 1.8 christos fpcmpshl ("eq32", 0x19a), 2298 1.8 christos fpcmpshl ("ne32", 0x19b), 2299 1.8 christos 2300 1.8 christos fpcmpshl ("de8", 0x45), 2301 1.8 christos fpcmpshl ("de16", 0x47), 2302 1.8 christos fpcmpshl ("de32", 0x4a), 2303 1.8 christos 2304 1.8 christos fpcmpshl ("ur8", 0x19c), 2305 1.8 christos fpcmpshl ("ur16", 0x19d), 2306 1.8 christos fpcmpshl ("ur32", 0x19e), 2307 1.8 christos 2308 1.8 christos #undef fpcmpshl 2309 1.8 christos 2310 1.8 christos #define fps64x(dir, opf) \ 2311 1.8 christos { "fps" dir "64x", F3F(2, 0x36, (opf)), F3F(~2, ~0x36, ~(opf)), "v,B,H", 0, 0, HWCAP2_SPARC6, m8 } 2312 1.8 christos 2313 1.8 christos fps64x ("ll", 0x106), 2314 1.8 christos fps64x ("ra", 0x10f), 2315 1.8 christos fps64x ("rl", 0x107), 2316 1.8 christos 2317 1.8 christos #undef fps64x 2318 1.8 christos 2319 1.8 christos #define ldm(width,opm,flags) \ 2320 1.8 christos { "ldm" width, F3(3, 0x31, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~0), "[1+2],d", (flags), 0, HWCAP2_SPARC6, m8 }, \ 2321 1.8 christos { "ldm" width, F3(3, 0x31, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~0)|RS2_G0, "[1],d", (flags), 0, HWCAP2_SPARC6, m8 }, /* ldm [rs1+%g0],d */ \ 2322 1.8 christos { "ldm" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm)), "[1+j],d", (flags), 0, HWCAP2_SPARC6, m8 }, \ 2323 1.8 christos { "ldm" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm)), "[j+1],d", (flags), 0, HWCAP2_SPARC6, m8 }, /* ldm [rs1+j],d */ \ 2324 1.8 christos { "ldm" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm))|RS1_G0, "[j],d", (flags), 0, HWCAP2_SPARC6, m8 }, \ 2325 1.8 christos { "ldm" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm))|SIMM10(~0), "[1],d", (flags), 0, HWCAP2_SPARC6, m8 } /* ldm [rs1+0],d */ 2326 1.8 christos 2327 1.8 christos ldm ("sh", 0x0, 0), 2328 1.8 christos ldm ("uh", 0x1, 0), 2329 1.8 christos ldm ("sw", 0x2, 0), 2330 1.8 christos ldm ("uw", 0x3, 0), 2331 1.8 christos /* Note that opm=0x4 is reserved. */ 2332 1.8 christos ldm ("x", 0x5, 0), 2333 1.8 christos ldm ("ux", 0x5, F_ALIAS), 2334 1.8 christos 2335 1.8 christos #undef ldm 2336 1.8 christos 2337 1.8 christos #define ldma(width,opm,flags) \ 2338 1.8 christos { "ldm" width "a", F3(3, 0x31, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~1), "[1+2]o,d", (flags), 0, HWCAP2_SPARC6, m8 }, \ 2339 1.8 christos { "ldm" width "a", F3(3, 0x31, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~1)|RS2_G0, "[1]o,d", (flags), 0, HWCAP2_SPARC6, m8 } 2340 1.8 christos 2341 1.8 christos ldma ("sh", 0x0, 0), 2342 1.8 christos ldma ("uh", 0x1, 0), 2343 1.8 christos ldma ("sw", 0x2, 0), 2344 1.8 christos ldma ("uw", 0x3, 0), 2345 1.8 christos /* Note that opm=0x4 is reserved. */ 2346 1.8 christos ldma ("x", 0x5, 0), 2347 1.8 christos ldma ("ux", 0x5, F_ALIAS), 2348 1.8 christos 2349 1.8 christos #undef ldma 2350 1.8 christos 2351 1.8 christos #define ldmf(width,opm,rd) \ 2352 1.8 christos { "ldmf" width, F3(3, 0x31, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~0), "[1+2]," rd, 0, 0, HWCAP2_SPARC6, m8 }, \ 2353 1.8 christos { "ldmf" width, F3(3, 0x31, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~0)|RS2_G0, "[1]," rd, 0, 0, HWCAP2_SPARC6, m8 }, /* ldmf [rs1+%g0],rd */ \ 2354 1.8 christos { "ldmf" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm)), "[1+j]," rd, 0, 0, HWCAP2_SPARC6, m8 }, \ 2355 1.8 christos { "ldmf" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm)), "[j+1]," rd, 0, 0, HWCAP2_SPARC6, m8 }, /* ldmf [rs1+j],rd */ \ 2356 1.8 christos { "ldmf" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm))|RS1_G0, "[j]," rd, 0, 0, HWCAP2_SPARC6, m8 }, \ 2357 1.8 christos { "ldmf" width, F3(3, 0x31, 1)|OPM((opm)), F3(~3, ~0x31, ~1)|OPM(~(opm))|SIMM10(~0), "[1]," rd, 0, 0, HWCAP2_SPARC6, m8 } /* ldmf [rs1+0],rd */ 2358 1.8 christos 2359 1.8 christos ldmf ("s", 0x6, "g"), 2360 1.8 christos ldmf ("d", 0x7, "H"), 2361 1.8 christos 2362 1.8 christos #undef ldmf 2363 1.8 christos 2364 1.8 christos #define ldmfa(width,opm,rd) \ 2365 1.8 christos { "ldmf" width "a", F3(3, 0x31, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~1), "[1+2]o," rd, 0, 0, HWCAP2_SPARC6, m8 }, \ 2366 1.8 christos { "ldmf" width "a", F3(3, 0x31, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x31, ~0)|OPM(~(opm))|OPMI(~1)|RS2_G0, "[1]o," rd, 0, 0, HWCAP2_SPARC6, m8} 2367 1.8 christos 2368 1.8 christos ldmfa ("s", 0x6, "g"), 2369 1.8 christos ldmfa ("d", 0x7, "H"), 2370 1.8 christos 2371 1.8 christos #undef ldmfa 2372 1.8 christos 2373 1.8 christos #define stm(width,opm) \ 2374 1.8 christos { "stm" width, F3(3, 0x35, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~0), "d,[1+2]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2375 1.8 christos { "stm" width, F3(3, 0x35, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~0)|RS2_G0, "d,[1]", 0, 0, HWCAP2_SPARC6, m8 }, /* stm d,[rs1+%g0] */ \ 2376 1.8 christos { "stm" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm)), "d,[1+j]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2377 1.8 christos { "stm" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm)), "d,[j+1]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2378 1.8 christos { "stm" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm))|RS1_G0, "d,[j]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2379 1.8 christos { "stm" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm))|SIMM10(~0), "d,[1]", 0, 0, HWCAP2_SPARC6, m8 } 2380 1.8 christos 2381 1.8 christos stm ("h", 0x1), 2382 1.8 christos stm ("w", 0x3), 2383 1.8 christos stm ("x", 0x5), 2384 1.8 christos 2385 1.8 christos #undef stm 2386 1.8 christos 2387 1.8 christos #define stma(width,opm) \ 2388 1.8 christos { "stm" width "a", F3(3, 0x35, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~1), "d,[1+2]o", 0, 0, HWCAP2_SPARC6, m8 }, \ 2389 1.8 christos { "stm" width "a", F3(3, 0x35, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~1)|RS2_G0, "d,[1]o", 0, 0, HWCAP2_SPARC6, m8 } 2390 1.8 christos 2391 1.8 christos stma ("h", 0x1), 2392 1.8 christos stma ("w", 0x3), 2393 1.8 christos stma ("x", 0x5), 2394 1.8 christos 2395 1.8 christos #undef stma 2396 1.8 christos 2397 1.8 christos #define stmf(width, opm, rd) \ 2398 1.8 christos { "stmf" width, F3(3, 0x35, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~0), rd ",[1+2]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2399 1.8 christos { "stmf" width, F3(3, 0x35, 0)|OPM((opm))|OPMI(0), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~0)|RS2_G0, rd ",[1]", 0, 0, HWCAP2_SPARC6, m8 }, /* stmf rd,[rs1+%g0] */ \ 2400 1.8 christos { "stmf" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm)), rd ",[1+j]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2401 1.8 christos { "stmf" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm)), rd ",[j+1]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2402 1.8 christos { "stmf" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm))|RS1_G0, rd ",[j]", 0, 0, HWCAP2_SPARC6, m8 }, \ 2403 1.8 christos { "stmf" width, F3(3, 0x35, 1)|OPM((opm)), F3(~3, ~0x35, ~1)|OPM(~(opm))|SIMM10(~0), rd ",[1]", 0, 0, HWCAP2_SPARC6, m8 } 2404 1.8 christos 2405 1.8 christos stmf ("s", 0x6, "g"), 2406 1.8 christos stmf ("d", 0x7, "H"), 2407 1.8 christos 2408 1.8 christos #define stmfa(width, opm, rd) \ 2409 1.8 christos { "stmf" width "a", F3(3, 0x35, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~1), rd ",[1+2]o", 0, 0, HWCAP2_SPARC6, m8 }, \ 2410 1.8 christos { "stmf" width "a", F3(3, 0x35, 0)|OPM((opm))|OPMI(1), F3(~3, ~0x35, ~0)|OPM(~(opm))|OPMI(~1)|RS2_G0, rd ",[1]o", 0, 0, HWCAP2_SPARC6, m8 } 2411 1.8 christos 2412 1.8 christos stmfa ("s", 0x6, "g"), 2413 1.8 christos stmfa ("d", 0x7, "H"), 2414 1.8 christos 2415 1.8 christos #undef stmfa 2416 1.8 christos 2417 1.8 christos #define on(op,fcn,hwcaps2) \ 2418 1.8 christos { "on" op, F3F(2, 0x36, 0x15)|ONFCN((fcn)), F3F(~2, ~0x36, ~0x15)|ONFCN(~(fcn)), ";,:,^", 0, 0, (hwcaps2), m8 } 2419 1.8 christos 2420 1.8 christos on ("add", 0x0, HWCAP2_ONADDSUB), 2421 1.8 christos on ("sub", 0x1, HWCAP2_ONADDSUB), 2422 1.8 christos on ("mul", 0x2, HWCAP2_ONMUL), 2423 1.8 christos on ("div", 0x3, HWCAP2_ONDIV), 2424 1.8 christos 2425 1.8 christos #undef on 2426 1.8 christos 2427 1.8 christos #define rev(what,width,fcn) \ 2428 1.8 christos { "rev" what width, F3F(2, 0x36, 0x1e)|REVFCN((fcn)), F3F(~2, ~0x36, ~0x1e)|REVFCN(~(fcn)), "1,d", 0, 0, HWCAP2_SPARC6, m8 } 2429 1.8 christos 2430 1.8 christos rev ("bits", "b", 0x0), 2431 1.8 christos rev ("bytes", "h", 0x1), 2432 1.8 christos rev ("bytes", "w", 0x2), 2433 1.8 christos rev ("bytes", "x", 0x3), 2434 1.8 christos 2435 1.8 christos #undef rev 2436 1.8 christos 2437 1.8 christos { "rle_burst", F3F(2, 0x36, 0x30), F3F(~2, ~0x36, ~0x30), "1,2,d", 0, 0, HWCAP2_RLE, m8 }, 2438 1.1 christos { "rle_length", F3F(2, 0x36, 0x32)|RS1(0), F3F(~2, ~0x36, ~0x32)|RS1(~0), "2,d", 0, 0, HWCAP2_RLE, m8 }, 2439 1.1 christos 2440 1.1 christos /* More v9 specific insns, these need to come last so they do not clash 2441 1.1 christos with v9a instructions such as "edge8" which looks like impdep1. */ 2442 1.3 christos 2443 1.3 christos #define IMPDEP(name, code) \ 2444 1.3 christos { name, F3(2, code, 0), F3(~2, ~code, ~0)|ASI(~0), "1,2,d", 0, 0, 0, v9notv9a }, \ 2445 1.3 christos { name, F3(2, code, 1), F3(~2, ~code, ~1), "1,i,d", 0, 0, 0, v9notv9a }, \ 2446 1.1 christos { name, F3(2, code, 0), F3(~2, ~code, ~0), "x,1,2,d", 0, 0, 0, v9notv9a }, \ 2447 1.1 christos { name, F3(2, code, 0), F3(~2, ~code, ~0), "x,e,f,g", 0, 0, 0, v9notv9a } 2448 1.1 christos 2449 1.1 christos IMPDEP ("impdep1", 0x36), 2450 1.1 christos IMPDEP ("impdep2", 0x37), 2451 1.1 christos 2452 1.1 christos #undef IMPDEP 2453 1.1 christos 2454 1.1 christos }; 2455 1.1 christos 2456 1.7 christos const int sparc_num_opcodes = ((sizeof sparc_opcodes)/(sizeof sparc_opcodes[0])); 2457 1.7 christos 2458 1.7 christos /* Handle ASI's. */ 2460 1.7 christos 2461 1.7 christos static sparc_asi asi_table[] = 2462 1.7 christos { 2463 1.7 christos /* These are in the v9 architecture manual. */ 2464 1.7 christos /* The shorter versions appear first, they're here because Sun's as has them. 2465 1.7 christos Sun's as uses #ASI_P_L instead of #ASI_PL (which appears in the 2466 1.7 christos UltraSPARC architecture manual). */ 2467 1.7 christos { 0x04, "#ASI_N", v9 }, 2468 1.7 christos { 0x0c, "#ASI_N_L", v9 }, 2469 1.7 christos { 0x10, "#ASI_AIUP", v9 }, 2470 1.7 christos { 0x11, "#ASI_AIUS", v9 }, 2471 1.7 christos { 0x18, "#ASI_AIUP_L", v9 }, 2472 1.7 christos { 0x19, "#ASI_AIUS_L", v9 }, 2473 1.7 christos { 0x80, "#ASI_P", v9 }, 2474 1.7 christos { 0x81, "#ASI_S", v9 }, 2475 1.7 christos { 0x82, "#ASI_PNF", v9 }, 2476 1.7 christos { 0x83, "#ASI_SNF", v9 }, 2477 1.7 christos { 0x88, "#ASI_P_L", v9 }, 2478 1.7 christos { 0x89, "#ASI_S_L", v9 }, 2479 1.7 christos { 0x8a, "#ASI_PNF_L", v9 }, 2480 1.7 christos { 0x8b, "#ASI_SNF_L", v9 }, 2481 1.7 christos { 0x04, "#ASI_NUCLEUS", v9 }, 2482 1.7 christos { 0x0c, "#ASI_NUCLEUS_LITTLE", v9 }, 2483 1.7 christos { 0x10, "#ASI_AS_IF_USER_PRIMARY", v9 }, 2484 1.7 christos { 0x11, "#ASI_AS_IF_USER_SECONDARY", v9 }, 2485 1.7 christos { 0x18, "#ASI_AS_IF_USER_PRIMARY_LITTLE", v9 }, 2486 1.7 christos { 0x19, "#ASI_AS_IF_USER_SECONDARY_LITTLE", v9 }, 2487 1.7 christos { 0x80, "#ASI_PRIMARY", v9 }, 2488 1.7 christos { 0x81, "#ASI_SECONDARY", v9 }, 2489 1.7 christos { 0x82, "#ASI_PRIMARY_NOFAULT", v9 }, 2490 1.7 christos { 0x83, "#ASI_SECONDARY_NOFAULT", v9 }, 2491 1.7 christos { 0x88, "#ASI_PRIMARY_LITTLE", v9 }, 2492 1.7 christos { 0x89, "#ASI_SECONDARY_LITTLE", v9 }, 2493 1.7 christos { 0x8a, "#ASI_PRIMARY_NOFAULT_LITTLE", v9 }, 2494 1.7 christos { 0x8b, "#ASI_SECONDARY_NOFAULT_LITTLE", v9 }, 2495 1.7 christos /* These are UltraSPARC and Niagara extensions. */ 2496 1.7 christos { 0x14, "#ASI_PHYS_USE_EC", v9b }, 2497 1.7 christos { 0x15, "#ASI_PHYS_BYPASS_EC_E", v9b }, 2498 1.7 christos { 0x16, "#ASI_BLK_AIUP_4V", v9c }, 2499 1.7 christos { 0x17, "#ASI_BLK_AIUS_4V", v9c }, 2500 1.7 christos { 0x1c, "#ASI_PHYS_USE_EC_L", v9b }, 2501 1.7 christos { 0x1d, "#ASI_PHYS_BYPASS_EC_E_L", v9b }, 2502 1.7 christos { 0x1e, "#ASI_BLK_AIUP_L_4V", v9c }, 2503 1.7 christos { 0x1f, "#ASI_BLK_AIUS_L_4V", v9c }, 2504 1.7 christos { 0x20, "#ASI_SCRATCHPAD", v9c }, 2505 1.8 christos { 0x21, "#ASI_MMU", v9c }, 2506 1.8 christos { 0x23, "#ASI_BLK_INIT_QUAD_LDD_AIUS", v9c }, 2507 1.7 christos { 0x24, "#ASI_NUCLEUS_QUAD_LDD", v9b }, 2508 1.7 christos { 0x24, "#ASI_CORE_COMMIT_COUNT", m8 }, 2509 1.7 christos { 0x24, "#ASI_CORE_SELECT_COUNT", m8 }, 2510 1.7 christos { 0x25, "#ASI_QUEUE", v9c }, 2511 1.7 christos { 0x26, "#ASI_QUAD_LDD_PHYS_4V", v9c }, 2512 1.7 christos { 0x2c, "#ASI_NUCLEUS_QUAD_LDD_L", v9b }, 2513 1.7 christos { 0x30, "#ASI_PCACHE_DATA_STATUS", v9b }, 2514 1.7 christos { 0x31, "#ASI_PCACHE_DATA", v9b }, 2515 1.7 christos { 0x32, "#ASI_PCACHE_TAG", v9b }, 2516 1.7 christos { 0x33, "#ASI_PCACHE_SNOOP_TAG", v9b }, 2517 1.7 christos { 0x34, "#ASI_QUAD_LDD_PHYS", v9b }, 2518 1.7 christos { 0x38, "#ASI_WCACHE_VALID_BITS", v9b }, 2519 1.7 christos { 0x39, "#ASI_WCACHE_DATA", v9b }, 2520 1.7 christos { 0x3a, "#ASI_WCACHE_TAG", v9b }, 2521 1.7 christos { 0x3b, "#ASI_WCACHE_SNOOP_TAG", v9b }, 2522 1.7 christos { 0x3c, "#ASI_QUAD_LDD_PHYS_L", v9b }, 2523 1.7 christos { 0x40, "#ASI_SRAM_FAST_INIT", v9b }, 2524 1.7 christos { 0x41, "#ASI_CORE_AVAILABLE", v9b }, 2525 1.7 christos { 0x41, "#ASI_CORE_ENABLE_STAT", v9b }, 2526 1.7 christos { 0x41, "#ASI_CORE_ENABLE", v9b }, 2527 1.7 christos { 0x41, "#ASI_XIR_STEERING", v9b }, 2528 1.7 christos { 0x41, "#ASI_CORE_RUNNING_RW", v9b }, 2529 1.7 christos { 0x41, "#ASI_CORE_RUNNING_W1S", v9b }, 2530 1.7 christos { 0x41, "#ASI_CORE_RUNNING_W1C", v9b }, 2531 1.7 christos { 0x41, "#ASI_CORE_RUNNING_STAT", v9b }, 2532 1.7 christos { 0x41, "#ASI_CMT_ERROR_STEERING", v9b }, 2533 1.7 christos { 0x45, "#ASI_LSU_CONTROL_REG", v9b }, 2534 1.7 christos { 0x45, "#ASI_DCU_CONTROL_REG", v9b }, 2535 1.7 christos { 0x46, "#ASI_DCACHE_DATA", v9b }, 2536 1.7 christos { 0x47, "#ASI_DCACHE_TAG", v9b }, 2537 1.7 christos { 0x48, "#ASI_INTR_DISPATCH_STAT", v9b }, 2538 1.7 christos { 0x49, "#ASI_INTR_RECEIVE", v9b }, 2539 1.7 christos { 0x4b, "#ASI_ESTATE_ERROR_EN", v9b }, 2540 1.8 christos { 0x4c, "#ASI_AFSR", v9b }, 2541 1.7 christos { 0x4d, "#ASI_AFAR", v9b }, 2542 1.7 christos { 0x4e, "#ASI_EC_TAG_DATA", v9b }, 2543 1.7 christos { 0x48, "#ASI_ARF_ECC_REG", m8 }, 2544 1.8 christos { 0x50, "#ASI_IMMU", v9b }, 2545 1.7 christos { 0x51, "#ASI_IMMU_TSB_8KB_PTR", v9b }, 2546 1.7 christos { 0x52, "#ASI_IMMU_TSB_64KB_PTR", v9b }, 2547 1.7 christos { 0x53, "#ASI_ITLB_PROBE", m8 }, 2548 1.7 christos { 0x54, "#ASI_ITLB_DATA_IN", v9b }, 2549 1.7 christos { 0x55, "#ASI_ITLB_DATA_ACCESS", v9b }, 2550 1.8 christos { 0x56, "#ASI_ITLB_TAG_READ", v9b }, 2551 1.7 christos { 0x57, "#ASI_IMMU_DEMAP", v9b }, 2552 1.7 christos { 0x58, "#ASI_DMMU", v9b }, 2553 1.8 christos { 0x58, "#ASI_DSFAR", m8 }, 2554 1.7 christos { 0x59, "#ASI_DMMU_TSB_8KB_PTR", v9b }, 2555 1.8 christos { 0x5a, "#ASI_DMMU_TSB_64KB_PTR", v9b }, 2556 1.7 christos { 0x5a, "#ASI_DTLB_PROBE_PRIMARY", m8 }, 2557 1.7 christos { 0x5b, "#ASI_DMMU_TSB_DIRECT_PTR", v9b }, 2558 1.7 christos { 0x5b, "#ASI_DTLB_PROBE_REAL", m8 }, 2559 1.7 christos { 0x5c, "#ASI_DTLB_DATA_IN", v9b }, 2560 1.7 christos { 0x5d, "#ASI_DTLB_DATA_ACCESS", v9b }, 2561 1.7 christos { 0x5e, "#ASI_DTLB_TAG_READ", v9b }, 2562 1.7 christos { 0x5f, "#ASI_DMMU_DEMAP", v9b }, 2563 1.7 christos { 0x60, "#ASI_IIU_INST_TRAP", v9b }, 2564 1.8 christos { 0x63, "#ASI_INTR_ID", v9b }, 2565 1.7 christos { 0x63, "#ASI_CORE_ID", v9b }, 2566 1.7 christos { 0x63, "#ASI_CESR_ID", v9b }, 2567 1.7 christos { 0x64, "#ASI_CORE_SELECT_COMMIT_NHT", m8 }, 2568 1.7 christos { 0x66, "#ASI_IC_INSTR", v9b }, 2569 1.7 christos { 0x67, "#ASI_IC_TAG", v9b }, 2570 1.7 christos { 0x68, "#ASI_IC_STAG", v9b }, 2571 1.7 christos { 0x6f, "#ASI_BRPRED_ARRAY", v9b }, 2572 1.7 christos { 0x70, "#ASI_BLK_AIUP", v9b }, 2573 1.7 christos { 0x71, "#ASI_BLK_AIUS", v9b }, 2574 1.7 christos { 0x72, "#ASI_MCU_CTRL_REG", v9b }, 2575 1.7 christos { 0x74, "#ASI_EC_DATA", v9b }, 2576 1.7 christos { 0x75, "#ASI_EC_CTRL", v9b }, 2577 1.7 christos { 0x76, "#ASI_EC_W", v9b }, 2578 1.7 christos { 0x77, "#ASI_INTR_W", v9b }, 2579 1.7 christos { 0x77, "#ASI_INTR_DATAN_W", v9b }, 2580 1.7 christos { 0x77, "#ASI_INTR_DISPATCH_W", v9b }, 2581 1.7 christos { 0x78, "#ASI_BLK_AIUPL", v9b }, 2582 1.7 christos { 0x79, "#ASI_BLK_AIUSL", v9b }, 2583 1.7 christos { 0x7e, "#ASI_EC_R", v9b }, 2584 1.7 christos { 0x7f, "#ASI_INTR_R", v9b }, 2585 1.7 christos { 0x7f, "#ASI_INTR_DATAN_R", v9b }, 2586 1.7 christos { 0xc0, "#ASI_PST8_P", v9b }, 2587 1.7 christos { 0xc1, "#ASI_PST8_S", v9b }, 2588 1.7 christos { 0xc2, "#ASI_PST16_P", v9b }, 2589 1.7 christos { 0xc3, "#ASI_PST16_S", v9b }, 2590 1.7 christos { 0xc4, "#ASI_PST32_P", v9b }, 2591 1.7 christos { 0xc5, "#ASI_PST32_S", v9b }, 2592 1.7 christos { 0xc8, "#ASI_PST8_PL", v9b }, 2593 1.7 christos { 0xc9, "#ASI_PST8_SL", v9b }, 2594 1.7 christos { 0xca, "#ASI_PST16_PL", v9b }, 2595 1.7 christos { 0xcb, "#ASI_PST16_SL", v9b }, 2596 1.7 christos { 0xcc, "#ASI_PST32_PL", v9b }, 2597 1.7 christos { 0xcd, "#ASI_PST32_SL", v9b }, 2598 1.7 christos { 0xd0, "#ASI_FL8_P", v9b }, 2599 1.7 christos { 0xd1, "#ASI_FL8_S", v9b }, 2600 1.7 christos { 0xd2, "#ASI_FL16_P", v9b }, 2601 1.7 christos { 0xd3, "#ASI_FL16_S", v9b }, 2602 1.7 christos { 0xd8, "#ASI_FL8_PL", v9b }, 2603 1.7 christos { 0xd9, "#ASI_FL8_SL", v9b }, 2604 1.7 christos { 0xda, "#ASI_FL16_PL", v9b }, 2605 1.7 christos { 0xdb, "#ASI_FL16_SL", v9b }, 2606 1.7 christos { 0xe0, "#ASI_BLK_COMMIT_P", v9b }, 2607 1.7 christos { 0xe1, "#ASI_BLK_COMMIT_S", v9b }, 2608 1.7 christos { 0xe2, "#ASI_BLK_INIT_QUAD_LDD_P", v9b }, 2609 1.7 christos { 0xf0, "#ASI_BLK_P", v9b }, 2610 1.7 christos { 0xf1, "#ASI_BLK_S", v9b }, 2611 1.7 christos { 0xf8, "#ASI_BLK_PL", v9b }, 2612 1.7 christos { 0xf9, "#ASI_BLK_SL", v9b }, 2613 1.7 christos { 0x22, "#ASI_TWINX_AIUP", v9c }, 2614 1.7 christos { 0x23, "#ASI_TWINX_AIUS", v9c }, 2615 1.7 christos { 0x26, "#ASI_TWINX_REAL", v9c }, 2616 1.7 christos { 0x27, "#ASI_TWINX_N", v9c }, 2617 1.7 christos { 0x2A, "#ASI_TWINX_AIUP_L", v9c }, 2618 1.7 christos { 0x2B, "#ASI_TWINX_AIUS_L", v9c }, 2619 1.7 christos { 0x2E, "#ASI_TWINX_REAL_L", v9c }, 2620 1.7 christos { 0x2F, "#ASI_TWINX_NL", v9c }, 2621 1.7 christos { 0xE2, "#ASI_TWINX_P", v9c }, 2622 1.7 christos { 0xE3, "#ASI_TWINX_S", v9c }, 2623 1.7 christos { 0xEA, "#ASI_TWINX_PL", v9c }, 2624 1.7 christos { 0xEB, "#ASI_TWINX_SL", v9c }, 2625 1.7 christos /* These are ASIs from UA2005, UA2007, OSA2011, & OSA 2015 */ 2626 1.7 christos { 0x12, "#ASI_MAIUP", v9m }, 2627 1.7 christos { 0x13, "#ASI_MAIUS", v9m }, 2628 1.7 christos { 0x14, "#ASI_REAL", v9c }, 2629 1.7 christos { 0x15, "#ASI_REAL_IO", v9c }, 2630 1.7 christos { 0x1c, "#ASI_REAL_L", v9c }, 2631 1.7 christos { 0x1d, "#ASI_REAL_IO_L", v9c }, 2632 1.7 christos { 0x30, "#ASI_AIPP", v9d }, 2633 1.7 christos { 0x31, "#ASI_AIPS", v9d }, 2634 1.7 christos { 0x36, "#ASI_AIPN", v9d }, 2635 1.7 christos { 0x38, "#ASI_AIPP_L", v9d }, 2636 1.7 christos { 0x39, "#ASI_AIPS_L", v9d }, 2637 1.7 christos { 0x3e, "#ASI_AIPN_L", v9d }, 2638 1.7 christos { 0x42, "#ASI_INST_MASK_REG", v9d }, 2639 1.7 christos { 0x42, "#ASI_LSU_DIAG_REG", v9d }, 2640 1.7 christos { 0x43, "#ASI_ERROR_INJECT_REG", v9d }, 2641 1.7 christos { 0x48, "#ASI_IRF_ECC_REG", v9d }, 2642 1.7 christos { 0x49, "#ASI_FRF_ECC_REG", v9d }, 2643 1.7 christos { 0x4e, "#ASI_SPARC_PWR_MGMT", v9d }, 2644 1.7 christos { 0x4f, "#ASI_HYP_SCRATCHPAD", v9c }, 2645 1.7 christos { 0x59, "#ASI_SCRATCHPAD_ACCESS", v9d }, 2646 1.7 christos { 0x5a, "#ASI_TICK_ACCESS", v9d }, 2647 1.7 christos { 0x5b, "#ASI_TSA_ACCESS", v9d }, 2648 1.7 christos { 0xb0, "#ASI_PIC", v9e }, 2649 1.7 christos { 0xf2, "#ASI_STBI_PM", v9e }, 2650 1.7 christos { 0xf3, "#ASI_STBI_SM", v9e }, 2651 1.7 christos { 0xfa, "#ASI_STBI_PLM", v9e }, 2652 1.7 christos { 0xfb, "#ASI_STBI_SLM", v9e }, 2653 1.7 christos { 0, 0, 0 } 2654 1.7 christos }; 2655 1.7 christos 2656 1.7 christos /* Return the a pointer to the matching sparc_asi struct, NULL if not found. */ 2657 1.7 christos 2658 1.7 christos const sparc_asi * 2659 1.7 christos sparc_encode_asi (const char *name) 2660 1.7 christos { 2661 1.7 christos const sparc_asi *p; 2662 1.7 christos 2663 1.7 christos for (p = asi_table; p->name; ++p) 2664 1.7 christos if (strcmp (name, p->name) == 0) 2665 1.7 christos return p; 2666 1.7 christos 2667 1.7 christos return NULL; 2668 1.7 christos } 2669 1.7 christos 2670 1.7 christos /* Return the name for ASI value VALUE or NULL if not found. */ 2671 1.7 christos 2672 1.7 christos const char * 2673 1.7 christos sparc_decode_asi (int value) 2674 1.7 christos { 2675 1.7 christos const sparc_asi *p; 2676 1.7 christos 2677 1.7 christos for (p = asi_table; p->name; ++p) 2678 1.7 christos if (value == p->value) 2679 1.7 christos return p->name; 2680 1.7 christos 2681 1.1 christos return NULL; 2682 1.1 christos } 2683 1.1 christos 2684 1.1 christos /* Utilities for argument parsing. */ 2686 1.1 christos 2687 1.1 christos typedef struct 2688 1.1 christos { 2689 1.1 christos int value; 2690 1.1 christos const char *name; 2691 1.1 christos } arg; 2692 1.1 christos 2693 1.1 christos /* Look up NAME in TABLE. */ 2694 1.1 christos 2695 1.1 christos static int 2696 1.1 christos lookup_name (const arg *table, const char *name) 2697 1.1 christos { 2698 1.1 christos const arg *p; 2699 1.1 christos 2700 1.1 christos for (p = table; p->name; ++p) 2701 1.1 christos if (strcmp (name, p->name) == 0) 2702 1.1 christos return p->value; 2703 1.1 christos 2704 1.1 christos return -1; 2705 1.1 christos } 2706 1.1 christos 2707 1.1 christos /* Look up VALUE in TABLE. */ 2708 1.1 christos 2709 1.1 christos static const char * 2710 1.1 christos lookup_value (const arg *table, int value) 2711 1.1 christos { 2712 1.1 christos const arg *p; 2713 1.1 christos 2714 1.1 christos for (p = table; p->name; ++p) 2715 1.1 christos if (value == p->value) 2716 1.1 christos return p->name; 2717 1.1 christos 2718 1.1 christos return NULL; 2719 1.1 christos } 2720 1.1 christos 2721 1.1 christos /* Handle membar masks. */ 2722 1.1 christos 2723 1.1 christos static arg membar_table[] = 2724 1.1 christos { 2725 1.1 christos { 0x40, "#Sync" }, 2726 1.1 christos { 0x20, "#MemIssue" }, 2727 1.1 christos { 0x10, "#Lookaside" }, 2728 1.1 christos { 0x08, "#StoreStore" }, 2729 1.1 christos { 0x04, "#LoadStore" }, 2730 1.1 christos { 0x02, "#StoreLoad" }, 2731 1.1 christos { 0x01, "#LoadLoad" }, 2732 1.1 christos { 0, 0 } 2733 1.1 christos }; 2734 1.1 christos 2735 1.1 christos /* Return the value for membar arg NAME, or -1 if not found. */ 2736 1.1 christos 2737 1.1 christos int 2738 1.1 christos sparc_encode_membar (const char *name) 2739 1.1 christos { 2740 1.1 christos return lookup_name (membar_table, name); 2741 1.1 christos } 2742 1.1 christos 2743 1.1 christos /* Return the name for membar value VALUE or NULL if not found. */ 2744 1.1 christos 2745 1.1 christos const char * 2746 1.1 christos sparc_decode_membar (int value) 2747 1.1 christos { 2748 1.1 christos return lookup_value (membar_table, value); 2749 1.1 christos } 2750 1.1 christos 2751 1.1 christos /* Handle prefetch args. */ 2753 1.1 christos 2754 1.1 christos static arg prefetch_table[] = 2755 1.1 christos { 2756 1.1 christos { 0, "#n_reads" }, 2757 1.1 christos { 1, "#one_read" }, 2758 1.1 christos { 2, "#n_writes" }, 2759 1.1 christos { 3, "#one_write" }, 2760 1.1 christos { 4, "#page" }, 2761 1.1 christos { 16, "#invalidate" }, 2762 1.1 christos { 17, "#unified", }, 2763 1.1 christos { 20, "#n_reads_strong", }, 2764 1.1 christos { 21, "#one_read_strong", }, 2765 1.1 christos { 22, "#n_writes_strong", }, 2766 1.1 christos { 23, "#one_write_strong", }, 2767 1.1 christos { 0, 0 } 2768 1.1 christos }; 2769 1.1 christos 2770 1.1 christos /* Return the value for prefetch arg NAME, or -1 if not found. */ 2771 1.1 christos 2772 1.1 christos int 2773 1.1 christos sparc_encode_prefetch (const char *name) 2774 1.1 christos { 2775 1.1 christos return lookup_name (prefetch_table, name); 2776 1.1 christos } 2777 1.1 christos 2778 1.1 christos /* Return the name for prefetch value VALUE or NULL if not found. */ 2779 1.1 christos 2780 1.1 christos const char * 2781 1.1 christos sparc_decode_prefetch (int value) 2782 1.1 christos { 2783 1.1 christos return lookup_value (prefetch_table, value); 2784 1.1 christos } 2785 1.1 christos 2786 1.1 christos /* Handle sparclet coprocessor registers. */ 2788 1.1 christos 2789 1.1 christos static arg sparclet_cpreg_table[] = 2790 1.1 christos { 2791 1.1 christos { 0, "%ccsr" }, 2792 1.1 christos { 1, "%ccfr" }, 2793 1.1 christos { 2, "%cccrcr" }, 2794 1.1 christos { 3, "%ccpr" }, 2795 1.1 christos { 4, "%ccsr2" }, 2796 1.1 christos { 5, "%cccrr" }, 2797 1.1 christos { 6, "%ccrstr" }, 2798 1.1 christos { 0, 0 } 2799 1.1 christos }; 2800 1.1 christos 2801 1.1 christos /* Return the value for sparclet cpreg arg NAME, or -1 if not found. */ 2802 1.1 christos 2803 1.1 christos int 2804 1.1 christos sparc_encode_sparclet_cpreg (const char *name) 2805 1.1 christos { 2806 1.1 christos return lookup_name (sparclet_cpreg_table, name); 2807 1.1 christos } 2808 1.1 christos 2809 1.1 christos /* Return the name for sparclet cpreg value VALUE or NULL if not found. */ 2810 2811 const char * 2812 sparc_decode_sparclet_cpreg (int value) 2813 { 2814 return lookup_value (sparclet_cpreg_table, value); 2815 } 2816