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

Side by Side Diff: src/compilation-cache.h

Issue 181543002: Eliminate extended mode, and other modes clean-up (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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/code-stubs-hydrogen.cc ('k') | src/compilation-cache.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 // More specifically these are the CompileString, DebugEvaluate and 142 // More specifically these are the CompileString, DebugEvaluate and
143 // DebugEvaluateGlobal runtime functions. 143 // DebugEvaluateGlobal runtime functions.
144 // 4. The start position of the calling scope. 144 // 4. The start position of the calling scope.
145 class CompilationCacheEval: public CompilationSubCache { 145 class CompilationCacheEval: public CompilationSubCache {
146 public: 146 public:
147 CompilationCacheEval(Isolate* isolate, int generations) 147 CompilationCacheEval(Isolate* isolate, int generations)
148 : CompilationSubCache(isolate, generations) { } 148 : CompilationSubCache(isolate, generations) { }
149 149
150 Handle<SharedFunctionInfo> Lookup(Handle<String> source, 150 Handle<SharedFunctionInfo> Lookup(Handle<String> source,
151 Handle<Context> context, 151 Handle<Context> context,
152 LanguageMode language_mode, 152 StrictMode strict_mode,
153 int scope_position); 153 int scope_position);
154 154
155 void Put(Handle<String> source, 155 void Put(Handle<String> source,
156 Handle<Context> context, 156 Handle<Context> context,
157 Handle<SharedFunctionInfo> function_info, 157 Handle<SharedFunctionInfo> function_info,
158 int scope_position); 158 int scope_position);
159 159
160 private: 160 private:
161 MUST_USE_RESULT MaybeObject* TryTablePut( 161 MUST_USE_RESULT MaybeObject* TryTablePut(
162 Handle<String> source, 162 Handle<String> source,
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 int line_offset, 214 int line_offset,
215 int column_offset, 215 int column_offset,
216 bool is_shared_cross_origin, 216 bool is_shared_cross_origin,
217 Handle<Context> context); 217 Handle<Context> context);
218 218
219 // Finds the shared function info for a source string for eval in a 219 // Finds the shared function info for a source string for eval in a
220 // given context. Returns an empty handle if the cache doesn't 220 // given context. Returns an empty handle if the cache doesn't
221 // contain a script for the given source string. 221 // contain a script for the given source string.
222 Handle<SharedFunctionInfo> LookupEval(Handle<String> source, 222 Handle<SharedFunctionInfo> LookupEval(Handle<String> source,
223 Handle<Context> context, 223 Handle<Context> context,
224 LanguageMode language_mode, 224 StrictMode strict_mode,
225 int scope_position); 225 int scope_position);
226 226
227 // Returns the regexp data associated with the given regexp if it 227 // Returns the regexp data associated with the given regexp if it
228 // is in cache, otherwise an empty handle. 228 // is in cache, otherwise an empty handle.
229 Handle<FixedArray> LookupRegExp(Handle<String> source, 229 Handle<FixedArray> LookupRegExp(Handle<String> source,
230 JSRegExp::Flags flags); 230 JSRegExp::Flags flags);
231 231
232 // Associate the (source, kind) pair to the shared function 232 // Associate the (source, kind) pair to the shared function
233 // info. This may overwrite an existing mapping. 233 // info. This may overwrite an existing mapping.
234 void PutScript(Handle<String> source, 234 void PutScript(Handle<String> source,
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 294
295 friend class Isolate; 295 friend class Isolate;
296 296
297 DISALLOW_COPY_AND_ASSIGN(CompilationCache); 297 DISALLOW_COPY_AND_ASSIGN(CompilationCache);
298 }; 298 };
299 299
300 300
301 } } // namespace v8::internal 301 } } // namespace v8::internal
302 302
303 #endif // V8_COMPILATION_CACHE_H_ 303 #endif // V8_COMPILATION_CACHE_H_
OLDNEW
« no previous file with comments | « src/code-stubs-hydrogen.cc ('k') | src/compilation-cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698