Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: src/compiler/typer.h

Issue 1197703002: Use big-boy Types to annotate interface descriptor parameters (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Review feedback Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_COMPILER_TYPER_H_ 5 #ifndef V8_COMPILER_TYPER_H_
6 #define V8_COMPILER_TYPER_H_ 6 #define V8_COMPILER_TYPER_H_
7 7
8 #include "src/compiler/graph.h" 8 #include "src/compiler/graph.h"
9 #include "src/types.h" 9 #include "src/types.h"
10 10
11 namespace v8 { 11 namespace v8 {
12 namespace internal { 12 namespace internal {
13 namespace compiler { 13 namespace compiler {
14 14
15 // Forward declarations. 15 // Forward declarations.
16 class LazyTypeCache; 16 class LazyTypeCache;
17 17
18 18
19 class Typer { 19 class Typer {
20 public: 20 public:
21 Typer(Isolate* isolate, Graph* graph, MaybeHandle<Context> context); 21 Typer(Isolate* isolate, Graph* graph, Type::FunctionType* function_type,
22 MaybeHandle<Context> context);
22 ~Typer(); 23 ~Typer();
23 24
24 void Run(); 25 void Run();
25 // TODO(bmeurer,jarin): Remove this once we have a notion of "roots" on Graph. 26 // TODO(bmeurer,jarin): Remove this once we have a notion of "roots" on Graph.
26 void Run(const ZoneVector<Node*>& roots); 27 void Run(const ZoneVector<Node*>& roots);
27 28
28 Graph* graph() { return graph_; } 29 Graph* graph() { return graph_; }
29 MaybeHandle<Context> context() { return context_; } 30 MaybeHandle<Context> context() { return context_; }
30 Zone* zone() { return graph_->zone(); } 31 Zone* zone() { return graph_->zone(); }
31 Isolate* isolate() { return isolate_; } 32 Isolate* isolate() { return isolate_; }
33 Type::FunctionType* function_type() const { return function_type_; }
32 34
33 private: 35 private:
34 class Visitor; 36 class Visitor;
35 class Decorator; 37 class Decorator;
36 38
37 Isolate* isolate_; 39 Isolate* isolate_;
38 Graph* graph_; 40 Graph* graph_;
41 Type::FunctionType* function_type_;
39 MaybeHandle<Context> context_; 42 MaybeHandle<Context> context_;
40 Decorator* decorator_; 43 Decorator* decorator_;
41 44
42 Zone* zone_; 45 Zone* zone_;
43 Type* boolean_or_number; 46 Type* boolean_or_number;
44 Type* undefined_or_null; 47 Type* undefined_or_null;
45 Type* undefined_or_number; 48 Type* undefined_or_number;
46 Type* negative_signed32; 49 Type* negative_signed32;
47 Type* non_negative_signed32; 50 Type* non_negative_signed32;
48 Type* singleton_false; 51 Type* singleton_false;
(...skipping 16 matching lines...) Expand all
65 LazyTypeCache* cache_; 68 LazyTypeCache* cache_;
66 69
67 DISALLOW_COPY_AND_ASSIGN(Typer); 70 DISALLOW_COPY_AND_ASSIGN(Typer);
68 }; 71 };
69 72
70 } // namespace compiler 73 } // namespace compiler
71 } // namespace internal 74 } // namespace internal
72 } // namespace v8 75 } // namespace v8
73 76
74 #endif // V8_COMPILER_TYPER_H_ 77 #endif // V8_COMPILER_TYPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698