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

Side by Side Diff: src/arm/lithium-codegen-arm.cc

Issue 140943002: Fix logic error in assert in IsUndeclaredGlobal() (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Ports and addressed comments. Created 6 years, 11 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 | « src/arm/lithium-arm.cc ('k') | src/code-stubs.h » ('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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 2983 matching lines...) Expand 10 before | Expand all | Expand 10 after
2994 __ CompareRoot(payload, Heap::kTheHoleValueRootIndex); 2994 __ CompareRoot(payload, Heap::kTheHoleValueRootIndex);
2995 DeoptimizeIf(eq, instr->environment()); 2995 DeoptimizeIf(eq, instr->environment());
2996 } 2996 }
2997 2997
2998 // Store the value. 2998 // Store the value.
2999 __ str(value, FieldMemOperand(cell, Cell::kValueOffset)); 2999 __ str(value, FieldMemOperand(cell, Cell::kValueOffset));
3000 // Cells are always rescanned, so no write barrier here. 3000 // Cells are always rescanned, so no write barrier here.
3001 } 3001 }
3002 3002
3003 3003
3004 void LCodeGen::DoStoreGlobalGeneric(LStoreGlobalGeneric* instr) {
3005 ASSERT(ToRegister(instr->context()).is(cp));
3006 ASSERT(ToRegister(instr->global_object()).is(r1));
3007 ASSERT(ToRegister(instr->value()).is(r0));
3008
3009 __ mov(r2, Operand(instr->name()));
3010 Handle<Code> ic = StoreIC::initialize_stub(isolate(),
3011 instr->strict_mode_flag(),
3012 CONTEXTUAL);
3013 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3014 }
3015
3016
3017 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) { 3004 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) {
3018 Register context = ToRegister(instr->context()); 3005 Register context = ToRegister(instr->context());
3019 Register result = ToRegister(instr->result()); 3006 Register result = ToRegister(instr->result());
3020 __ ldr(result, ContextOperand(context, instr->slot_index())); 3007 __ ldr(result, ContextOperand(context, instr->slot_index()));
3021 if (instr->hydrogen()->RequiresHoleCheck()) { 3008 if (instr->hydrogen()->RequiresHoleCheck()) {
3022 __ LoadRoot(ip, Heap::kTheHoleValueRootIndex); 3009 __ LoadRoot(ip, Heap::kTheHoleValueRootIndex);
3023 __ cmp(result, ip); 3010 __ cmp(result, ip);
3024 if (instr->hydrogen()->DeoptimizesOnHole()) { 3011 if (instr->hydrogen()->DeoptimizesOnHole()) {
3025 DeoptimizeIf(eq, instr->environment()); 3012 DeoptimizeIf(eq, instr->environment());
3026 } else { 3013 } else {
(...skipping 1166 matching lines...) Expand 10 before | Expand all | Expand 10 after
4193 4180
4194 4181
4195 void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) { 4182 void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) {
4196 ASSERT(ToRegister(instr->context()).is(cp)); 4183 ASSERT(ToRegister(instr->context()).is(cp));
4197 ASSERT(ToRegister(instr->object()).is(r1)); 4184 ASSERT(ToRegister(instr->object()).is(r1));
4198 ASSERT(ToRegister(instr->value()).is(r0)); 4185 ASSERT(ToRegister(instr->value()).is(r0));
4199 4186
4200 // Name is always in r2. 4187 // Name is always in r2.
4201 __ mov(r2, Operand(instr->name())); 4188 __ mov(r2, Operand(instr->name()));
4202 Handle<Code> ic = StoreIC::initialize_stub(isolate(), 4189 Handle<Code> ic = StoreIC::initialize_stub(isolate(),
4203 instr->strict_mode_flag(), 4190 instr->strict_mode_flag());
4204 NOT_CONTEXTUAL);
4205 CallCode(ic, RelocInfo::CODE_TARGET, instr, NEVER_INLINE_TARGET_ADDRESS); 4191 CallCode(ic, RelocInfo::CODE_TARGET, instr, NEVER_INLINE_TARGET_ADDRESS);
4206 } 4192 }
4207 4193
4208 4194
4209 void LCodeGen::ApplyCheckIf(Condition condition, LBoundsCheck* check) { 4195 void LCodeGen::ApplyCheckIf(Condition condition, LBoundsCheck* check) {
4210 if (FLAG_debug_code && check->hydrogen()->skip_check()) { 4196 if (FLAG_debug_code && check->hydrogen()->skip_check()) {
4211 Label done; 4197 Label done;
4212 __ b(NegateCondition(condition), &done); 4198 __ b(NegateCondition(condition), &done);
4213 __ stop("eliminated bounds check failed"); 4199 __ stop("eliminated bounds check failed");
4214 __ bind(&done); 4200 __ bind(&done);
(...skipping 1585 matching lines...) Expand 10 before | Expand all | Expand 10 after
5800 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); 5786 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index));
5801 __ ldr(result, FieldMemOperand(scratch, 5787 __ ldr(result, FieldMemOperand(scratch,
5802 FixedArray::kHeaderSize - kPointerSize)); 5788 FixedArray::kHeaderSize - kPointerSize));
5803 __ bind(&done); 5789 __ bind(&done);
5804 } 5790 }
5805 5791
5806 5792
5807 #undef __ 5793 #undef __
5808 5794
5809 } } // namespace v8::internal 5795 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/code-stubs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698