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

Side by Side Diff: src/api.cc

Issue 564035: Remove lazy loading of natives files and the natives cache.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/partial_snapshots/
Patch Set: Created 10 years, 10 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/SConscript ('k') | src/apinatives.js » ('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 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 16 matching lines...) Expand all
27 27
28 #include "v8.h" 28 #include "v8.h"
29 29
30 #include "api.h" 30 #include "api.h"
31 #include "arguments.h" 31 #include "arguments.h"
32 #include "bootstrapper.h" 32 #include "bootstrapper.h"
33 #include "compiler.h" 33 #include "compiler.h"
34 #include "debug.h" 34 #include "debug.h"
35 #include "execution.h" 35 #include "execution.h"
36 #include "global-handles.h" 36 #include "global-handles.h"
37 #include "globals.h"
37 #include "platform.h" 38 #include "platform.h"
38 #include "serialize.h" 39 #include "serialize.h"
39 #include "snapshot.h" 40 #include "snapshot.h"
40 #include "utils.h" 41 #include "utils.h"
41 #include "v8threads.h" 42 #include "v8threads.h"
42 #include "version.h" 43 #include "version.h"
43 44
44 45
45 #define LOG_API(expr) LOG(ApiEntryCall(expr)) 46 #define LOG_API(expr) LOG(ApiEntryCall(expr))
46 47
(...skipping 1080 matching lines...) Expand 10 before | Expand all | Expand 10 after
1127 } 1128 }
1128 EXCEPTION_PREAMBLE(); 1129 EXCEPTION_PREAMBLE();
1129 i::ScriptDataImpl* pre_data = static_cast<i::ScriptDataImpl*>(script_data); 1130 i::ScriptDataImpl* pre_data = static_cast<i::ScriptDataImpl*>(script_data);
1130 // We assert that the pre-data is sane, even though we can actually 1131 // We assert that the pre-data is sane, even though we can actually
1131 // handle it if it turns out not to be in release mode. 1132 // handle it if it turns out not to be in release mode.
1132 ASSERT(pre_data == NULL || pre_data->SanityCheck()); 1133 ASSERT(pre_data == NULL || pre_data->SanityCheck());
1133 // If the pre-data isn't sane we simply ignore it 1134 // If the pre-data isn't sane we simply ignore it
1134 if (pre_data != NULL && !pre_data->SanityCheck()) { 1135 if (pre_data != NULL && !pre_data->SanityCheck()) {
1135 pre_data = NULL; 1136 pre_data = NULL;
1136 } 1137 }
1137 i::Handle<i::JSFunction> boilerplate = i::Compiler::Compile(str, 1138 i::Handle<i::JSFunction> boilerplate =
1138 name_obj, 1139 i::Compiler::Compile(str,
1139 line_offset, 1140 name_obj,
1140 column_offset, 1141 line_offset,
1141 NULL, 1142 column_offset,
1142 pre_data); 1143 NULL,
1144 pre_data,
1145 i::NOT_NATIVES_CODE);
1143 has_pending_exception = boilerplate.is_null(); 1146 has_pending_exception = boilerplate.is_null();
1144 EXCEPTION_BAILOUT_CHECK(Local<Script>()); 1147 EXCEPTION_BAILOUT_CHECK(Local<Script>());
1145 return Local<Script>(ToApi<Script>(boilerplate)); 1148 return Local<Script>(ToApi<Script>(boilerplate));
1146 } 1149 }
1147 1150
1148 1151
1149 Local<Script> Script::New(v8::Handle<String> source, 1152 Local<Script> Script::New(v8::Handle<String> source,
1150 v8::Handle<Value> file_name) { 1153 v8::Handle<Value> file_name) {
1151 ScriptOrigin origin(file_name); 1154 ScriptOrigin origin(file_name);
1152 return New(source, &origin); 1155 return New(source, &origin);
(...skipping 2673 matching lines...) Expand 10 before | Expand all | Expand 10 after
3826 3829
3827 3830
3828 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { 3831 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) {
3829 HandleScopeImplementer* thread_local = 3832 HandleScopeImplementer* thread_local =
3830 reinterpret_cast<HandleScopeImplementer*>(storage); 3833 reinterpret_cast<HandleScopeImplementer*>(storage);
3831 thread_local->IterateThis(v); 3834 thread_local->IterateThis(v);
3832 return storage + ArchiveSpacePerThread(); 3835 return storage + ArchiveSpacePerThread();
3833 } 3836 }
3834 3837
3835 } } // namespace v8::internal 3838 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/SConscript ('k') | src/apinatives.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698