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

Unified Diff: src/compiler.h

Issue 261253005: Clean up debugger flags. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: rebase Created 6 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/codegen.cc ('k') | src/compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.h
diff --git a/src/compiler.h b/src/compiler.h
index fd26d24d719cf9815518796918f7b8b6edb799be..ac4dfd4e3e470a9862defd840070b2bbac7594ca 100644
--- a/src/compiler.h
+++ b/src/compiler.h
@@ -50,7 +50,6 @@ class CompilationInfo {
bool is_eval() const { return IsEval::decode(flags_); }
bool is_global() const { return IsGlobal::decode(flags_); }
StrictMode strict_mode() const { return StrictModeField::decode(flags_); }
- bool is_in_loop() const { return IsInLoop::decode(flags_); }
FunctionLiteral* function() const { return function_; }
Scope* scope() const { return scope_; }
Scope* global_scope() const { return global_scope_; }
@@ -95,10 +94,6 @@ class CompilationInfo {
ASSERT(this->strict_mode() == SLOPPY || this->strict_mode() == strict_mode);
flags_ = StrictModeField::update(flags_, strict_mode);
}
- void MarkAsInLoop() {
- ASSERT(is_lazy());
- flags_ |= IsInLoop::encode(true);
- }
void MarkAsNative() {
flags_ |= IsNative::encode(true);
}
@@ -151,6 +146,18 @@ class CompilationInfo {
return MustNotHaveEagerFrame::decode(flags_);
}
+ void MarkAsDebug() {
+ flags_ |= IsDebug::encode(true);
+ }
+
+ bool is_debug() const {
+ return IsDebug::decode(flags_);
+ }
+
+ bool IsCodePreAgingActive() const {
+ return FLAG_optimize_for_size && FLAG_age_code && !is_debug();
+ }
+
void SetParseRestriction(ParseRestriction restriction) {
flags_ = ParseRestricitonField::update(flags_, restriction);
}
@@ -353,8 +360,8 @@ class CompilationInfo {
// Flags that can be set for eager compilation.
class IsEval: public BitField<bool, 1, 1> {};
class IsGlobal: public BitField<bool, 2, 1> {};
- // Flags that can be set for lazy compilation.
- class IsInLoop: public BitField<bool, 3, 1> {};
+ // If the function is being compiled for the debugger.
+ class IsDebug: public BitField<bool, 3, 1> {};
// Strict mode - used in eager compilation.
class StrictModeField: public BitField<StrictMode, 4, 1> {};
// Is this a function from our natives.
« no previous file with comments | « src/codegen.cc ('k') | src/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698