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

Side by Side Diff: src/scopeinfo.h

Issue 7374002: Refactor allocation policies. Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « src/safepoint-table.cc ('k') | src/scopeinfo.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 30 matching lines...) Expand all
41 // is stored in a compressed form in FixedArray objects and is used 41 // is stored in a compressed form in FixedArray objects and is used
42 // at runtime (stack dumps, deoptimization, etc.). 42 // at runtime (stack dumps, deoptimization, etc.).
43 // 43 //
44 // Historical note: In other VMs built by this team, ScopeInfo was 44 // Historical note: In other VMs built by this team, ScopeInfo was
45 // usually called DebugInfo since the information was used (among 45 // usually called DebugInfo since the information was used (among
46 // other things) for on-demand debugging (Self, Smalltalk). However, 46 // other things) for on-demand debugging (Self, Smalltalk). However,
47 // DebugInfo seems misleading, since this information is primarily used 47 // DebugInfo seems misleading, since this information is primarily used
48 // in debugging-unrelated contexts. 48 // in debugging-unrelated contexts.
49 49
50 // Forward defined as 50 // Forward defined as
51 // template <class Allocator = FreeStoreAllocationPolicy> class ScopeInfo; 51 // template <class Allocator = FreeStoreAllocator> class ScopeInfo;
52 template<class Allocator> 52 template<class Allocator>
53 class ScopeInfo BASE_EMBEDDED { 53 class ScopeInfo BASE_EMBEDDED {
54 public: 54 public:
55 // Create a ScopeInfo instance from a scope. 55 // Create a ScopeInfo instance from a scope.
56 explicit ScopeInfo(Scope* scope); 56 explicit ScopeInfo(Scope* scope,
57 const Allocator& allocator = Allocator());
57 58
58 // Create a ScopeInfo instance from SerializedScopeInfo. 59 // Create a ScopeInfo instance from SerializedScopeInfo.
59 explicit ScopeInfo(SerializedScopeInfo* data); 60 explicit ScopeInfo(SerializedScopeInfo* data,
61 const Allocator& allocator = Allocator());
60 62
61 // Creates a SerializedScopeInfo holding the serialized scope info. 63 // Creates a SerializedScopeInfo holding the serialized scope info.
62 Handle<SerializedScopeInfo> Serialize(); 64 Handle<SerializedScopeInfo> Serialize();
63 65
64 // -------------------------------------------------------------------------- 66 // --------------------------------------------------------------------------
65 // Lookup 67 // Lookup
66 68
67 Handle<String> function_name() const { return function_name_; } 69 Handle<String> function_name() const { return function_name_; }
68 70
69 Handle<String> parameter_name(int i) const { return parameters_[i]; } 71 Handle<String> parameter_name(int i) const { return parameters_[i]; }
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 uint32_t values_[kLength]; 242 uint32_t values_[kLength];
241 243
242 friend class Isolate; 244 friend class Isolate;
243 DISALLOW_COPY_AND_ASSIGN(ContextSlotCache); 245 DISALLOW_COPY_AND_ASSIGN(ContextSlotCache);
244 }; 246 };
245 247
246 248
247 } } // namespace v8::internal 249 } } // namespace v8::internal
248 250
249 #endif // V8_SCOPEINFO_H_ 251 #endif // V8_SCOPEINFO_H_
OLDNEW
« no previous file with comments | « src/safepoint-table.cc ('k') | src/scopeinfo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698