Revision: 11526
Author:   [email protected]
Date:     Tue May  8 05:30:36 2012
Log:      Fix function sorter from 11482 with correct fix.  The sorter
was reverted from trunk 3.10.8.1, with this change we can
repush it.
Review URL: https://chromiumcodereview.appspot.com/10377043
http://code.google.com/p/v8/source/detail?r=11526

Modified:
 /branches/bleeding_edge/src/hydrogen.cc
 /branches/bleeding_edge/src/objects-inl.h
 /branches/bleeding_edge/src/objects.h

=======================================
--- /branches/bleeding_edge/src/hydrogen.cc     Wed May  2 06:07:31 2012
+++ /branches/bleeding_edge/src/hydrogen.cc     Tue May  8 05:30:36 2012
@@ -5713,7 +5713,7 @@
     if (expr->ComputeTarget(map, name)) {
       order[ordered_functions++] =
           FunctionSorter(i,
- expr->target()->shared()->code()->profiler_ticks(),
+                         expr->target()->shared()->profiler_ticks(),
                          InliningAstSize(expr->target()),
                          expr->target()->shared()->SourceSize());
     }
=======================================
--- /branches/bleeding_edge/src/objects-inl.h   Thu May  3 07:09:26 2012
+++ /branches/bleeding_edge/src/objects-inl.h   Tue May  8 05:30:36 2012
@@ -3082,7 +3082,6 @@


 int Code::profiler_ticks() {
-  if (kind() == OPTIMIZED_FUNCTION) return 0;
   ASSERT_EQ(FUNCTION, kind());
   return READ_BYTE_FIELD(this, kProfilerTicksOffset);
 }
@@ -3671,6 +3670,12 @@
     code()->set_optimizable(false);
   }
 }
+
+
+int SharedFunctionInfo::profiler_ticks() {
+  if (code()->kind() != Code::FUNCTION) return 0;
+  return code()->profiler_ticks();
+}


 LanguageMode SharedFunctionInfo::language_mode() {
=======================================
--- /branches/bleeding_edge/src/objects.h       Fri May  4 02:16:38 2012
+++ /branches/bleeding_edge/src/objects.h       Tue May  8 05:30:36 2012
@@ -5351,6 +5351,8 @@
   inline int deopt_counter();
   inline void set_deopt_counter(int counter);

+  inline int profiler_ticks();
+
// Inline cache age is used to infer whether the function survived a context
   // disposal or not. In the former case we reset the opt_count.
   inline int ic_age();

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to