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

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

Issue 113259: Inline the code dealing with entering spilled scopes and maintaining a... (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
Index: src/ia32/virtual-frame-ia32.h
===================================================================
--- src/ia32/virtual-frame-ia32.h (revision 1913)
+++ src/ia32/virtual-frame-ia32.h (working copy)
@@ -50,13 +50,27 @@
// generator is being transformed.
class SpilledScope BASE_EMBEDDED {
public:
- explicit SpilledScope(CodeGenerator* cgen);
+ explicit SpilledScope(CodeGenerator* cgen) {
+#ifdef DEBUG
+ cgen_ = cgen;
+ previous_state_ = cgen->in_spilled_code();
+ cgen->set_in_spilled_code(true);
+#endif
+ ASSERT(cgen->has_valid_frame());
+ cgen->frame()->SpillAll();
+ }
- ~SpilledScope();
+ ~SpilledScope() {
+#ifdef DEBUG
+ cgen_->set_in_spilled_code(previous_state_);
+#endif
+ }
private:
+#ifdef DEBUG
CodeGenerator* cgen_;
bool previous_state_;
+#endif
};
// An illegal index into the virtual frame.
« src/ia32/codegen-ia32.h ('K') | « src/ia32/codegen-ia32.cc ('k') | src/virtual-frame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698