Include what you use for allocation, api, assembler, and ast.

R=fschneider@chromium.org
BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com/9288011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10505 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 248adeb1
// Copyright 2008 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -25,10 +25,11 @@ ...@@ -25,10 +25,11 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "../include/v8stdint.h"
#include "globals.h"
#include "checks.h"
#include "allocation.h" #include "allocation.h"
#include <stdlib.h> // For free, malloc.
#include <string.h> // For memcpy.
#include "checks.h"
#include "utils.h" #include "utils.h"
namespace v8 { namespace v8 {
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
#ifndef V8_ALLOCATION_H_ #ifndef V8_ALLOCATION_H_
#define V8_ALLOCATION_H_ #define V8_ALLOCATION_H_
#include "checks.h"
#include "globals.h" #include "globals.h"
namespace v8 { namespace v8 {
......
...@@ -25,34 +25,36 @@ ...@@ -25,34 +25,36 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "v8.h"
#include "api.h" #include "api.h"
#include "arguments.h" #include <math.h> // For isnan.
#include <string.h> // For memcpy, strlen.
#include "../include/v8-debug.h"
#include "../include/v8-profiler.h"
#include "../include/v8-testing.h"
#include "bootstrapper.h" #include "bootstrapper.h"
#include "compiler.h" #include "compiler.h"
#include "conversions-inl.h"
#include "counters.h"
#include "debug.h" #include "debug.h"
#include "deoptimizer.h" #include "deoptimizer.h"
#include "execution.h" #include "execution.h"
#include "flags.h"
#include "global-handles.h" #include "global-handles.h"
#include "heap-profiler.h" #include "heap-profiler.h"
#include "messages.h" #include "messages.h"
#include "natives.h"
#include "parser.h" #include "parser.h"
#include "platform.h" #include "platform.h"
#include "profile-generator-inl.h" #include "profile-generator-inl.h"
#include "property-details.h"
#include "property.h"
#include "runtime-profiler.h" #include "runtime-profiler.h"
#include "scanner-character-streams.h" #include "scanner-character-streams.h"
#include "serialize.h"
#include "snapshot.h" #include "snapshot.h"
#include "unicode-inl.h"
#include "v8threads.h" #include "v8threads.h"
#include "version.h" #include "version.h"
#include "vm-state-inl.h" #include "vm-state-inl.h"
#include "../include/v8-profiler.h"
#include "../include/v8-testing.h"
#define LOG_API(isolate, expr) LOG(isolate, ApiEntryCall(expr)) #define LOG_API(isolate, expr) LOG(isolate, ApiEntryCall(expr))
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -28,10 +28,14 @@ ...@@ -28,10 +28,14 @@
#ifndef V8_API_H_ #ifndef V8_API_H_
#define V8_API_H_ #define V8_API_H_
#include "apiutils.h" #include "v8.h"
#include "factory.h"
#include "../include/v8-testing.h" #include "../include/v8-testing.h"
#include "apiutils.h"
#include "contexts.h"
#include "factory.h"
#include "isolate.h"
#include "list-inl.h"
namespace v8 { namespace v8 {
......
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
#define V8_ARM_ASSEMBLER_ARM_INL_H_ #define V8_ARM_ASSEMBLER_ARM_INL_H_
#include "arm/assembler-arm.h" #include "arm/assembler-arm.h"
#include "cpu.h" #include "cpu.h"
#include "debug.h" #include "debug.h"
......
...@@ -30,25 +30,42 @@ ...@@ -30,25 +30,42 @@
// The original source code covered by the above license above has been // The original source code covered by the above license above has been
// modified significantly by Google Inc. // modified significantly by Google Inc.
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
#include "v8.h" #include "assembler.h"
#include "arguments.h" #include <math.h> // For cos, log, pow, sin, tan, etc.
#include "api.h"
#include "builtins.h"
#include "counters.h"
#include "cpu.h"
#include "debug.h"
#include "deoptimizer.h" #include "deoptimizer.h"
#include "execution.h" #include "execution.h"
#include "ic-inl.h" #include "ic.h"
#include "incremental-marking.h" #include "isolate.h"
#include "factory.h" #include "jsregexp.h"
#include "platform.h"
#include "regexp-macro-assembler.h"
#include "regexp-stack.h"
#include "runtime.h" #include "runtime.h"
#include "runtime-profiler.h"
#include "serialize.h" #include "serialize.h"
#include "store-buffer-inl.h"
#include "stub-cache.h" #include "stub-cache.h"
#include "regexp-stack.h" #include "token.h"
#include "ast.h"
#include "regexp-macro-assembler.h" #if V8_TARGET_ARCH_IA32
#include "platform.h" #include "ia32/assembler-ia32-inl.h"
#include "store-buffer.h" #elif V8_TARGET_ARCH_X64
#include "x64/assembler-x64-inl.h"
#elif V8_TARGET_ARCH_ARM
#include "arm/assembler-arm-inl.h"
#elif V8_TARGET_ARCH_MIPS
#include "mips/assembler-mips-inl.h"
#else
#error "Unknown architecture."
#endif
// Include native regexp-macro-assembler. // Include native regexp-macro-assembler.
#ifndef V8_INTERPRETED_REGEXP #ifndef V8_INTERPRETED_REGEXP
#if V8_TARGET_ARCH_IA32 #if V8_TARGET_ARCH_IA32
......
...@@ -30,19 +30,27 @@ ...@@ -30,19 +30,27 @@
// The original source code covered by the above license above has been // The original source code covered by the above license above has been
// modified significantly by Google Inc. // modified significantly by Google Inc.
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
#ifndef V8_ASSEMBLER_H_ #ifndef V8_ASSEMBLER_H_
#define V8_ASSEMBLER_H_ #define V8_ASSEMBLER_H_
#include "v8.h"
#include "allocation.h" #include "allocation.h"
#include "builtins.h"
#include "gdb-jit.h" #include "gdb-jit.h"
#include "isolate.h"
#include "runtime.h" #include "runtime.h"
#include "token.h" #include "token.h"
namespace v8 { namespace v8 {
class ApiFunction;
namespace internal { namespace internal {
struct StatsCounter;
const unsigned kNoASTId = -1; const unsigned kNoASTId = -1;
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
// Platform independent assembler base class. // Platform independent assembler base class.
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -25,10 +25,15 @@ ...@@ -25,10 +25,15 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "v8.h"
#include "ast.h" #include "ast.h"
#include <math.h> // For isfinite.
#include "builtins.h"
#include "conversions.h"
#include "hashmap.h"
#include "parser.h" #include "parser.h"
#include "property-details.h"
#include "property.h"
#include "scopes.h" #include "scopes.h"
#include "string-stream.h" #include "string-stream.h"
#include "type-info.h" #include "type-info.h"
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -28,14 +28,19 @@ ...@@ -28,14 +28,19 @@
#ifndef V8_AST_H_ #ifndef V8_AST_H_
#define V8_AST_H_ #define V8_AST_H_
#include "allocation.h" #include "v8.h"
#include "execution.h"
#include "assembler.h"
#include "factory.h" #include "factory.h"
#include "isolate.h"
#include "jsregexp.h" #include "jsregexp.h"
#include "list-inl.h"
#include "runtime.h" #include "runtime.h"
#include "small-pointer-list.h" #include "small-pointer-list.h"
#include "smart-array-pointer.h"
#include "token.h" #include "token.h"
#include "variables.h" #include "variables.h"
#include "zone-inl.h"
namespace v8 { namespace v8 {
namespace internal { namespace internal {
...@@ -98,12 +103,28 @@ namespace internal { ...@@ -98,12 +103,28 @@ namespace internal {
EXPRESSION_NODE_LIST(V) EXPRESSION_NODE_LIST(V)
// Forward declarations // Forward declarations
class BitVector; class AstVisitor;
class DefinitionInfo; class BreakableStatement;
class Expression;
class IterationStatement;
class MaterializedLiteral; class MaterializedLiteral;
class Statement;
class TargetCollector; class TargetCollector;
class TypeFeedbackOracle; class TypeFeedbackOracle;
class RegExpAlternative;
class RegExpAssertion;
class RegExpAtom;
class RegExpBackReference;
class RegExpCapture;
class RegExpCharacterClass;
class RegExpCompiler;
class RegExpDisjunction;
class RegExpEmpty;
class RegExpLookahead;
class RegExpQuantifier;
class RegExpText;
#define DEF_FORWARD_DECLARATION(type) class type; #define DEF_FORWARD_DECLARATION(type) class type;
AST_NODE_LIST(DEF_FORWARD_DECLARATION) AST_NODE_LIST(DEF_FORWARD_DECLARATION)
#undef DEF_FORWARD_DECLARATION #undef DEF_FORWARD_DECLARATION
...@@ -115,11 +136,6 @@ typedef ZoneList<Handle<String> > ZoneStringList; ...@@ -115,11 +136,6 @@ typedef ZoneList<Handle<String> > ZoneStringList;
typedef ZoneList<Handle<Object> > ZoneObjectList; typedef ZoneList<Handle<Object> > ZoneObjectList;
#define DECLARE_NODE_TYPE(type) \
virtual void Accept(AstVisitor* v); \
virtual AstNode::Type node_type() const { return AstNode::k##type; } \
class AstNode: public ZoneObject { class AstNode: public ZoneObject {
public: public:
#define DECLARE_TYPE_ENUM(type) k##type, #define DECLARE_TYPE_ENUM(type) k##type,
...@@ -190,6 +206,11 @@ class AstNode: public ZoneObject { ...@@ -190,6 +206,11 @@ class AstNode: public ZoneObject {
}; };
#define DECLARE_NODE_TYPE(type) \
virtual void Accept(AstVisitor* v); \
virtual AstNode::Type node_type() const { return AstNode::k##type; } \
class Statement: public AstNode { class Statement: public AstNode {
public: public:
Statement() : statement_pos_(RelocInfo::kNoPosition) {} Statement() : statement_pos_(RelocInfo::kNoPosition) {}
......
...@@ -30,13 +30,15 @@ ...@@ -30,13 +30,15 @@
// The original source code covered by the above license above has been // The original source code covered by the above license above has been
// modified significantly by Google Inc. // modified significantly by Google Inc.
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// A light-weight IA32 Assembler. // A light-weight IA32 Assembler.
#ifndef V8_IA32_ASSEMBLER_IA32_INL_H_ #ifndef V8_IA32_ASSEMBLER_IA32_INL_H_
#define V8_IA32_ASSEMBLER_IA32_INL_H_ #define V8_IA32_ASSEMBLER_IA32_INL_H_
#include "ia32/assembler-ia32.h"
#include "cpu.h" #include "cpu.h"
#include "debug.h" #include "debug.h"
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -35,9 +35,11 @@ ...@@ -35,9 +35,11 @@
namespace v8 { namespace v8 {
namespace internal { namespace internal {
class NodeVisitor;
class RegExpCompiler;
class RegExpMacroAssembler; class RegExpMacroAssembler;
class RegExpNode;
class RegExpTree;
class RegExpImpl { class RegExpImpl {
public: public:
......
...@@ -37,6 +37,7 @@ ...@@ -37,6 +37,7 @@
#define V8_MIPS_ASSEMBLER_MIPS_INL_H_ #define V8_MIPS_ASSEMBLER_MIPS_INL_H_
#include "mips/assembler-mips.h" #include "mips/assembler-mips.h"
#include "cpu.h" #include "cpu.h"
#include "debug.h" #include "debug.h"
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -223,6 +223,7 @@ class CaseClause; ...@@ -223,6 +223,7 @@ class CaseClause;
class CompareOperation; class CompareOperation;
class CompilationInfo; class CompilationInfo;
class CountOperation; class CountOperation;
class Expression;
class Property; class Property;
class SmallMapList; class SmallMapList;
class UnaryOperation; class UnaryOperation;
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -107,14 +107,12 @@ const uint32_t kQuietNaNHighBitsMask = 0xfff << (51 - 32); ...@@ -107,14 +107,12 @@ const uint32_t kQuietNaNHighBitsMask = 0xfff << (51 - 32);
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
// Forward declarations for frequently used classes // Forward declarations for frequently used classes
// (sorted alphabetically)
class AccessorInfo; class AccessorInfo;
class Allocation; class Allocation;
class Arguments; class Arguments;
class Assembler; class Assembler;
class AssertNoAllocation; class AssertNoAllocation;
class BreakableStatement;
class Code; class Code;
class CodeGenerator; class CodeGenerator;
class CodeStub; class CodeStub;
...@@ -124,10 +122,8 @@ class Debugger; ...@@ -124,10 +122,8 @@ class Debugger;
class DebugInfo; class DebugInfo;
class Descriptor; class Descriptor;
class DescriptorArray; class DescriptorArray;
class Expression;
class ExternalReference; class ExternalReference;
class FixedArray; class FixedArray;
class FunctionLiteral;
class FunctionTemplateInfo; class FunctionTemplateInfo;
class MemoryChunk; class MemoryChunk;
class SeededNumberDictionary; class SeededNumberDictionary;
...@@ -138,7 +134,6 @@ class Heap; ...@@ -138,7 +134,6 @@ class Heap;
class HeapObject; class HeapObject;
class IC; class IC;
class InterceptorInfo; class InterceptorInfo;
class IterationStatement;
class JSArray; class JSArray;
class JSFunction; class JSFunction;
class JSObject; class JSObject;
...@@ -149,31 +144,19 @@ class Map; ...@@ -149,31 +144,19 @@ class Map;
class MapSpace; class MapSpace;
class MarkCompactCollector; class MarkCompactCollector;
class NewSpace; class NewSpace;
class NodeVisitor;
class Object; class Object;
class MaybeObject; class MaybeObject;
class OldSpace; class OldSpace;
class Property;
class Foreign; class Foreign;
class RegExpNode;
struct RegExpCompileData;
class RegExpTree;
class RegExpCompiler;
class RegExpVisitor;
class Scope; class Scope;
class ScopeInfo; class ScopeInfo;
class Script; class Script;
class Slot;
class Smi; class Smi;
template <typename Config, class Allocator = FreeStoreAllocationPolicy> template <typename Config, class Allocator = FreeStoreAllocationPolicy>
class SplayTree; class SplayTree;
class Statement;
class String; class String;
class Struct; class Struct;
class SwitchStatement;
class AstVisitor;
class Variable; class Variable;
class VariableProxy;
class RelocInfo; class RelocInfo;
class Deserializer; class Deserializer;
class MessageLocation; class MessageLocation;
......
// Copyright 2011 the V8 project authors. All rights reserved. // Copyright 2012 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without // Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are // modification, are permitted provided that the following conditions are
// met: // met:
...@@ -28,6 +28,8 @@ ...@@ -28,6 +28,8 @@
#ifndef V8_X64_ASSEMBLER_X64_INL_H_ #ifndef V8_X64_ASSEMBLER_X64_INL_H_
#define V8_X64_ASSEMBLER_X64_INL_H_ #define V8_X64_ASSEMBLER_X64_INL_H_
#include "x64/assembler-x64.h"
#include "cpu.h" #include "cpu.h"
#include "debug.h" #include "debug.h"
#include "v8memory.h" #include "v8memory.h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment