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 674 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
685 receiver_types_.Reserve(kMaxKeyedPolymorphism); | 685 receiver_types_.Reserve(kMaxKeyedPolymorphism); |
686 oracle->CollectKeyedReceiverTypes(this->id(), &receiver_types_); | 686 oracle->CollectKeyedReceiverTypes(this->id(), &receiver_types_); |
687 } | 687 } |
688 } | 688 } |
689 | 689 |
690 | 690 |
691 void CaseClause::RecordTypeFeedback(TypeFeedbackOracle* oracle) { | 691 void CaseClause::RecordTypeFeedback(TypeFeedbackOracle* oracle) { |
692 TypeInfo info = oracle->SwitchType(this); | 692 TypeInfo info = oracle->SwitchType(this); |
693 if (info.IsSmi()) { | 693 if (info.IsSmi()) { |
694 compare_type_ = SMI_ONLY; | 694 compare_type_ = SMI_ONLY; |
| 695 } else if (info.IsSymbol()) { |
| 696 compare_type_ = SYMBOL_ONLY; |
695 } else if (info.IsNonPrimitive()) { | 697 } else if (info.IsNonPrimitive()) { |
696 compare_type_ = OBJECT_ONLY; | 698 compare_type_ = OBJECT_ONLY; |
697 } else { | 699 } else { |
698 ASSERT(compare_type_ == NONE); | 700 ASSERT(compare_type_ == NONE); |
699 } | 701 } |
700 } | 702 } |
701 | 703 |
702 | 704 |
703 static bool CanCallWithoutIC(Handle<JSFunction> target, int arity) { | 705 static bool CanCallWithoutIC(Handle<JSFunction> target, int arity) { |
704 SharedFunctionInfo* info = target->shared(); | 706 SharedFunctionInfo* info = target->shared(); |
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1188 int pos) | 1190 int pos) |
1189 : label_(label), | 1191 : label_(label), |
1190 statements_(statements), | 1192 statements_(statements), |
1191 position_(pos), | 1193 position_(pos), |
1192 compare_type_(NONE), | 1194 compare_type_(NONE), |
1193 compare_id_(AstNode::GetNextId(isolate)), | 1195 compare_id_(AstNode::GetNextId(isolate)), |
1194 entry_id_(AstNode::GetNextId(isolate)) { | 1196 entry_id_(AstNode::GetNextId(isolate)) { |
1195 } | 1197 } |
1196 | 1198 |
1197 } } // namespace v8::internal | 1199 } } // namespace v8::internal |
OLD | NEW |