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

Unified Diff: src/virtual-frame-ia32.cc

Issue 42324: Add a bit to a virtual frame element telling if it's been copied. Set... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 9 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 side-by-side diff with in-line comments
Download patch
« src/virtual-frame.h ('K') | « src/virtual-frame.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/virtual-frame-ia32.cc
===================================================================
--- src/virtual-frame-ia32.cc (revision 1527)
+++ src/virtual-frame-ia32.cc (working copy)
@@ -550,6 +550,7 @@
return copy;
}
+ elements_[index].clear_copied();
return FrameElement::InvalidElement();
}
@@ -569,7 +570,9 @@
// push that register on top of the frame. If it is copied,
// make the first copy the backing store and push a fresh copy
// on top of the frame.
- FrameElement copy = AdjustCopies(index);
+ FrameElement copy = original.is_copied()
+ ? AdjustCopies(index)
+ : FrameElement::InvalidElement();
if (copy.is_valid()) {
// The original element was a copy. Push the copy of the new
// backing store.
@@ -593,7 +596,9 @@
// If the element is not copied, push it on top of the frame.
// If it is copied, make the first copy be the new backing store
// and push a fresh copy on top of the frame.
- FrameElement copy = AdjustCopies(index);
+ FrameElement copy = original.is_copied()
+ ? AdjustCopies(index)
+ : FrameElement::InvalidElement();
if (copy.is_valid()) {
// The original element was a copy. Push the copy of the new
// backing store.
@@ -634,7 +639,8 @@
FrameElement original = elements_[index];
// If the stored-to slot may be copied, adjust to preserve the
// copy-on-write semantics of copied elements.
- if (original.is_register() || original.is_memory()) {
+ if (original.is_copied() &&
+ (original.is_register() || original.is_memory())) {
FrameElement ignored = AdjustCopies(index);
}
« src/virtual-frame.h ('K') | « src/virtual-frame.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698