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

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

Issue 682643002: Add vrint{a,n,p,m,z} instructions to arm assembler. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressing comments. Created 6 years, 1 month 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 | Annotate | Revision Log
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 3076 matching lines...) Expand 10 before | Expand all | Expand 10 after
3087 // Vd(15-12) | 101(11-9) | sz=1(8) | 11(7-6) | M(5) | 0(4) | Vm(3-0) 3087 // Vd(15-12) | 101(11-9) | sz=1(8) | 11(7-6) | M(5) | 0(4) | Vm(3-0)
3088 int vd, d; 3088 int vd, d;
3089 dst.split_code(&vd, &d); 3089 dst.split_code(&vd, &d);
3090 int vm, m; 3090 int vm, m;
3091 src.split_code(&vm, &m); 3091 src.split_code(&vm, &m);
3092 emit(cond | 0x1D*B23 | d*B22 | 0x3*B20 | B16 | vd*B12 | 0x5*B9 | B8 | 0x3*B6 | 3092 emit(cond | 0x1D*B23 | d*B22 | 0x3*B20 | B16 | vd*B12 | 0x5*B9 | B8 | 0x3*B6 |
3093 m*B5 | vm); 3093 m*B5 | vm);
3094 } 3094 }
3095 3095
3096 3096
3097 void Assembler::vrinta(const DwVfpRegister dst, const DwVfpRegister src) {
3098 // cond=kSpecialCondition(31-28) | 11101(27-23)| D(22) | 11(21-20) |
3099 // 10(19-18) | RM=00(17-16) | Vd(15-12) | 101(11-9) | sz=1(8) | 01(7-6) |
3100 // M(5) | 0(4) | Vm(3-0)
3101 int vd, d;
Rodolph Perfetta 2014/10/29 12:37:53 DCHECK(CpuFeature::IsSupported(ARMv8)); I miss tha
sigurds 2014/10/29 15:25:05 Done.
3102 dst.split_code(&vd, &d);
3103 int vm, m;
3104 src.split_code(&vm, &m);
3105 emit(kSpecialCondition | 0x1D * B23 | d * B22 | 0x3 * B20 | B19 | vd * B12 |
3106 0x5 * B9 | B8 | B6 | m * B5 | vm);
3107 }
3108
3109
3110 void Assembler::vrintn(const DwVfpRegister dst, const DwVfpRegister src) {
3111 // cond=kSpecialCondition(31-28) | 11101(27-23)| D(22) | 11(21-20) |
3112 // 10(19-18) | RM=01(17-16) | Vd(15-12) | 101(11-9) | sz=1(8) | 01(7-6) |
3113 // M(5) | 0(4) | Vm(3-0)
3114 int vd, d;
3115 dst.split_code(&vd, &d);
3116 int vm, m;
3117 src.split_code(&vm, &m);
3118 emit(kSpecialCondition | 0x1D * B23 | d * B22 | 0x3 * B20 | B19 | 0x1 * B16 |
3119 vd * B12 | 0x5 * B9 | B8 | B6 | m * B5 | vm);
3120 }
3121
3122
3123 void Assembler::vrintp(const DwVfpRegister dst, const DwVfpRegister src) {
3124 // cond=kSpecialCondition(31-28) | 11101(27-23)| D(22) | 11(21-20) |
3125 // 10(19-18) | RM=10(17-16) | Vd(15-12) | 101(11-9) | sz=1(8) | 01(7-6) |
3126 // M(5) | 0(4) | Vm(3-0)
3127 int vd, d;
3128 dst.split_code(&vd, &d);
3129 int vm, m;
3130 src.split_code(&vm, &m);
3131 emit(kSpecialCondition | 0x1D * B23 | d * B22 | 0x3 * B20 | B19 | 0x2 * B16 |
3132 vd * B12 | 0x5 * B9 | B8 | B6 | m * B5 | vm);
3133 }
3134
3135
3136 void Assembler::vrintm(const DwVfpRegister dst, const DwVfpRegister src) {
3137 // cond=kSpecialCondition(31-28) | 11101(27-23)| D(22) | 11(21-20) |
3138 // 10(19-18) | RM=11(17-16) | Vd(15-12) | 101(11-9) | sz=1(8) | 01(7-6) |
3139 // M(5) | 0(4) | Vm(3-0)
3140 int vd, d;
3141 dst.split_code(&vd, &d);
3142 int vm, m;
3143 src.split_code(&vm, &m);
3144 emit(kSpecialCondition | 0x1D * B23 | d * B22 | 0x3 * B20 | B19 | 0x3 * B16 |
3145 vd * B12 | 0x5 * B9 | B8 | B6 | m * B5 | vm);
3146 }
3147
3148
3149 void Assembler::vrintz(const DwVfpRegister dst, const DwVfpRegister src,
3150 const Condition cond) {
3151 // cond(31-28) | 11101(27-23)| D(22) | 11(21-20) | 011(19-17) | 0(16) |
3152 // Vd(15-12) | 101(11-9) | sz=1(8) | op=1(7) | 1(6) | M(5) | 0(4) | Vm(3-0)
3153 int vd, d;
3154 dst.split_code(&vd, &d);
3155 int vm, m;
3156 src.split_code(&vm, &m);
3157 emit(cond | 0x1D * B23 | d * B22 | 0x3 * B20 | 0x3 * B17 | vd * B12 |
3158 0x5 * B9 | B8 | B7 | B6 | m * B5 | vm);
3159 }
3160
3161
3097 // Support for NEON. 3162 // Support for NEON.
3098 3163
3099 void Assembler::vld1(NeonSize size, 3164 void Assembler::vld1(NeonSize size,
3100 const NeonListOperand& dst, 3165 const NeonListOperand& dst,
3101 const NeonMemOperand& src) { 3166 const NeonMemOperand& src) {
3102 // Instruction details available in ARM DDI 0406C.b, A8.8.320. 3167 // Instruction details available in ARM DDI 0406C.b, A8.8.320.
3103 // 1111(31-28) | 01000(27-23) | D(22) | 10(21-20) | Rn(19-16) | 3168 // 1111(31-28) | 01000(27-23) | D(22) | 10(21-20) | Rn(19-16) |
3104 // Vd(15-12) | type(11-8) | size(7-6) | align(5-4) | Rm(3-0) 3169 // Vd(15-12) | type(11-8) | size(7-6) | align(5-4) | Rm(3-0)
3105 DCHECK(CpuFeatures::IsSupported(NEON)); 3170 DCHECK(CpuFeatures::IsSupported(NEON));
3106 int vd, d; 3171 int vd, d;
(...skipping 747 matching lines...) Expand 10 before | Expand all | Expand 10 after
3854 assm->instr_at_put( 3919 assm->instr_at_put(
3855 rinfo.pc(), Assembler::SetLdrRegisterImmediateOffset(instr, offset)); 3920 rinfo.pc(), Assembler::SetLdrRegisterImmediateOffset(instr, offset));
3856 } 3921 }
3857 } 3922 }
3858 } 3923 }
3859 3924
3860 3925
3861 } } // namespace v8::internal 3926 } } // namespace v8::internal
3862 3927
3863 #endif // V8_TARGET_ARCH_ARM 3928 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/assembler-arm.h ('k') | src/arm/constants-arm.h » ('j') | src/arm/disasm-arm.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698