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

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

Issue 11406: Simplify virtual frame by removing the virtual stack pointer, which... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/toiger/
Patch Set: Created 12 years, 1 month 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
Index: src/virtual-frame-ia32.h
===================================================================
--- src/virtual-frame-ia32.h (revision 766)
+++ src/virtual-frame-ia32.h (working copy)
@@ -68,7 +68,7 @@
// The height of the virtual expression stack.
int height() const {
- return virtual_stack_pointer_ - expression_base_index() + 1;
+ return elements_.length() - expression_base_index();
}
// Add extra in-memory elements to the top of the frame without generating
@@ -179,14 +179,11 @@
List<Element> elements_;
- // The virtual stack pointer is the index of the top element of the stack.
- int virtual_stack_pointer_;
-
- int virtual_frame_pointer_;
-
int parameter_count_;
int local_count_;
+ int frame_pointer_;
+
// The index of the first parameter. The receiver lies below the first
// parameter.
int param0_index() const { return 1; }
@@ -198,16 +195,6 @@
// The index of the base of the expression stack.
int expression_base_index() const { return local0_index() + local_count_; }
-
- void AddElement(const Element& element) {
- virtual_stack_pointer_++;
- elements_.Add(element);
- }
-
- Element RemoveElement() {
- virtual_stack_pointer_--;
- return elements_.RemoveLast();
- }
};

Powered by Google App Engine
This is Rietveld 408576698