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

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

Issue 661503002: MIPS: Implement inline %_IsJSProxy() for full codegen and Hydrogen. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | src/mips64/full-codegen-mips64.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_MIPS 7 #if V8_TARGET_ARCH_MIPS
8 8
9 // Note on Mips implementation: 9 // Note on Mips implementation:
10 // 10 //
(...skipping 3399 matching lines...) Expand 10 before | Expand all | Expand 10 after
3410 3410
3411 __ JumpIfSmi(v0, if_false); 3411 __ JumpIfSmi(v0, if_false);
3412 __ GetObjectType(v0, a1, a1); 3412 __ GetObjectType(v0, a1, a1);
3413 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); 3413 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
3414 Split(eq, a1, Operand(JS_REGEXP_TYPE), if_true, if_false, fall_through); 3414 Split(eq, a1, Operand(JS_REGEXP_TYPE), if_true, if_false, fall_through);
3415 3415
3416 context()->Plug(if_true, if_false); 3416 context()->Plug(if_true, if_false);
3417 } 3417 }
3418 3418
3419 3419
3420 void FullCodeGenerator::EmitIsJSProxy(CallRuntime* expr) {
3421 ZoneList<Expression*>* args = expr->arguments();
3422 DCHECK(args->length() == 1);
3423
3424 VisitForAccumulatorValue(args->at(0));
3425
3426 Label materialize_true, materialize_false;
3427 Label* if_true = NULL;
3428 Label* if_false = NULL;
3429 Label* fall_through = NULL;
3430 context()->PrepareTest(&materialize_true, &materialize_false, &if_true,
3431 &if_false, &fall_through);
3432
3433 __ JumpIfSmi(v0, if_false);
3434 Register map = a1;
3435 Register type_reg = a2;
3436 __ GetObjectType(v0, map, type_reg);
3437 __ Subu(type_reg, type_reg, Operand(FIRST_JS_PROXY_TYPE));
3438 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
3439 Split(ls, type_reg, Operand(LAST_JS_PROXY_TYPE - FIRST_JS_PROXY_TYPE),
3440 if_true, if_false, fall_through);
3441
3442 context()->Plug(if_true, if_false);
3443 }
3444
3445
3420 void FullCodeGenerator::EmitIsConstructCall(CallRuntime* expr) { 3446 void FullCodeGenerator::EmitIsConstructCall(CallRuntime* expr) {
3421 DCHECK(expr->arguments()->length() == 0); 3447 DCHECK(expr->arguments()->length() == 0);
3422 3448
3423 Label materialize_true, materialize_false; 3449 Label materialize_true, materialize_false;
3424 Label* if_true = NULL; 3450 Label* if_true = NULL;
3425 Label* if_false = NULL; 3451 Label* if_false = NULL;
3426 Label* fall_through = NULL; 3452 Label* fall_through = NULL;
3427 context()->PrepareTest(&materialize_true, &materialize_false, 3453 context()->PrepareTest(&materialize_true, &materialize_false,
3428 &if_true, &if_false, &fall_through); 3454 &if_true, &if_false, &fall_through);
3429 3455
(...skipping 1735 matching lines...) Expand 10 before | Expand all | Expand 10 after
5165 Assembler::target_address_at(pc_immediate_load_address)) == 5191 Assembler::target_address_at(pc_immediate_load_address)) ==
5166 reinterpret_cast<uint32_t>( 5192 reinterpret_cast<uint32_t>(
5167 isolate->builtins()->OsrAfterStackCheck()->entry())); 5193 isolate->builtins()->OsrAfterStackCheck()->entry()));
5168 return OSR_AFTER_STACK_CHECK; 5194 return OSR_AFTER_STACK_CHECK;
5169 } 5195 }
5170 5196
5171 5197
5172 } } // namespace v8::internal 5198 } } // namespace v8::internal
5173 5199
5174 #endif // V8_TARGET_ARCH_MIPS 5200 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « no previous file | src/mips64/full-codegen-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698