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

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

Issue 6306014: Fix reintroduction of global variables that have been deleted. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Address comments. Created 9 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 | Annotate | Revision Log
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/ia32/lithium-ia32.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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 1893 matching lines...) Expand 10 before | Expand all | Expand 10 after
1904 __ mov(result, Operand::Cell(instr->hydrogen()->cell())); 1904 __ mov(result, Operand::Cell(instr->hydrogen()->cell()));
1905 if (instr->hydrogen()->check_hole_value()) { 1905 if (instr->hydrogen()->check_hole_value()) {
1906 __ cmp(result, Factory::the_hole_value()); 1906 __ cmp(result, Factory::the_hole_value());
1907 DeoptimizeIf(equal, instr->environment()); 1907 DeoptimizeIf(equal, instr->environment());
1908 } 1908 }
1909 } 1909 }
1910 1910
1911 1911
1912 void LCodeGen::DoStoreGlobal(LStoreGlobal* instr) { 1912 void LCodeGen::DoStoreGlobal(LStoreGlobal* instr) {
1913 Register value = ToRegister(instr->InputAt(0)); 1913 Register value = ToRegister(instr->InputAt(0));
1914 __ mov(Operand::Cell(instr->hydrogen()->cell()), value); 1914 Operand cell_operand = Operand::Cell(instr->hydrogen()->cell());
1915
1916 // If the cell we are storing to contains the hole it could have
1917 // been deleted from the property dictionary. In that case, we need
1918 // to update the property details in the property dictionary to mark
1919 // it as no longer deleted. We deoptimize in that case.
1920 if (instr->hydrogen()->check_hole_value()) {
1921 __ cmp(cell_operand, Factory::the_hole_value());
1922 DeoptimizeIf(equal, instr->environment());
1923 }
1924
1925 // Store the value.
1926 __ mov(cell_operand, value);
1915 } 1927 }
1916 1928
1917 1929
1918 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) { 1930 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) {
1919 // TODO(antonm): load a context with a separate instruction. 1931 // TODO(antonm): load a context with a separate instruction.
1920 Register result = ToRegister(instr->result()); 1932 Register result = ToRegister(instr->result());
1921 __ LoadContext(result, instr->context_chain_length()); 1933 __ LoadContext(result, instr->context_chain_length());
1922 __ mov(result, ContextOperand(result, instr->slot_index())); 1934 __ mov(result, ContextOperand(result, instr->slot_index()));
1923 } 1935 }
1924 1936
(...skipping 1674 matching lines...) Expand 10 before | Expand all | Expand 10 after
3599 ASSERT(osr_pc_offset_ == -1); 3611 ASSERT(osr_pc_offset_ == -1);
3600 osr_pc_offset_ = masm()->pc_offset(); 3612 osr_pc_offset_ = masm()->pc_offset();
3601 } 3613 }
3602 3614
3603 3615
3604 #undef __ 3616 #undef __
3605 3617
3606 } } // namespace v8::internal 3618 } } // namespace v8::internal
3607 3619
3608 #endif // V8_TARGET_ARCH_IA32 3620 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/ia32/lithium-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698