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

Unified Diff: src/compiler.h

Issue 115347: Reduce the memory used by frame elements from two words to one by... (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/arm/virtual-frame-arm.h ('k') | src/compiler.cc » ('j') | src/compiler.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.h
===================================================================
--- src/compiler.h (revision 1947)
+++ src/compiler.h (working copy)
@@ -29,6 +29,8 @@
#define V8_COMPILER_H_
#include "parser.h"
+#include "zone.h"
+#include "frame-element.h"
Kevin Millikin (Chromium) 2009/05/14 11:29:02 Is it OK to alphabetize these?
Mads Ager (chromium) 2009/05/14 11:42:40 It is. Done.
namespace v8 { namespace internal {
@@ -69,6 +71,19 @@
static bool CompileLazy(Handle<SharedFunctionInfo> shared, int loop_nesting);
};
+
+// During compilation we need a global list of handles to constants
+// for frame elements. When the zone gets deleted, we make sure to
+// clear this list of handles as well.
+class CompilationZoneScope : public ZoneScope {
+ public:
+ CompilationZoneScope(ZoneScopeMode mode) : ZoneScope(mode) { };
+ virtual ~CompilationZoneScope() {
+ if (ShouldDeleteOnExit()) FrameElement::ClearConstantList();
+ };
+};
+
+
} } // namespace v8::internal
#endif // V8_COMPILER_H_
« no previous file with comments | « src/arm/virtual-frame-arm.h ('k') | src/compiler.cc » ('j') | src/compiler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698