rs2 167 arch/riscv/net/bpf_jit_comp.c static u32 rv_r_insn(u8 funct7, u8 rs2, u8 rs1, u8 funct3, u8 rd, u8 opcode) rs2 169 arch/riscv/net/bpf_jit_comp.c return (funct7 << 25) | (rs2 << 20) | (rs1 << 15) | (funct3 << 12) | rs2 179 arch/riscv/net/bpf_jit_comp.c static u32 rv_s_insn(u16 imm11_0, u8 rs2, u8 rs1, u8 funct3, u8 opcode) rs2 183 arch/riscv/net/bpf_jit_comp.c return (imm11_5 << 25) | (rs2 << 20) | (rs1 << 15) | (funct3 << 12) | rs2 187 arch/riscv/net/bpf_jit_comp.c static u32 rv_sb_insn(u16 imm12_1, u8 rs2, u8 rs1, u8 funct3, u8 opcode) rs2 192 arch/riscv/net/bpf_jit_comp.c return (imm12 << 25) | (rs2 << 20) | (rs1 << 15) | (funct3 << 12) | rs2 211 arch/riscv/net/bpf_jit_comp.c static u32 rv_amo_insn(u8 funct5, u8 aq, u8 rl, u8 rs2, u8 rs1, rs2 216 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(funct7, rs2, rs1, funct3, rd, opcode); rs2 229 arch/riscv/net/bpf_jit_comp.c static u32 rv_addw(u8 rd, u8 rs1, u8 rs2) rs2 231 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 0, rd, 0x3b); rs2 234 arch/riscv/net/bpf_jit_comp.c static u32 rv_add(u8 rd, u8 rs1, u8 rs2) rs2 236 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 0, rd, 0x33); rs2 239 arch/riscv/net/bpf_jit_comp.c static u32 rv_subw(u8 rd, u8 rs1, u8 rs2) rs2 241 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0x20, rs2, rs1, 0, rd, 0x3b); rs2 244 arch/riscv/net/bpf_jit_comp.c static u32 rv_sub(u8 rd, u8 rs1, u8 rs2) rs2 246 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0x20, rs2, rs1, 0, rd, 0x33); rs2 249 arch/riscv/net/bpf_jit_comp.c static u32 rv_and(u8 rd, u8 rs1, u8 rs2) rs2 251 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 7, rd, 0x33); rs2 254 arch/riscv/net/bpf_jit_comp.c static u32 rv_or(u8 rd, u8 rs1, u8 rs2) rs2 256 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 6, rd, 0x33); rs2 259 arch/riscv/net/bpf_jit_comp.c static u32 rv_xor(u8 rd, u8 rs1, u8 rs2) rs2 261 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 4, rd, 0x33); rs2 264 arch/riscv/net/bpf_jit_comp.c static u32 rv_mulw(u8 rd, u8 rs1, u8 rs2) rs2 266 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(1, rs2, rs1, 0, rd, 0x3b); rs2 269 arch/riscv/net/bpf_jit_comp.c static u32 rv_mul(u8 rd, u8 rs1, u8 rs2) rs2 271 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(1, rs2, rs1, 0, rd, 0x33); rs2 274 arch/riscv/net/bpf_jit_comp.c static u32 rv_divuw(u8 rd, u8 rs1, u8 rs2) rs2 276 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(1, rs2, rs1, 5, rd, 0x3b); rs2 279 arch/riscv/net/bpf_jit_comp.c static u32 rv_divu(u8 rd, u8 rs1, u8 rs2) rs2 281 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(1, rs2, rs1, 5, rd, 0x33); rs2 284 arch/riscv/net/bpf_jit_comp.c static u32 rv_remuw(u8 rd, u8 rs1, u8 rs2) rs2 286 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(1, rs2, rs1, 7, rd, 0x3b); rs2 289 arch/riscv/net/bpf_jit_comp.c static u32 rv_remu(u8 rd, u8 rs1, u8 rs2) rs2 291 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(1, rs2, rs1, 7, rd, 0x33); rs2 294 arch/riscv/net/bpf_jit_comp.c static u32 rv_sllw(u8 rd, u8 rs1, u8 rs2) rs2 296 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 1, rd, 0x3b); rs2 299 arch/riscv/net/bpf_jit_comp.c static u32 rv_sll(u8 rd, u8 rs1, u8 rs2) rs2 301 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 1, rd, 0x33); rs2 304 arch/riscv/net/bpf_jit_comp.c static u32 rv_srlw(u8 rd, u8 rs1, u8 rs2) rs2 306 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 5, rd, 0x3b); rs2 309 arch/riscv/net/bpf_jit_comp.c static u32 rv_srl(u8 rd, u8 rs1, u8 rs2) rs2 311 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0, rs2, rs1, 5, rd, 0x33); rs2 314 arch/riscv/net/bpf_jit_comp.c static u32 rv_sraw(u8 rd, u8 rs1, u8 rs2) rs2 316 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0x20, rs2, rs1, 5, rd, 0x3b); rs2 319 arch/riscv/net/bpf_jit_comp.c static u32 rv_sra(u8 rd, u8 rs1, u8 rs2) rs2 321 arch/riscv/net/bpf_jit_comp.c return rv_r_insn(0x20, rs2, rs1, 5, rd, 0x33); rs2 384 arch/riscv/net/bpf_jit_comp.c static u32 rv_beq(u8 rs1, u8 rs2, u16 imm12_1) rs2 386 arch/riscv/net/bpf_jit_comp.c return rv_sb_insn(imm12_1, rs2, rs1, 0, 0x63); rs2 389 arch/riscv/net/bpf_jit_comp.c static u32 rv_bltu(u8 rs1, u8 rs2, u16 imm12_1) rs2 391 arch/riscv/net/bpf_jit_comp.c return rv_sb_insn(imm12_1, rs2, rs1, 6, 0x63); rs2 394 arch/riscv/net/bpf_jit_comp.c static u32 rv_bgeu(u8 rs1, u8 rs2, u16 imm12_1) rs2 396 arch/riscv/net/bpf_jit_comp.c return rv_sb_insn(imm12_1, rs2, rs1, 7, 0x63); rs2 399 arch/riscv/net/bpf_jit_comp.c static u32 rv_bne(u8 rs1, u8 rs2, u16 imm12_1) rs2 401 arch/riscv/net/bpf_jit_comp.c return rv_sb_insn(imm12_1, rs2, rs1, 1, 0x63); rs2 404 arch/riscv/net/bpf_jit_comp.c static u32 rv_blt(u8 rs1, u8 rs2, u16 imm12_1) rs2 406 arch/riscv/net/bpf_jit_comp.c return rv_sb_insn(imm12_1, rs2, rs1, 4, 0x63); rs2 409 arch/riscv/net/bpf_jit_comp.c static u32 rv_bge(u8 rs1, u8 rs2, u16 imm12_1) rs2 411 arch/riscv/net/bpf_jit_comp.c return rv_sb_insn(imm12_1, rs2, rs1, 5, 0x63); rs2 414 arch/riscv/net/bpf_jit_comp.c static u32 rv_sb(u8 rs1, u16 imm11_0, u8 rs2) rs2 416 arch/riscv/net/bpf_jit_comp.c return rv_s_insn(imm11_0, rs2, rs1, 0, 0x23); rs2 419 arch/riscv/net/bpf_jit_comp.c static u32 rv_sh(u8 rs1, u16 imm11_0, u8 rs2) rs2 421 arch/riscv/net/bpf_jit_comp.c return rv_s_insn(imm11_0, rs2, rs1, 1, 0x23); rs2 424 arch/riscv/net/bpf_jit_comp.c static u32 rv_sw(u8 rs1, u16 imm11_0, u8 rs2) rs2 426 arch/riscv/net/bpf_jit_comp.c return rv_s_insn(imm11_0, rs2, rs1, 2, 0x23); rs2 429 arch/riscv/net/bpf_jit_comp.c static u32 rv_sd(u8 rs1, u16 imm11_0, u8 rs2) rs2 431 arch/riscv/net/bpf_jit_comp.c return rv_s_insn(imm11_0, rs2, rs1, 3, 0x23); rs2 454 arch/riscv/net/bpf_jit_comp.c static u32 rv_amoadd_w(u8 rd, u8 rs2, u8 rs1, u8 aq, u8 rl) rs2 456 arch/riscv/net/bpf_jit_comp.c return rv_amo_insn(0, aq, rl, rs2, rs1, 2, rd, 0x2f); rs2 459 arch/riscv/net/bpf_jit_comp.c static u32 rv_amoadd_d(u8 rd, u8 rs2, u8 rs1, u8 aq, u8 rl) rs2 461 arch/riscv/net/bpf_jit_comp.c return rv_amo_insn(0, aq, rl, rs2, rs1, 3, rd, 0x2f); rs2 71 arch/sparc/kernel/unaligned_32.c static inline void maybe_flush_windows(unsigned int rs1, unsigned int rs2, rs2 74 arch/sparc/kernel/unaligned_32.c if(rs2 >= 16 || rs1 >= 16 || rd >= 16) { rs2 139 arch/sparc/kernel/unaligned_32.c unsigned int rs2 = insn & 0x1f; rs2 146 arch/sparc/kernel/unaligned_32.c maybe_flush_windows(rs1, rs2, rd); rs2 147 arch/sparc/kernel/unaligned_32.c return (fetch_reg(rs1, regs) + fetch_reg(rs2, regs)); rs2 155 arch/sparc/kernel/unaligned_32.c unsigned int rs2 = insn & 0x1f; rs2 162 arch/sparc/kernel/unaligned_32.c maybe_flush_windows(rs1, rs2, rd); rs2 163 arch/sparc/kernel/unaligned_32.c return (safe_fetch_reg(rs1, regs) + safe_fetch_reg(rs2, regs)); rs2 104 arch/sparc/kernel/unaligned_64.c static inline void maybe_flush_windows(unsigned int rs1, unsigned int rs2, rs2 107 arch/sparc/kernel/unaligned_64.c if (rs2 >= 16 || rs1 >= 16 || rd >= 16) { rs2 174 arch/sparc/kernel/unaligned_64.c unsigned int rs2 = insn & 0x1f; rs2 181 arch/sparc/kernel/unaligned_64.c maybe_flush_windows(rs1, rs2, rd, from_kernel); rs2 182 arch/sparc/kernel/unaligned_64.c addr = (fetch_reg(rs1, regs) + fetch_reg(rs2, regs)); rs2 140 arch/sparc/kernel/visemul.c static inline void maybe_flush_windows(unsigned int rs1, unsigned int rs2, rs2 143 arch/sparc/kernel/visemul.c if (rs2 >= 16 || rs1 >= 16 || rd >= 16) { rs2 296 arch/sparc/kernel/visemul.c unsigned long orig_rs1, rs1, orig_rs2, rs2, rd_val; rs2 301 arch/sparc/kernel/visemul.c orig_rs2 = rs2 = fetch_reg(RS2(insn), regs); rs2 305 arch/sparc/kernel/visemul.c rs2 = rs2 & 0xffffffff; rs2 312 arch/sparc/kernel/visemul.c right = edge8_tab[rs2 & 0x7].right; rs2 317 arch/sparc/kernel/visemul.c right = edge8_tab_l[rs2 & 0x7].right; rs2 323 arch/sparc/kernel/visemul.c right = edge16_tab[(rs2 >> 1) & 0x3].right; rs2 329 arch/sparc/kernel/visemul.c right = edge16_tab_l[(rs2 >> 1) & 0x3].right; rs2 335 arch/sparc/kernel/visemul.c right = edge32_tab[(rs2 >> 2) & 0x1].right; rs2 341 arch/sparc/kernel/visemul.c right = edge32_tab_l[(rs2 >> 2) & 0x1].right; rs2 345 arch/sparc/kernel/visemul.c if ((rs1 & ~0x7UL) == (rs2 & ~0x7UL)) rs2 374 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, rd_val; rs2 379 arch/sparc/kernel/visemul.c rs2 = fetch_reg(RS2(insn), regs); rs2 381 arch/sparc/kernel/visemul.c bits = (rs2 > 5 ? 5 : rs2); rs2 408 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, rd_val, gsr; rs2 412 arch/sparc/kernel/visemul.c rs2 = fetch_reg(RS2(insn), regs); rs2 413 arch/sparc/kernel/visemul.c rd_val = rs1 + rs2; rs2 425 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, rd_val; rs2 431 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 441 arch/sparc/kernel/visemul.c byte = (rs2 >> ((which-8)*8)) & 0xff; rs2 451 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, *rd, rd_val; rs2 455 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 464 arch/sparc/kernel/visemul.c s2 = (rs2 >> (56 - (i * 8))) & 0xff; rs2 480 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, gsr, scale, rd_val; rs2 488 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 492 arch/sparc/kernel/visemul.c s16 src = (rs2 >> (byte * 16UL)) & 0xffffUL; rs2 511 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 515 arch/sparc/kernel/visemul.c s32 src = (rs2 >> (word * 32UL)); rs2 533 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 538 arch/sparc/kernel/visemul.c s32 src = (rs2 >> (word * 32UL)); rs2 556 arch/sparc/kernel/visemul.c rs2 = fps_regval(f, RS2(insn)); rs2 561 arch/sparc/kernel/visemul.c u8 src = (rs2 >> (byte * 8)) & 0xff; rs2 573 arch/sparc/kernel/visemul.c rs2 = fps_regval(f, RS2(insn)); rs2 575 arch/sparc/kernel/visemul.c rd_val = (((rs2 & 0x000000ff) << 0) | rs2 577 arch/sparc/kernel/visemul.c ((rs2 & 0x0000ff00) << 8) | rs2 579 arch/sparc/kernel/visemul.c ((rs2 & 0x00ff0000) << 16) | rs2 581 arch/sparc/kernel/visemul.c ((rs2 & 0xff000000) << 24) | rs2 592 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, rd_val; rs2 599 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 604 arch/sparc/kernel/visemul.c s16 src2 = (rs2 >> (byte * 16)) & 0xffff; rs2 624 arch/sparc/kernel/visemul.c rs2 = fps_regval(f, RS2(insn)); rs2 627 arch/sparc/kernel/visemul.c src2 = rs2 >> (opf == FMUL8x16AU_OPF ? 16 : 0); rs2 648 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 659 arch/sparc/kernel/visemul.c src2 = ((rs2 >> (16 * byte)) & 0xffff); rs2 678 arch/sparc/kernel/visemul.c rs2 = fps_regval(f, RS2(insn)); rs2 689 arch/sparc/kernel/visemul.c src2 = ((rs2 >> (16 * byte)) & 0xffff); rs2 708 arch/sparc/kernel/visemul.c unsigned long rs1, rs2, rd_val, i; rs2 711 arch/sparc/kernel/visemul.c rs2 = fpd_regval(f, RS2(insn)); rs2 719 arch/sparc/kernel/visemul.c s16 b = (rs2 >> (i * 16)) & 0xffff; rs2 729 arch/sparc/kernel/visemul.c s32 b = (rs2 >> (i * 32)) & 0xffffffff; rs2 739 arch/sparc/kernel/visemul.c s16 b = (rs2 >> (i * 16)) & 0xffff; rs2 749 arch/sparc/kernel/visemul.c s32 b = (rs2 >> (i * 32)) & 0xffffffff; rs2 759 arch/sparc/kernel/visemul.c s16 b = (rs2 >> (i * 16)) & 0xffff; rs2 769 arch/sparc/kernel/visemul.c s32 b = (rs2 >> (i * 32)) & 0xffffffff; rs2 779 arch/sparc/kernel/visemul.c s16 b = (rs2 >> (i * 16)) & 0xffff; rs2 789 arch/sparc/kernel/visemul.c s32 b = (rs2 >> (i * 32)) & 0xffffffff; rs2 284 arch/sparc/math-emu/math_32.c argp rs1 = NULL, rs2 = NULL, rd = NULL; rs2 390 arch/sparc/math-emu/math_32.c rs2 = (argp)&fregs[freg]; rs2 392 arch/sparc/math-emu/math_32.c case 7: FP_UNPACK_QP (QB, rs2); break; rs2 393 arch/sparc/math-emu/math_32.c case 6: FP_UNPACK_DP (DB, rs2); break; rs2 394 arch/sparc/math-emu/math_32.c case 5: FP_UNPACK_SP (SB, rs2); break; rs2 452 arch/sparc/math-emu/math_32.c case FMOVS: rd->s = rs2->s; break; rs2 453 arch/sparc/math-emu/math_32.c case FABSS: rd->s = rs2->s & 0x7fffffff; break; rs2 454 arch/sparc/math-emu/math_32.c case FNEGS: rd->s = rs2->s ^ 0x80000000; break; rs2 460 arch/sparc/math-emu/math_32.c case FITOS: IR = rs2->s; FP_FROM_INT_S (SR, IR, 32, int); break; rs2 461 arch/sparc/math-emu/math_32.c case FITOD: IR = rs2->s; FP_FROM_INT_D (DR, IR, 32, int); break; rs2 462 arch/sparc/math-emu/math_32.c case FITOQ: IR = rs2->s; FP_FROM_INT_Q (QR, IR, 32, int); break; rs2 359 arch/sparc/math-emu/math_64.c argp rs1 = NULL, rs2 = NULL, rd = NULL; rs2 398 arch/sparc/math-emu/math_64.c case 1: rs2 = (argp)&f->regs[freg]; rs2 401 arch/sparc/math-emu/math_64.c rs2 = (argp)&zero; rs2 405 arch/sparc/math-emu/math_64.c case 7: FP_UNPACK_QP (QB, rs2); break; rs2 406 arch/sparc/math-emu/math_64.c case 6: FP_UNPACK_DP (DB, rs2); break; rs2 407 arch/sparc/math-emu/math_64.c case 5: FP_UNPACK_SP (SB, rs2); break; rs2 457 arch/sparc/math-emu/math_64.c case FMOVQ: rd->q[0] = rs2->q[0]; rd->q[1] = rs2->q[1]; break; rs2 458 arch/sparc/math-emu/math_64.c case FABSQ: rd->q[0] = rs2->q[0] & 0x7fffffffffffffffUL; rd->q[1] = rs2->q[1]; break; rs2 459 arch/sparc/math-emu/math_64.c case FNEGQ: rd->q[0] = rs2->q[0] ^ 0x8000000000000000UL; rd->q[1] = rs2->q[1]; break; rs2 468 arch/sparc/math-emu/math_64.c case FITOQ: IR = rs2->s; FP_FROM_INT_Q (QR, IR, 32, int); break; rs2 469 arch/sparc/math-emu/math_64.c case FXTOQ: XR = rs2->d; FP_FROM_INT_Q (QR, XR, 64, long); break; rs2 471 arch/sparc/math-emu/math_64.c case FXTOS: XR = rs2->d; FP_FROM_INT_S (SR, XR, 64, long); break; rs2 472 arch/sparc/math-emu/math_64.c case FXTOD: XR = rs2->d; FP_FROM_INT_D (DR, XR, 64, long); break; rs2 474 arch/sparc/math-emu/math_64.c case FITOS: IR = rs2->s; FP_FROM_INT_S (SR, IR, 32, int); break; rs2 476 arch/sparc/math-emu/math_64.c case FITOD: IR = rs2->s; FP_FROM_INT_D (DR, IR, 32, int); break; rs2 1260 arch/sparc/net/bpf_jit_comp_64.c u32 opcode = 0, rs2; rs2 1280 arch/sparc/net/bpf_jit_comp_64.c rs2 = S13(off); rs2 1283 arch/sparc/net/bpf_jit_comp_64.c rs2 = RS2(tmp); rs2 1285 arch/sparc/net/bpf_jit_comp_64.c emit(opcode | RS1(src) | rs2 | RD(dst), ctx); rs2 1297 arch/sparc/net/bpf_jit_comp_64.c u32 opcode = 0, rs2; rs2 1322 arch/sparc/net/bpf_jit_comp_64.c rs2 = S13(off); rs2 1326 arch/sparc/net/bpf_jit_comp_64.c rs2 = RS2(tmp); rs2 1328 arch/sparc/net/bpf_jit_comp_64.c emit(opcode | RS1(dst) | rs2 | RD(tmp2), ctx); rs2 1338 arch/sparc/net/bpf_jit_comp_64.c u32 opcode = 0, rs2; rs2 1359 arch/sparc/net/bpf_jit_comp_64.c rs2 = S13(off); rs2 1363 arch/sparc/net/bpf_jit_comp_64.c rs2 = RS2(tmp); rs2 1365 arch/sparc/net/bpf_jit_comp_64.c emit(opcode | RS1(dst) | rs2 | RD(src), ctx);