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

Side by Side Diff: src/full-codegen/mips64/full-codegen-mips64.cc

Issue 1250733005: SIMD.js Add the other SIMD Phase 1 types. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Don't run downloaded SIMD value type tests. Created 5 years, 4 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/full-codegen/mips/full-codegen-mips.cc ('k') | src/full-codegen/ppc/full-codegen-ppc.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_MIPS64 7 #if V8_TARGET_ARCH_MIPS64
8 8
9 // Note on Mips implementation: 9 // Note on Mips implementation:
10 // 10 //
(...skipping 3404 matching lines...) Expand 10 before | Expand all | Expand 10 after
3415 __ JumpIfSmi(v0, if_false); 3415 __ JumpIfSmi(v0, if_false);
3416 __ GetObjectType(v0, a1, a1); 3416 __ GetObjectType(v0, a1, a1);
3417 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); 3417 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
3418 Split(ge, a1, Operand(FIRST_SPEC_OBJECT_TYPE), 3418 Split(ge, a1, Operand(FIRST_SPEC_OBJECT_TYPE),
3419 if_true, if_false, fall_through); 3419 if_true, if_false, fall_through);
3420 3420
3421 context()->Plug(if_true, if_false); 3421 context()->Plug(if_true, if_false);
3422 } 3422 }
3423 3423
3424 3424
3425 void FullCodeGenerator::EmitIsSimdObject(CallRuntime* expr) {
3426 ZoneList<Expression*>* args = expr->arguments();
3427 DCHECK(args->length() == 1);
3428
3429 VisitForAccumulatorValue(args->at(0));
3430
3431 Label materialize_true, materialize_false;
3432 Label* if_true = NULL;
3433 Label* if_false = NULL;
3434 Label* fall_through = NULL;
3435 context()->PrepareTest(&materialize_true, &materialize_false, &if_true,
3436 &if_false, &fall_through);
3437
3438 __ JumpIfSmi(v0, if_false);
3439 Register map = a1;
3440 Register type_reg = a2;
3441 __ GetObjectType(v0, map, type_reg);
3442 __ Subu(type_reg, type_reg, Operand(FIRST_SIMD_VALUE_TYPE));
3443 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
3444 Split(ls, type_reg, Operand(LAST_SIMD_VALUE_TYPE - FIRST_SIMD_VALUE_TYPE),
3445 if_true, if_false, fall_through);
3446
3447 context()->Plug(if_true, if_false);
3448 }
3449
3450
3425 void FullCodeGenerator::EmitIsUndetectableObject(CallRuntime* expr) { 3451 void FullCodeGenerator::EmitIsUndetectableObject(CallRuntime* expr) {
3426 ZoneList<Expression*>* args = expr->arguments(); 3452 ZoneList<Expression*>* args = expr->arguments();
3427 DCHECK(args->length() == 1); 3453 DCHECK(args->length() == 1);
3428 3454
3429 VisitForAccumulatorValue(args->at(0)); 3455 VisitForAccumulatorValue(args->at(0));
3430 3456
3431 Label materialize_true, materialize_false; 3457 Label materialize_true, materialize_false;
3432 Label* if_true = NULL; 3458 Label* if_true = NULL;
3433 Label* if_false = NULL; 3459 Label* if_false = NULL;
3434 Label* fall_through = NULL; 3460 Label* fall_through = NULL;
(...skipping 1667 matching lines...) Expand 10 before | Expand all | Expand 10 after
5102 Split(eq, a1, Operand(zero_reg), 5128 Split(eq, a1, Operand(zero_reg),
5103 if_true, if_false, fall_through); 5129 if_true, if_false, fall_through);
5104 } else if (String::Equals(check, factory->symbol_string())) { 5130 } else if (String::Equals(check, factory->symbol_string())) {
5105 __ JumpIfSmi(v0, if_false); 5131 __ JumpIfSmi(v0, if_false);
5106 __ GetObjectType(v0, v0, a1); 5132 __ GetObjectType(v0, v0, a1);
5107 Split(eq, a1, Operand(SYMBOL_TYPE), if_true, if_false, fall_through); 5133 Split(eq, a1, Operand(SYMBOL_TYPE), if_true, if_false, fall_through);
5108 } else if (String::Equals(check, factory->float32x4_string())) { 5134 } else if (String::Equals(check, factory->float32x4_string())) {
5109 __ JumpIfSmi(v0, if_false); 5135 __ JumpIfSmi(v0, if_false);
5110 __ GetObjectType(v0, v0, a1); 5136 __ GetObjectType(v0, v0, a1);
5111 Split(eq, a1, Operand(FLOAT32X4_TYPE), if_true, if_false, fall_through); 5137 Split(eq, a1, Operand(FLOAT32X4_TYPE), if_true, if_false, fall_through);
5138 } else if (String::Equals(check, factory->int32x4_string())) {
5139 __ JumpIfSmi(v0, if_false);
5140 __ GetObjectType(v0, v0, a1);
5141 Split(eq, a1, Operand(INT32X4_TYPE), if_true, if_false, fall_through);
5142 } else if (String::Equals(check, factory->bool32x4_string())) {
5143 __ JumpIfSmi(v0, if_false);
5144 __ GetObjectType(v0, v0, a1);
5145 Split(eq, a1, Operand(BOOL32X4_TYPE), if_true, if_false, fall_through);
5146 } else if (String::Equals(check, factory->int16x8_string())) {
5147 __ JumpIfSmi(v0, if_false);
5148 __ GetObjectType(v0, v0, a1);
5149 Split(eq, a1, Operand(INT16X8_TYPE), if_true, if_false, fall_through);
5150 } else if (String::Equals(check, factory->bool16x8_string())) {
5151 __ JumpIfSmi(v0, if_false);
5152 __ GetObjectType(v0, v0, a1);
5153 Split(eq, a1, Operand(BOOL16X8_TYPE), if_true, if_false, fall_through);
5154 } else if (String::Equals(check, factory->int8x16_string())) {
5155 __ JumpIfSmi(v0, if_false);
5156 __ GetObjectType(v0, v0, a1);
5157 Split(eq, a1, Operand(INT8X16_TYPE), if_true, if_false, fall_through);
5158 } else if (String::Equals(check, factory->bool8x16_string())) {
5159 __ JumpIfSmi(v0, if_false);
5160 __ GetObjectType(v0, v0, a1);
5161 Split(eq, a1, Operand(BOOL8X16_TYPE), if_true, if_false, fall_through);
5112 } else if (String::Equals(check, factory->boolean_string())) { 5162 } else if (String::Equals(check, factory->boolean_string())) {
5113 __ LoadRoot(at, Heap::kTrueValueRootIndex); 5163 __ LoadRoot(at, Heap::kTrueValueRootIndex);
5114 __ Branch(if_true, eq, v0, Operand(at)); 5164 __ Branch(if_true, eq, v0, Operand(at));
5115 __ LoadRoot(at, Heap::kFalseValueRootIndex); 5165 __ LoadRoot(at, Heap::kFalseValueRootIndex);
5116 Split(eq, v0, Operand(at), if_true, if_false, fall_through); 5166 Split(eq, v0, Operand(at), if_true, if_false, fall_through);
5117 } else if (String::Equals(check, factory->undefined_string())) { 5167 } else if (String::Equals(check, factory->undefined_string())) {
5118 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); 5168 __ LoadRoot(at, Heap::kUndefinedValueRootIndex);
5119 __ Branch(if_true, eq, v0, Operand(at)); 5169 __ Branch(if_true, eq, v0, Operand(at));
5120 __ JumpIfSmi(v0, if_false); 5170 __ JumpIfSmi(v0, if_false);
5121 // Check for undetectable objects => true. 5171 // Check for undetectable objects => true.
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after
5441 reinterpret_cast<uint64_t>( 5491 reinterpret_cast<uint64_t>(
5442 isolate->builtins()->OsrAfterStackCheck()->entry())); 5492 isolate->builtins()->OsrAfterStackCheck()->entry()));
5443 return OSR_AFTER_STACK_CHECK; 5493 return OSR_AFTER_STACK_CHECK;
5444 } 5494 }
5445 5495
5446 5496
5447 } // namespace internal 5497 } // namespace internal
5448 } // namespace v8 5498 } // namespace v8
5449 5499
5450 #endif // V8_TARGET_ARCH_MIPS64 5500 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/full-codegen/mips/full-codegen-mips.cc ('k') | src/full-codegen/ppc/full-codegen-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698