Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(258)

Side by Side Diff: src/ia32/assembler-ia32.cc

Issue 2916093002: [ia32][wasm] Support AVX instructions for I32x4Splat/ReplaceLane/ExtractLane (Closed)
Patch Set: Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/ia32/assembler-ia32.h ('k') | src/ia32/disasm-ia32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions 5 // modification, are permitted provided that the following conditions
6 // are met: 6 // are met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 2665 matching lines...) Expand 10 before | Expand all | Expand 10 after
2676 2676
2677 2677
2678 void Assembler::psrlq(XMMRegister dst, XMMRegister src) { 2678 void Assembler::psrlq(XMMRegister dst, XMMRegister src) {
2679 EnsureSpace ensure_space(this); 2679 EnsureSpace ensure_space(this);
2680 EMIT(0x66); 2680 EMIT(0x66);
2681 EMIT(0x0F); 2681 EMIT(0x0F);
2682 EMIT(0xD3); 2682 EMIT(0xD3);
2683 emit_sse_operand(dst, src); 2683 emit_sse_operand(dst, src);
2684 } 2684 }
2685 2685
2686 2686 void Assembler::pshufd(XMMRegister dst, const Operand& src, uint8_t shuffle) {
2687 void Assembler::pshufd(XMMRegister dst, XMMRegister src, uint8_t shuffle) {
2688 EnsureSpace ensure_space(this); 2687 EnsureSpace ensure_space(this);
2689 EMIT(0x66); 2688 EMIT(0x66);
2690 EMIT(0x0F); 2689 EMIT(0x0F);
2691 EMIT(0x70); 2690 EMIT(0x70);
2692 emit_sse_operand(dst, src); 2691 emit_sse_operand(dst, src);
2693 EMIT(shuffle); 2692 EMIT(shuffle);
2694 } 2693 }
2695 2694
2696 2695
2697 void Assembler::pextrd(const Operand& dst, XMMRegister src, int8_t offset) { 2696 void Assembler::pextrd(const Operand& dst, XMMRegister src, int8_t offset) {
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
2877 vinstr(0x71, iop, dst, Operand(src), k66, k0F, kWIG); 2876 vinstr(0x71, iop, dst, Operand(src), k66, k0F, kWIG);
2878 EMIT(imm8); 2877 EMIT(imm8);
2879 } 2878 }
2880 2879
2881 void Assembler::vpsrad(XMMRegister dst, XMMRegister src, int8_t imm8) { 2880 void Assembler::vpsrad(XMMRegister dst, XMMRegister src, int8_t imm8) {
2882 XMMRegister iop = {4}; 2881 XMMRegister iop = {4};
2883 vinstr(0x72, iop, dst, Operand(src), k66, k0F, kWIG); 2882 vinstr(0x72, iop, dst, Operand(src), k66, k0F, kWIG);
2884 EMIT(imm8); 2883 EMIT(imm8);
2885 } 2884 }
2886 2885
2886 void Assembler::vpshufd(XMMRegister dst, const Operand& src, uint8_t shuffle) {
2887 vinstr(0x70, dst, xmm0, src, k66, k0F, kWIG);
2888 EMIT(shuffle);
2889 }
2890
2891 void Assembler::vpextrd(const Operand& dst, XMMRegister src, int8_t offset) {
2892 vinstr(0x16, src, xmm0, dst, k66, k0F3A, kWIG);
2893 EMIT(offset);
2894 }
2895
2896 void Assembler::vpinsrd(XMMRegister dst, XMMRegister src1, const Operand& src2,
2897 int8_t offset) {
2898 vinstr(0x22, dst, src1, src2, k66, k0F3A, kWIG);
2899 EMIT(offset);
2900 }
2901
2887 void Assembler::bmi1(byte op, Register reg, Register vreg, const Operand& rm) { 2902 void Assembler::bmi1(byte op, Register reg, Register vreg, const Operand& rm) {
2888 DCHECK(IsEnabled(BMI1)); 2903 DCHECK(IsEnabled(BMI1));
2889 EnsureSpace ensure_space(this); 2904 EnsureSpace ensure_space(this);
2890 emit_vex_prefix(vreg, kLZ, kNone, k0F38, kW0); 2905 emit_vex_prefix(vreg, kLZ, kNone, k0F38, kW0);
2891 EMIT(op); 2906 EMIT(op);
2892 emit_operand(reg, rm); 2907 emit_operand(reg, rm);
2893 } 2908 }
2894 2909
2895 2910
2896 void Assembler::tzcnt(Register dst, const Operand& src) { 2911 void Assembler::tzcnt(Register dst, const Operand& src) {
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
3173 } 3188 }
3174 RelocInfo rinfo(pc_, rmode, data, NULL); 3189 RelocInfo rinfo(pc_, rmode, data, NULL);
3175 reloc_info_writer.Write(&rinfo); 3190 reloc_info_writer.Write(&rinfo);
3176 } 3191 }
3177 3192
3178 3193
3179 } // namespace internal 3194 } // namespace internal
3180 } // namespace v8 3195 } // namespace v8
3181 3196
3182 #endif // V8_TARGET_ARCH_IA32 3197 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/assembler-ia32.h ('k') | src/ia32/disasm-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698