Reviewers: Igor Sheludko,

Message:
PTAL

Description:
Make space available in bf3 by moving FunctionWithPrototype to bf1

BUG=

Please review this at https://codereview.chromium.org/275053002/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files (+17, -18 lines):
  M src/objects.h
  M src/objects-inl.h


Index: src/objects-inl.h
diff --git a/src/objects-inl.h b/src/objects-inl.h
index 6550e219ed528ba9d587652281302655a2896ed5..00cd62e818346c16b60fcddb03c6fef5d1ca200f 100644
--- a/src/objects-inl.h
+++ b/src/objects-inl.h
@@ -4033,12 +4033,12 @@ bool Map::has_non_instance_prototype() {


 void Map::set_function_with_prototype(bool value) {
-  set_bit_field3(FunctionWithPrototype::update(bit_field3(), value));
+  set_bit_field(FunctionWithPrototype::update(bit_field(), value));
 }


 bool Map::function_with_prototype() {
-  return FunctionWithPrototype::decode(bit_field3());
+  return FunctionWithPrototype::decode(bit_field());
 }


Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 961bc9a993ac15a1a5ce3a00ac6844102c2e17a6..17da0abca3ca8172cea0a0af630c30bcafe8ec49 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -5959,14 +5959,13 @@ class Map: public HeapObject {
       kDescriptorIndexBitCount, kDescriptorIndexBitCount> {};  // NOLINT
   STATIC_ASSERT(kDescriptorIndexBitCount + kDescriptorIndexBitCount == 20);
   class IsShared:                   public BitField<bool, 20,  1> {};
-  class FunctionWithPrototype:      public BitField<bool, 21,  1> {};
-  class DictionaryMap:              public BitField<bool, 22,  1> {};
-  class OwnsDescriptors:            public BitField<bool, 23,  1> {};
-  class HasInstanceCallHandler:     public BitField<bool, 24,  1> {};
-  class Deprecated:                 public BitField<bool, 25,  1> {};
-  class IsFrozen:                   public BitField<bool, 26,  1> {};
-  class IsUnstable:                 public BitField<bool, 27,  1> {};
-  class IsMigrationTarget:          public BitField<bool, 28,  1> {};
+  class DictionaryMap:              public BitField<bool, 21,  1> {};
+  class OwnsDescriptors:            public BitField<bool, 22,  1> {};
+  class HasInstanceCallHandler:     public BitField<bool, 23,  1> {};
+  class Deprecated:                 public BitField<bool, 24,  1> {};
+  class IsFrozen:                   public BitField<bool, 25,  1> {};
+  class IsUnstable:                 public BitField<bool, 26,  1> {};
+  class IsMigrationTarget:          public BitField<bool, 27,  1> {};

   // Tells whether the object in the prototype property will be used
   // for instances created from this function.  If the prototype
@@ -6521,14 +6520,14 @@ class Map: public HeapObject {
   STATIC_CHECK(kInstanceTypeOffset == Internals::kMapInstanceTypeOffset);

   // Bit positions for bit field.
- static const int kUnused = 0; // To be used for marking recently used maps.
-  static const int kHasNonInstancePrototype = 1;
-  static const int kIsHiddenPrototype = 2;
-  static const int kHasNamedInterceptor = 3;
-  static const int kHasIndexedInterceptor = 4;
-  static const int kIsUndetectable = 5;
-  static const int kIsObserved = 6;
-  static const int kIsAccessCheckNeeded = 7;
+  static const int kHasNonInstancePrototype = 0;
+  static const int kIsHiddenPrototype = 1;
+  static const int kHasNamedInterceptor = 2;
+  static const int kHasIndexedInterceptor = 3;
+  static const int kIsUndetectable = 4;
+  static const int kIsObserved = 5;
+  static const int kIsAccessCheckNeeded = 6;
+  class FunctionWithPrototype: public BitField<bool, 7,  1> {};

   // Bit positions for bit field 2
   static const int kIsExtensible = 0;


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to