OLD | NEW |
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 #include "src/code-stubs.h" | 5 #include "src/code-stubs.h" |
6 | 6 |
7 #include <sstream> | 7 #include <sstream> |
8 | 8 |
9 #include "src/ast/ast.h" | 9 #include "src/ast/ast.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 Address deoptimization_handler, | 66 Address deoptimization_handler, |
67 int hint_stack_parameter_count, | 67 int hint_stack_parameter_count, |
68 StubFunctionMode function_mode) { | 68 StubFunctionMode function_mode) { |
69 Initialize(deoptimization_handler, hint_stack_parameter_count, function_mode); | 69 Initialize(deoptimization_handler, hint_stack_parameter_count, function_mode); |
70 stack_parameter_count_ = stack_parameter_count; | 70 stack_parameter_count_ = stack_parameter_count; |
71 } | 71 } |
72 | 72 |
73 | 73 |
74 bool CodeStub::FindCodeInCache(Code** code_out) { | 74 bool CodeStub::FindCodeInCache(Code** code_out) { |
75 UnseededNumberDictionary* stubs = isolate()->heap()->code_stubs(); | 75 UnseededNumberDictionary* stubs = isolate()->heap()->code_stubs(); |
76 int index = stubs->FindEntry(GetKey()); | 76 int index = stubs->FindEntry(isolate(), GetKey()); |
77 if (index != UnseededNumberDictionary::kNotFound) { | 77 if (index != UnseededNumberDictionary::kNotFound) { |
78 *code_out = Code::cast(stubs->ValueAt(index)); | 78 *code_out = Code::cast(stubs->ValueAt(index)); |
79 return true; | 79 return true; |
80 } | 80 } |
81 return false; | 81 return false; |
82 } | 82 } |
83 | 83 |
84 | 84 |
85 void CodeStub::RecordCodeGeneration(Handle<Code> code) { | 85 void CodeStub::RecordCodeGeneration(Handle<Code> code) { |
86 std::ostringstream os; | 86 std::ostringstream os; |
(...skipping 2121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2208 } | 2208 } |
2209 | 2209 |
2210 ArrayConstructorStub::ArrayConstructorStub(Isolate* isolate) | 2210 ArrayConstructorStub::ArrayConstructorStub(Isolate* isolate) |
2211 : PlatformCodeStub(isolate) {} | 2211 : PlatformCodeStub(isolate) {} |
2212 | 2212 |
2213 InternalArrayConstructorStub::InternalArrayConstructorStub(Isolate* isolate) | 2213 InternalArrayConstructorStub::InternalArrayConstructorStub(Isolate* isolate) |
2214 : PlatformCodeStub(isolate) {} | 2214 : PlatformCodeStub(isolate) {} |
2215 | 2215 |
2216 } // namespace internal | 2216 } // namespace internal |
2217 } // namespace v8 | 2217 } // namespace v8 |
OLD | NEW |