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

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

Issue 888613002: Initial switch to Chromium-style CHECK_* and DCHECK_* macros. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix slow dchecks. Created 5 years, 10 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
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_IA32 7 #if V8_TARGET_ARCH_IA32
8 8
9 #include "src/code-factory.h" 9 #include "src/code-factory.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 3696 matching lines...) Expand 10 before | Expand all | Expand 10 after
3707 __ mov(eax, FieldOperand(eax, JSValue::kValueOffset)); 3707 __ mov(eax, FieldOperand(eax, JSValue::kValueOffset));
3708 3708
3709 __ bind(&done); 3709 __ bind(&done);
3710 context()->Plug(eax); 3710 context()->Plug(eax);
3711 } 3711 }
3712 3712
3713 3713
3714 void FullCodeGenerator::EmitDateField(CallRuntime* expr) { 3714 void FullCodeGenerator::EmitDateField(CallRuntime* expr) {
3715 ZoneList<Expression*>* args = expr->arguments(); 3715 ZoneList<Expression*>* args = expr->arguments();
3716 DCHECK(args->length() == 2); 3716 DCHECK(args->length() == 2);
3717 DCHECK_NE(NULL, args->at(1)->AsLiteral()); 3717 DCHECK(args->at(1)->AsLiteral());
3718 Smi* index = Smi::cast(*(args->at(1)->AsLiteral()->value())); 3718 Smi* index = Smi::cast(*(args->at(1)->AsLiteral()->value()));
3719 3719
3720 VisitForAccumulatorValue(args->at(0)); // Load the object. 3720 VisitForAccumulatorValue(args->at(0)); // Load the object.
3721 3721
3722 Label runtime, done, not_date_object; 3722 Label runtime, done, not_date_object;
3723 Register object = eax; 3723 Register object = eax;
3724 Register result = eax; 3724 Register result = eax;
3725 Register scratch = ecx; 3725 Register scratch = ecx;
3726 3726
3727 __ JumpIfSmi(object, &not_date_object); 3727 __ JumpIfSmi(object, &not_date_object);
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after
4063 __ pop(ecx); 4063 __ pop(ecx);
4064 __ CallStub(&stub); 4064 __ CallStub(&stub);
4065 context()->Plug(eax); 4065 context()->Plug(eax);
4066 } 4066 }
4067 4067
4068 4068
4069 void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) { 4069 void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) {
4070 ZoneList<Expression*>* args = expr->arguments(); 4070 ZoneList<Expression*>* args = expr->arguments();
4071 DCHECK_EQ(2, args->length()); 4071 DCHECK_EQ(2, args->length());
4072 4072
4073 DCHECK_NE(NULL, args->at(0)->AsLiteral()); 4073 DCHECK(args->at(0)->AsLiteral());
4074 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->value()))->value(); 4074 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->value()))->value();
4075 4075
4076 Handle<FixedArray> jsfunction_result_caches( 4076 Handle<FixedArray> jsfunction_result_caches(
4077 isolate()->native_context()->jsfunction_result_caches()); 4077 isolate()->native_context()->jsfunction_result_caches());
4078 if (jsfunction_result_caches->length() <= cache_id) { 4078 if (jsfunction_result_caches->length() <= cache_id) {
4079 __ Abort(kAttemptToUseUndefinedCache); 4079 __ Abort(kAttemptToUseUndefinedCache);
4080 __ mov(eax, isolate()->factory()->undefined_value()); 4080 __ mov(eax, isolate()->factory()->undefined_value());
4081 context()->Plug(eax); 4081 context()->Plug(eax);
4082 return; 4082 return;
4083 } 4083 }
(...skipping 1199 matching lines...) Expand 10 before | Expand all | Expand 10 after
5283 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), 5283 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(),
5284 Assembler::target_address_at(call_target_address, 5284 Assembler::target_address_at(call_target_address,
5285 unoptimized_code)); 5285 unoptimized_code));
5286 return OSR_AFTER_STACK_CHECK; 5286 return OSR_AFTER_STACK_CHECK;
5287 } 5287 }
5288 5288
5289 5289
5290 } } // namespace v8::internal 5290 } } // namespace v8::internal
5291 5291
5292 #endif // V8_TARGET_ARCH_IA32 5292 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698