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/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/bailout-reason.h" | 7 #include "src/bailout-reason.h" |
8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
9 #include "src/field-index.h" | 9 #include "src/field-index.h" |
10 #include "src/hydrogen.h" | 10 #include "src/hydrogen.h" |
(...skipping 1639 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1650 | 1650 |
1651 return value; | 1651 return value; |
1652 } | 1652 } |
1653 | 1653 |
1654 | 1654 |
1655 Handle<Code> ElementsTransitionAndStoreStub::GenerateCode() { | 1655 Handle<Code> ElementsTransitionAndStoreStub::GenerateCode() { |
1656 return DoGenerateCode(this); | 1656 return DoGenerateCode(this); |
1657 } | 1657 } |
1658 | 1658 |
1659 | 1659 |
| 1660 template <> |
| 1661 HValue* CodeStubGraphBuilder<ToObjectStub>::BuildCodeStub() { |
| 1662 HValue* receiver = GetParameter(ToObjectDescriptor::kReceiverIndex); |
| 1663 return BuildToObject(receiver); |
| 1664 } |
| 1665 |
| 1666 |
| 1667 Handle<Code> ToObjectStub::GenerateCode() { return DoGenerateCode(this); } |
| 1668 |
| 1669 |
1660 void CodeStubGraphBuilderBase::BuildCheckAndInstallOptimizedCode( | 1670 void CodeStubGraphBuilderBase::BuildCheckAndInstallOptimizedCode( |
1661 HValue* js_function, | 1671 HValue* js_function, |
1662 HValue* native_context, | 1672 HValue* native_context, |
1663 IfBuilder* builder, | 1673 IfBuilder* builder, |
1664 HValue* optimized_map, | 1674 HValue* optimized_map, |
1665 HValue* map_index) { | 1675 HValue* map_index) { |
1666 HValue* osr_ast_id_none = Add<HConstant>(BailoutId::None().ToInt()); | 1676 HValue* osr_ast_id_none = Add<HConstant>(BailoutId::None().ToInt()); |
1667 HValue* context_slot = LoadFromOptimizedCodeMap( | 1677 HValue* context_slot = LoadFromOptimizedCodeMap( |
1668 optimized_map, map_index, SharedFunctionInfo::kContextOffset); | 1678 optimized_map, map_index, SharedFunctionInfo::kContextOffset); |
1669 HValue* osr_ast_slot = LoadFromOptimizedCodeMap( | 1679 HValue* osr_ast_slot = LoadFromOptimizedCodeMap( |
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2211 return Pop(); | 2221 return Pop(); |
2212 } | 2222 } |
2213 | 2223 |
2214 | 2224 |
2215 Handle<Code> KeyedLoadGenericStub::GenerateCode() { | 2225 Handle<Code> KeyedLoadGenericStub::GenerateCode() { |
2216 return DoGenerateCode(this); | 2226 return DoGenerateCode(this); |
2217 } | 2227 } |
2218 | 2228 |
2219 } // namespace internal | 2229 } // namespace internal |
2220 } // namespace v8 | 2230 } // namespace v8 |
OLD | NEW |