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

Side by Side Diff: src/x64/lithium-codegen-x64.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/x64/ic-x64.cc ('k') | src/x64/lithium-x64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 2725 matching lines...) Expand 10 before | Expand all | Expand 10 after
2736 __ movq(Operand(cell, 0), value); 2736 __ movq(Operand(cell, 0), value);
2737 } else { 2737 } else {
2738 // Store the value. 2738 // Store the value.
2739 __ Move(kScratchRegister, cell_handle, RelocInfo::CELL); 2739 __ Move(kScratchRegister, cell_handle, RelocInfo::CELL);
2740 __ movq(Operand(kScratchRegister, 0), value); 2740 __ movq(Operand(kScratchRegister, 0), value);
2741 } 2741 }
2742 // Cells are always rescanned, so no write barrier here. 2742 // Cells are always rescanned, so no write barrier here.
2743 } 2743 }
2744 2744
2745 2745
2746 void LCodeGen::DoStoreGlobalGeneric(LStoreGlobalGeneric* instr) {
2747 ASSERT(ToRegister(instr->context()).is(rsi));
2748 ASSERT(ToRegister(instr->global_object()).is(rdx));
2749 ASSERT(ToRegister(instr->value()).is(rax));
2750
2751 __ Move(rcx, instr->name());
2752 Handle<Code> ic = StoreIC::initialize_stub(isolate(),
2753 instr->strict_mode_flag(),
2754 CONTEXTUAL);
2755 CallCode(ic, RelocInfo::CODE_TARGET, instr);
2756 }
2757
2758
2759 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) { 2746 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) {
2760 Register context = ToRegister(instr->context()); 2747 Register context = ToRegister(instr->context());
2761 Register result = ToRegister(instr->result()); 2748 Register result = ToRegister(instr->result());
2762 __ movq(result, ContextOperand(context, instr->slot_index())); 2749 __ movq(result, ContextOperand(context, instr->slot_index()));
2763 if (instr->hydrogen()->RequiresHoleCheck()) { 2750 if (instr->hydrogen()->RequiresHoleCheck()) {
2764 __ CompareRoot(result, Heap::kTheHoleValueRootIndex); 2751 __ CompareRoot(result, Heap::kTheHoleValueRootIndex);
2765 if (instr->hydrogen()->DeoptimizesOnHole()) { 2752 if (instr->hydrogen()->DeoptimizesOnHole()) {
2766 DeoptimizeIf(equal, instr->environment()); 2753 DeoptimizeIf(equal, instr->environment());
2767 } else { 2754 } else {
2768 Label is_not_hole; 2755 Label is_not_hole;
(...skipping 1289 matching lines...) Expand 10 before | Expand all | Expand 10 after
4058 } 4045 }
4059 4046
4060 4047
4061 void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) { 4048 void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) {
4062 ASSERT(ToRegister(instr->context()).is(rsi)); 4049 ASSERT(ToRegister(instr->context()).is(rsi));
4063 ASSERT(ToRegister(instr->object()).is(rdx)); 4050 ASSERT(ToRegister(instr->object()).is(rdx));
4064 ASSERT(ToRegister(instr->value()).is(rax)); 4051 ASSERT(ToRegister(instr->value()).is(rax));
4065 4052
4066 __ Move(rcx, instr->hydrogen()->name()); 4053 __ Move(rcx, instr->hydrogen()->name());
4067 Handle<Code> ic = StoreIC::initialize_stub(isolate(), 4054 Handle<Code> ic = StoreIC::initialize_stub(isolate(),
4068 instr->strict_mode_flag(), 4055 instr->strict_mode_flag());
4069 NOT_CONTEXTUAL);
4070 CallCode(ic, RelocInfo::CODE_TARGET, instr); 4056 CallCode(ic, RelocInfo::CODE_TARGET, instr);
4071 } 4057 }
4072 4058
4073 4059
4074 void LCodeGen::ApplyCheckIf(Condition cc, LBoundsCheck* check) { 4060 void LCodeGen::ApplyCheckIf(Condition cc, LBoundsCheck* check) {
4075 if (FLAG_debug_code && check->hydrogen()->skip_check()) { 4061 if (FLAG_debug_code && check->hydrogen()->skip_check()) {
4076 Label done; 4062 Label done;
4077 __ j(NegateCondition(cc), &done, Label::kNear); 4063 __ j(NegateCondition(cc), &done, Label::kNear);
4078 __ int3(); 4064 __ int3();
4079 __ bind(&done); 4065 __ bind(&done);
(...skipping 1542 matching lines...) Expand 10 before | Expand all | Expand 10 after
5622 FixedArray::kHeaderSize - kPointerSize)); 5608 FixedArray::kHeaderSize - kPointerSize));
5623 __ bind(&done); 5609 __ bind(&done);
5624 } 5610 }
5625 5611
5626 5612
5627 #undef __ 5613 #undef __
5628 5614
5629 } } // namespace v8::internal 5615 } } // namespace v8::internal
5630 5616
5631 #endif // V8_TARGET_ARCH_X64 5617 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/ic-x64.cc ('k') | src/x64/lithium-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698