OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 692 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
703 receiver_types_.Reserve(kMaxKeyedPolymorphism); | 703 receiver_types_.Reserve(kMaxKeyedPolymorphism); |
704 oracle->CollectKeyedReceiverTypes(this->id(), &receiver_types_); | 704 oracle->CollectKeyedReceiverTypes(this->id(), &receiver_types_); |
705 } | 705 } |
706 } | 706 } |
707 | 707 |
708 | 708 |
709 void CaseClause::RecordTypeFeedback(TypeFeedbackOracle* oracle) { | 709 void CaseClause::RecordTypeFeedback(TypeFeedbackOracle* oracle) { |
710 TypeInfo info = oracle->SwitchType(this); | 710 TypeInfo info = oracle->SwitchType(this); |
711 if (info.IsSmi()) { | 711 if (info.IsSmi()) { |
712 compare_type_ = SMI_ONLY; | 712 compare_type_ = SMI_ONLY; |
| 713 } else if (info.IsSymbol()) { |
| 714 compare_type_ = SYMBOL_ONLY; |
| 715 } else if (info.IsNonSymbol()) { |
| 716 compare_type_ = STRING_ONLY; |
713 } else if (info.IsNonPrimitive()) { | 717 } else if (info.IsNonPrimitive()) { |
714 compare_type_ = OBJECT_ONLY; | 718 compare_type_ = OBJECT_ONLY; |
715 } else { | 719 } else { |
716 ASSERT(compare_type_ == NONE); | 720 ASSERT(compare_type_ == NONE); |
717 } | 721 } |
718 } | 722 } |
719 | 723 |
720 | 724 |
721 static bool CanCallWithoutIC(Handle<JSFunction> target, int arity) { | 725 static bool CanCallWithoutIC(Handle<JSFunction> target, int arity) { |
722 SharedFunctionInfo* info = target->shared(); | 726 SharedFunctionInfo* info = target->shared(); |
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1206 int pos) | 1210 int pos) |
1207 : label_(label), | 1211 : label_(label), |
1208 statements_(statements), | 1212 statements_(statements), |
1209 position_(pos), | 1213 position_(pos), |
1210 compare_type_(NONE), | 1214 compare_type_(NONE), |
1211 compare_id_(AstNode::GetNextId(isolate)), | 1215 compare_id_(AstNode::GetNextId(isolate)), |
1212 entry_id_(AstNode::GetNextId(isolate)) { | 1216 entry_id_(AstNode::GetNextId(isolate)) { |
1213 } | 1217 } |
1214 | 1218 |
1215 } } // namespace v8::internal | 1219 } } // namespace v8::internal |
OLD | NEW |