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

Unified Diff: src/virtual-frame.cc

Issue 115350: Revert revision 1949. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 7 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
« no previous file with comments | « src/virtual-frame.h ('k') | src/zone.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/virtual-frame.cc
===================================================================
--- src/virtual-frame.cc (revision 1949)
+++ src/virtual-frame.cc (working copy)
@@ -94,10 +94,10 @@
case FrameElement::REGISTER:
// All copies are backed by memory or register locations.
result.set_static_type(target.static_type());
- result.set_type(FrameElement::COPY);
- result.clear_copied();
- result.clear_sync();
- result.set_index(index);
+ result.type_ = FrameElement::COPY;
+ result.copied_ = false;
+ result.synced_ = false;
+ result.data_.index_ = index;
elements_[index].set_copied();
break;
@@ -465,6 +465,23 @@
}
+bool FrameElement::Equals(FrameElement other) {
+ if (type_ != other.type_ ||
+ copied_ != other.copied_ ||
+ synced_ != other.synced_) return false;
+
+ if (is_register()) {
+ if (!reg().is(other.reg())) return false;
+ } else if (is_constant()) {
+ if (!handle().is_identical_to(other.handle())) return false;
+ } else if (is_copy()) {
+ if (index() != other.index()) return false;
+ }
+
+ return true;
+}
+
+
bool VirtualFrame::Equals(VirtualFrame* other) {
#ifdef DEBUG
// These are sanity checks in debug builds, but we do not need to
« no previous file with comments | « src/virtual-frame.h ('k') | src/zone.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698