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

Side by Side Diff: src/crankshaft/hydrogen.h

Issue 1968383002: Remove Expression::bounds_, in order to conserve memory during parsing. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove Expression::bounds_ Created 4 years, 7 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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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_CRANKSHAFT_HYDROGEN_H_ 5 #ifndef V8_CRANKSHAFT_HYDROGEN_H_
6 #define V8_CRANKSHAFT_HYDROGEN_H_ 6 #define V8_CRANKSHAFT_HYDROGEN_H_
7 7
8 #include "src/accessors.h" 8 #include "src/accessors.h"
9 #include "src/allocation.h" 9 #include "src/allocation.h"
10 #include "src/ast/ast-type-bounds.h"
10 #include "src/ast/ast.h" 11 #include "src/ast/ast.h"
11 #include "src/ast/scopes.h" 12 #include "src/ast/scopes.h"
12 #include "src/bailout-reason.h" 13 #include "src/bailout-reason.h"
13 #include "src/compiler.h" 14 #include "src/compiler.h"
14 #include "src/crankshaft/compilation-phase.h" 15 #include "src/crankshaft/compilation-phase.h"
15 #include "src/crankshaft/hydrogen-instructions.h" 16 #include "src/crankshaft/hydrogen-instructions.h"
16 #include "src/parsing/parser.h" 17 #include "src/parsing/parser.h"
17 #include "src/zone.h" 18 #include "src/zone.h"
18 19
19 namespace v8 { 20 namespace v8 {
(...skipping 2156 matching lines...) Expand 10 before | Expand all | Expand 10 after
2176 void Bailout(BailoutReason reason); 2177 void Bailout(BailoutReason reason);
2177 2178
2178 HBasicBlock* CreateJoin(HBasicBlock* first, 2179 HBasicBlock* CreateJoin(HBasicBlock* first,
2179 HBasicBlock* second, 2180 HBasicBlock* second,
2180 BailoutId join_id); 2181 BailoutId join_id);
2181 2182
2182 FunctionState* function_state() const { return function_state_; } 2183 FunctionState* function_state() const { return function_state_; }
2183 2184
2184 void VisitDeclarations(ZoneList<Declaration*>* declarations) override; 2185 void VisitDeclarations(ZoneList<Declaration*>* declarations) override;
2185 2186
2187 AstTypeBounds* bounds() { return &bounds_; }
2188
2186 void* operator new(size_t size, Zone* zone) { return zone->New(size); } 2189 void* operator new(size_t size, Zone* zone) { return zone->New(size); }
2187 void operator delete(void* pointer, Zone* zone) { } 2190 void operator delete(void* pointer, Zone* zone) { }
2188 void operator delete(void* pointer) { } 2191 void operator delete(void* pointer) { }
2189 2192
2190 DEFINE_AST_VISITOR_SUBCLASS_MEMBERS(); 2193 DEFINE_AST_VISITOR_SUBCLASS_MEMBERS();
2191 2194
2192 protected: 2195 protected:
2193 // Forward declarations for inner scope classes. 2196 // Forward declarations for inner scope classes.
2194 class SubgraphScope; 2197 class SubgraphScope;
2195 2198
(...skipping 713 matching lines...) Expand 10 before | Expand all | Expand 10 after
2909 // A stack of breakable statements entered. 2912 // A stack of breakable statements entered.
2910 BreakAndContinueScope* break_scope_; 2913 BreakAndContinueScope* break_scope_;
2911 2914
2912 int inlined_count_; 2915 int inlined_count_;
2913 ZoneList<Handle<Object> > globals_; 2916 ZoneList<Handle<Object> > globals_;
2914 2917
2915 bool inline_bailout_; 2918 bool inline_bailout_;
2916 2919
2917 HOsrBuilder* osr_; 2920 HOsrBuilder* osr_;
2918 2921
2922 AstTypeBounds bounds_;
2923
2919 friend class FunctionState; // Pushes and pops the state stack. 2924 friend class FunctionState; // Pushes and pops the state stack.
2920 friend class AstContext; // Pushes and pops the AST context stack. 2925 friend class AstContext; // Pushes and pops the AST context stack.
2921 friend class KeyedLoadFastElementStub; 2926 friend class KeyedLoadFastElementStub;
2922 friend class HOsrBuilder; 2927 friend class HOsrBuilder;
2923 2928
2924 DISALLOW_COPY_AND_ASSIGN(HOptimizedGraphBuilder); 2929 DISALLOW_COPY_AND_ASSIGN(HOptimizedGraphBuilder);
2925 }; 2930 };
2926 2931
2927 2932
2928 Zone* AstContext::zone() const { return owner_->zone(); } 2933 Zone* AstContext::zone() const { return owner_->zone(); }
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
3102 } 3107 }
3103 3108
3104 private: 3109 private:
3105 HOptimizedGraphBuilder* builder_; 3110 HOptimizedGraphBuilder* builder_;
3106 }; 3111 };
3107 3112
3108 } // namespace internal 3113 } // namespace internal
3109 } // namespace v8 3114 } // namespace v8
3110 3115
3111 #endif // V8_CRANKSHAFT_HYDROGEN_H_ 3116 #endif // V8_CRANKSHAFT_HYDROGEN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698