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

Unified Diff: src/objects.h

Issue 21062004: Revert 15940: "Compilation type and state allocate an unnecessary Smi on v8::Script." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 5 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/liveedit.cc ('k') | src/objects-inl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 388187445fe524bdb5aa7d6e31f0c074b51abe34..36611ee077710cdf4efebbc3beb8afe53bf17c52 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -5849,6 +5849,12 @@ class Script: public Struct {
// [type]: the script type.
DECL_ACCESSORS(type, Smi)
+ // [compilation]: how the the script was compiled.
+ DECL_ACCESSORS(compilation_type, Smi)
+
+ // [is_compiled]: determines whether the script has already been compiled.
+ DECL_ACCESSORS(compilation_state, Smi)
+
// [line_ends]: FixedArray of line ends positions.
DECL_ACCESSORS(line_ends, Object)
@@ -5860,19 +5866,6 @@ class Script: public Struct {
// function from which eval was called where eval was called.
DECL_ACCESSORS(eval_from_instructions_offset, Smi)
- // [flags]: Holds an exciting bitfield.
- DECL_ACCESSORS(flags, Smi)
-
- // [compilation_type]: how the the script was compiled. Encoded in the
- // 'flags' field.
- inline CompilationType compilation_type();
- inline void set_compilation_type(CompilationType type);
-
- // [compilation_state]: determines whether the script has already been
- // compiled. Encoded in the 'flags' field.
- inline CompilationState compilation_state();
- inline void set_compilation_state(CompilationState state);
-
static inline Script* cast(Object* obj);
// If script source is an external string, check that the underlying
@@ -5891,20 +5884,17 @@ class Script: public Struct {
static const int kContextOffset = kDataOffset + kPointerSize;
static const int kWrapperOffset = kContextOffset + kPointerSize;
static const int kTypeOffset = kWrapperOffset + kPointerSize;
- static const int kLineEndsOffset = kTypeOffset + kPointerSize;
+ static const int kCompilationTypeOffset = kTypeOffset + kPointerSize;
+ static const int kCompilationStateOffset =
+ kCompilationTypeOffset + kPointerSize;
+ static const int kLineEndsOffset = kCompilationStateOffset + kPointerSize;
static const int kIdOffset = kLineEndsOffset + kPointerSize;
static const int kEvalFromSharedOffset = kIdOffset + kPointerSize;
static const int kEvalFrominstructionsOffsetOffset =
kEvalFromSharedOffset + kPointerSize;
- static const int kFlagsOffset =
- kEvalFrominstructionsOffsetOffset + kPointerSize;
- static const int kSize = kFlagsOffset + kPointerSize;
+ static const int kSize = kEvalFrominstructionsOffsetOffset + kPointerSize;
private:
- // Bit positions in the flags field.
- static const int kCompilationTypeBit = 0;
- static const int kCompilationStateBit = 1;
-
DISALLOW_IMPLICIT_CONSTRUCTORS(Script);
};
« no previous file with comments | « src/liveedit.cc ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698