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 #ifndef V8_HYDROGEN_INSTRUCTIONS_H_ | 5 #ifndef V8_HYDROGEN_INSTRUCTIONS_H_ |
6 #define V8_HYDROGEN_INSTRUCTIONS_H_ | 6 #define V8_HYDROGEN_INSTRUCTIONS_H_ |
7 | 7 |
8 #include "src/v8.h" | 8 #include "src/v8.h" |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 3475 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3486 HValue* context, | 3486 HValue* context, |
3487 int32_t value, | 3487 int32_t value, |
3488 Representation representation, | 3488 Representation representation, |
3489 HInstruction* instruction) { | 3489 HInstruction* instruction) { |
3490 return instruction->Append(HConstant::New( | 3490 return instruction->Append(HConstant::New( |
3491 zone, context, value, representation)); | 3491 zone, context, value, representation)); |
3492 } | 3492 } |
3493 | 3493 |
3494 virtual Handle<Map> GetMonomorphicJSObjectMap() OVERRIDE { | 3494 virtual Handle<Map> GetMonomorphicJSObjectMap() OVERRIDE { |
3495 Handle<Object> object = object_.handle(); | 3495 Handle<Object> object = object_.handle(); |
3496 if (object->IsHeapObject()) { | 3496 if (!object.is_null() && object->IsHeapObject()) { |
3497 return v8::internal::handle(HeapObject::cast(*object)->map()); | 3497 return v8::internal::handle(HeapObject::cast(*object)->map()); |
3498 } | 3498 } |
3499 return Handle<Map>(); | 3499 return Handle<Map>(); |
3500 } | 3500 } |
3501 | 3501 |
3502 static HConstant* CreateAndInsertBefore(Zone* zone, | 3502 static HConstant* CreateAndInsertBefore(Zone* zone, |
3503 HValue* context, | 3503 HValue* context, |
3504 int32_t value, | 3504 int32_t value, |
3505 Representation representation, | 3505 Representation representation, |
3506 HInstruction* instruction) { | 3506 HInstruction* instruction) { |
(...skipping 4385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7892 }; | 7892 }; |
7893 | 7893 |
7894 | 7894 |
7895 | 7895 |
7896 #undef DECLARE_INSTRUCTION | 7896 #undef DECLARE_INSTRUCTION |
7897 #undef DECLARE_CONCRETE_INSTRUCTION | 7897 #undef DECLARE_CONCRETE_INSTRUCTION |
7898 | 7898 |
7899 } } // namespace v8::internal | 7899 } } // namespace v8::internal |
7900 | 7900 |
7901 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 7901 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
OLD | NEW |