Revision: 17531
Author:   [email protected]
Date:     Wed Nov  6 17:05:50 2013 UTC
Log:      Add three string constants from parser to the root-set.

[email protected]

Review URL: https://codereview.chromium.org/62143002
http://code.google.com/p/v8/source/detail?r=17531

Modified:
 /branches/bleeding_edge/include/v8.h
 /branches/bleeding_edge/src/func-name-inferrer.cc
 /branches/bleeding_edge/src/heap.h
 /branches/bleeding_edge/src/parser.cc
 /branches/bleeding_edge/src/rewriter.cc
 /branches/bleeding_edge/src/scopes.cc

=======================================
--- /branches/bleeding_edge/include/v8.h        Wed Nov  6 06:59:32 2013 UTC
+++ /branches/bleeding_edge/include/v8.h        Wed Nov  6 17:05:50 2013 UTC
@@ -5414,7 +5414,7 @@
   static const int kNullValueRootIndex = 7;
   static const int kTrueValueRootIndex = 8;
   static const int kFalseValueRootIndex = 9;
-  static const int kEmptyStringRootIndex = 132;
+  static const int kEmptyStringRootIndex = 134;

   static const int kNodeClassIdOffset = 1 * kApiPointerSize;
   static const int kNodeFlagsOffset = 1 * kApiPointerSize + 3;
=======================================
--- /branches/bleeding_edge/src/func-name-inferrer.cc Thu Feb 28 17:03:34 2013 UTC +++ /branches/bleeding_edge/src/func-name-inferrer.cc Wed Nov 6 17:05:50 2013 UTC
@@ -62,7 +62,7 @@


 void FuncNameInferrer::PushVariableName(Handle<String> name) {
-  if (IsOpen() && !isolate()->heap()->result_string()->Equals(*name)) {
+  if (IsOpen() && !isolate()->heap()->dot_result_string()->Equals(*name)) {
     names_stack_.Add(Name(name, kVariableName), zone());
   }
 }
=======================================
--- /branches/bleeding_edge/src/heap.h  Wed Nov  6 15:45:43 2013 UTC
+++ /branches/bleeding_edge/src/heap.h  Wed Nov  6 17:05:50 2013 UTC
@@ -209,8 +209,10 @@
   V(Boolean_string, "Boolean")                                           \
   V(callee_string, "callee")                                             \
   V(constructor_string, "constructor")                                   \
-  V(result_string, ".result")                                            \
+  V(dot_result_string, ".result")                                        \
   V(dot_for_string, ".for.")                                             \
+  V(dot_iterator_string, ".iterator")                                    \
+  V(dot_generator_object_string, ".generator_object")                    \
   V(eval_string, "eval")                                                 \
   V(empty_string, "")                                                    \
   V(function_string, "function")                                         \
=======================================
--- /branches/bleeding_edge/src/parser.cc       Tue Oct 29 11:44:04 2013 UTC
+++ /branches/bleeding_edge/src/parser.cc       Wed Nov  6 17:05:50 2013 UTC
@@ -2623,13 +2623,10 @@

   if (for_of != NULL) {
     Factory* heap_factory = isolate()->factory();
-    Handle<String> iterator_str = heap_factory->InternalizeOneByteString(
-        STATIC_ASCII_VECTOR(".iterator"));
-    Handle<String> result_str = heap_factory->InternalizeOneByteString(
-        STATIC_ASCII_VECTOR(".result"));
-    Variable* iterator =
-        top_scope_->DeclarationScope()->NewTemporary(iterator_str);
- Variable* result = top_scope_->DeclarationScope()->NewTemporary(result_str);
+    Variable* iterator = top_scope_->DeclarationScope()->NewTemporary(
+        heap_factory->dot_iterator_string());
+    Variable* result = top_scope_->DeclarationScope()->NewTemporary(
+        heap_factory->dot_result_string());

     Expression* assign_iterator;
     Expression* next_result;
@@ -4252,9 +4249,8 @@
       // in a temporary variable, a definition that is used by "yield"
// expressions. Presence of a variable for the generator object in the
       // FunctionState indicates that this function is a generator.
- Handle<String> tempname = isolate()->factory()->InternalizeOneByteString(
-          STATIC_ASCII_VECTOR(".generator_object"));
- Variable* temp = top_scope_->DeclarationScope()->NewTemporary(tempname);
+      Variable* temp = top_scope_->DeclarationScope()->NewTemporary(
+          isolate()->factory()->dot_generator_object_string());
       function_state.set_generator_object_variable(temp);
     }

=======================================
--- /branches/bleeding_edge/src/rewriter.cc     Mon Oct 14 11:06:15 2013 UTC
+++ /branches/bleeding_edge/src/rewriter.cc     Wed Nov  6 17:05:50 2013 UTC
@@ -263,7 +263,7 @@
   ZoneList<Statement*>* body = function->body();
   if (!body->is_empty()) {
     Variable* result = scope->NewTemporary(
-        info->isolate()->factory()->result_string());
+        info->isolate()->factory()->dot_result_string());
     Processor processor(result, info->zone());
     processor.Process(body);
     if (processor.HasStackOverflow()) return false;
=======================================
--- /branches/bleeding_edge/src/scopes.cc       Mon Oct 14 09:24:58 2013 UTC
+++ /branches/bleeding_edge/src/scopes.cc       Wed Nov  6 17:05:50 2013 UTC
@@ -1302,7 +1302,7 @@

 void Scope::AllocateNonParameterLocal(Variable* var) {
   ASSERT(var->scope() == this);
-  ASSERT(!var->IsVariable(isolate_->factory()->result_string()) ||
+  ASSERT(!var->IsVariable(isolate_->factory()->dot_result_string()) ||
          !var->IsStackLocal());
   if (var->IsUnallocated() && MustAllocate(var)) {
     if (MustAllocateInContext(var)) {

--
--
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/groups/opt_out.

Reply via email to