| OLD | NEW |
| 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 13 matching lines...) Expand all Loading... |
| 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 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 "codegen.h" | 33 #include "codegen.h" |
| 34 #include "crankshaft-thread.h" |
| 34 #include "debug.h" | 35 #include "debug.h" |
| 35 #include "deoptimizer.h" | 36 #include "deoptimizer.h" |
| 36 #include "date.h" | 37 #include "date.h" |
| 37 #include "elements.h" | 38 #include "elements.h" |
| 38 #include "execution.h" | 39 #include "execution.h" |
| 39 #include "full-codegen.h" | 40 #include "full-codegen.h" |
| 40 #include "hydrogen.h" | 41 #include "hydrogen.h" |
| 41 #include "objects-inl.h" | 42 #include "objects-inl.h" |
| 42 #include "objects-visiting.h" | 43 #include "objects-visiting.h" |
| 43 #include "objects-visiting-inl.h" | 44 #include "objects-visiting-inl.h" |
| (...skipping 7254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7298 | 7299 |
| 7299 void JSFunction::JSFunctionIterateBody(int object_size, ObjectVisitor* v) { | 7300 void JSFunction::JSFunctionIterateBody(int object_size, ObjectVisitor* v) { |
| 7300 // Iterate over all fields in the body but take care in dealing with | 7301 // Iterate over all fields in the body but take care in dealing with |
| 7301 // the code entry. | 7302 // the code entry. |
| 7302 IteratePointers(v, kPropertiesOffset, kCodeEntryOffset); | 7303 IteratePointers(v, kPropertiesOffset, kCodeEntryOffset); |
| 7303 v->VisitCodeEntry(this->address() + kCodeEntryOffset); | 7304 v->VisitCodeEntry(this->address() + kCodeEntryOffset); |
| 7304 IteratePointers(v, kCodeEntryOffset + kPointerSize, object_size); | 7305 IteratePointers(v, kCodeEntryOffset + kPointerSize, object_size); |
| 7305 } | 7306 } |
| 7306 | 7307 |
| 7307 | 7308 |
| 7309 void JSFunction::CompileConcurrently() { |
| 7310 ASSERT(FLAG_concurrent_crankshaft); |
| 7311 i::Handle<JSFunction> handle(reinterpret_cast<JSFunction **>( |
| 7312 GetIsolate()->global_handles()->Create(this).location())); |
| 7313 CrankshaftThread::AddJob(GetIsolate(), handle); |
| 7314 } |
| 7315 |
| 7316 |
| 7308 void JSFunction::MarkForLazyRecompilation() { | 7317 void JSFunction::MarkForLazyRecompilation() { |
| 7309 ASSERT(is_compiled() && !IsOptimized()); | 7318 ASSERT(is_compiled() && !IsOptimized()); |
| 7310 ASSERT(shared()->allows_lazy_compilation() || | 7319 ASSERT(shared()->allows_lazy_compilation() || |
| 7311 code()->optimizable()); | 7320 code()->optimizable()); |
| 7312 Builtins* builtins = GetIsolate()->builtins(); | 7321 Builtins* builtins = GetIsolate()->builtins(); |
| 7313 ReplaceCode(builtins->builtin(Builtins::kLazyRecompile)); | 7322 ReplaceCode(builtins->builtin(Builtins::kLazyRecompile)); |
| 7314 } | 7323 } |
| 7315 | 7324 |
| 7316 | 7325 |
| 7317 bool SharedFunctionInfo::EnsureCompiled(Handle<SharedFunctionInfo> shared, | 7326 bool SharedFunctionInfo::EnsureCompiled(Handle<SharedFunctionInfo> shared, |
| (...skipping 5613 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 12931 set_year(Smi::FromInt(year), SKIP_WRITE_BARRIER); | 12940 set_year(Smi::FromInt(year), SKIP_WRITE_BARRIER); |
| 12932 set_month(Smi::FromInt(month), SKIP_WRITE_BARRIER); | 12941 set_month(Smi::FromInt(month), SKIP_WRITE_BARRIER); |
| 12933 set_day(Smi::FromInt(day), SKIP_WRITE_BARRIER); | 12942 set_day(Smi::FromInt(day), SKIP_WRITE_BARRIER); |
| 12934 set_weekday(Smi::FromInt(weekday), SKIP_WRITE_BARRIER); | 12943 set_weekday(Smi::FromInt(weekday), SKIP_WRITE_BARRIER); |
| 12935 set_hour(Smi::FromInt(hour), SKIP_WRITE_BARRIER); | 12944 set_hour(Smi::FromInt(hour), SKIP_WRITE_BARRIER); |
| 12936 set_min(Smi::FromInt(min), SKIP_WRITE_BARRIER); | 12945 set_min(Smi::FromInt(min), SKIP_WRITE_BARRIER); |
| 12937 set_sec(Smi::FromInt(sec), SKIP_WRITE_BARRIER); | 12946 set_sec(Smi::FromInt(sec), SKIP_WRITE_BARRIER); |
| 12938 } | 12947 } |
| 12939 | 12948 |
| 12940 } } // namespace v8::internal | 12949 } } // namespace v8::internal |
| OLD | NEW |