Remove inline header includes from non-inline headers (2).
authormstarzinger <mstarzinger@chromium.org>
Thu, 13 Aug 2015 15:30:04 +0000 (08:30 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 13 Aug 2015 15:30:16 +0000 (15:30 +0000)
This tries to remove includes of "-inl.h" headers from normal ".h"
headers, thereby reducing the chance of any cyclic dependencies and
decreasing the average size of our compilation units.

Note that this change still leaves 5 violations of that rule in the
code. It only tackles "node.h" including "types-inl.h".

R=titzer@chromium.org

Review URL: https://codereview.chromium.org/1288053004

Cr-Commit-Position: refs/heads/master@{#30161}

src/compiler/common-node-cache.cc
src/compiler/js-frame-specialization.h
src/compiler/js-type-feedback-lowering.h
src/compiler/linkage.h
src/compiler/node.h
src/compiler/source-position.cc
src/conversions-inl.h
src/conversions.h
src/isolate.h
src/sampler.h

index e7f7436..b005c95 100644 (file)
@@ -6,6 +6,7 @@
 
 #include "src/assembler.h"
 #include "src/compiler/node.h"
+#include "src/objects-inl.h"  // TODO(mstarzinger): Temporary cycle breaker!
 
 namespace v8 {
 namespace internal {
index c6fc561..90b3ca5 100644 (file)
@@ -9,6 +9,10 @@
 
 namespace v8 {
 namespace internal {
+
+// Forward declarations.
+class JavaScriptFrame;
+
 namespace compiler {
 
 // Forward declarations.
index 19f4df0..db0fbdd 100644 (file)
 
 namespace v8 {
 namespace internal {
+
+// Forward declarations.
+class Factory;
+
 namespace compiler {
 
 // Forward declarations.
index 9f8b2d7..623c910 100644 (file)
@@ -17,6 +17,7 @@ namespace v8 {
 namespace internal {
 
 class CallInterfaceDescriptor;
+class CompilationInfo;
 
 namespace compiler {
 
index 6557635..a638df3 100644 (file)
@@ -7,7 +7,7 @@
 
 #include "src/compiler/opcodes.h"
 #include "src/compiler/operator.h"
-#include "src/types-inl.h"
+#include "src/types.h"
 #include "src/zone-containers.h"
 
 namespace v8 {
index 48361ec..aba77b3 100644 (file)
@@ -5,6 +5,7 @@
 #include "src/compiler/source-position.h"
 #include "src/compiler/graph.h"
 #include "src/compiler/node-aux-data.h"
+#include "src/objects-inl.h"  // TODO(mstarzinger): Temporary cycle breaker!
 
 namespace v8 {
 namespace internal {
index d9f16ad..42d617d 100644 (file)
@@ -160,6 +160,11 @@ size_t NumberToSize(Isolate* isolate, Object* number) {
 }
 
 
+uint32_t DoubleToUint32(double x) {
+  return static_cast<uint32_t>(DoubleToInt32(x));
+}
+
+
 template <class Iterator, class EndMark>
 bool SubStringEquals(Iterator* current,
                      EndMark end,
index 666c2ef..9b6d83b 100644 (file)
@@ -89,9 +89,7 @@ inline int32_t DoubleToInt32(double x);
 
 
 // This function should match the exact semantics of ECMA-262 9.6.
-inline uint32_t DoubleToUint32(double x) {
-  return static_cast<uint32_t>(DoubleToInt32(x));
-}
+inline uint32_t DoubleToUint32(double x);
 
 
 // Enumeration for allowing octals and ignoring junk when converting
@@ -156,19 +154,19 @@ static inline bool IsMinusZero(double value) {
 }
 
 
-static inline bool IsSmiDouble(double value);
+inline bool IsSmiDouble(double value);
 
 
 // Integer32 is an integer that can be represented as a signed 32-bit
 // integer. It has to be in the range [-2^31, 2^31 - 1].
 // We also have to check for negative 0 as it is not an Integer32.
-static inline bool IsInt32Double(double value);
+inline bool IsInt32Double(double value);
 
 
 // UInteger32 is an integer that can be represented as an unsigned 32-bit
 // integer. It has to be in the range [0, 2^32 - 1].
 // We also have to check for negative 0 as it is not a UInteger32.
-static inline bool IsUint32Double(double value);
+inline bool IsUint32Double(double value);
 
 
 // Convert from Number object to C integer.
index 0445fbe..bb1fa41 100644 (file)
@@ -64,6 +64,7 @@ class HStatistics;
 class HTracer;
 class InlineRuntimeFunctionsTable;
 class InnerPointerToCodeCache;
+class Logger;
 class MaterializedObjectStore;
 class CodeAgingHelper;
 class RegExpStack;
index 120260d..bfdf961 100644 (file)
@@ -8,6 +8,7 @@
 #include "include/v8.h"
 
 #include "src/base/atomicops.h"
+#include "src/base/platform/time.h"
 #include "src/frames.h"
 #include "src/globals.h"