| Index: src/typing.cc
|
| diff --git a/src/typing.cc b/src/typing.cc
|
| index 48528705bf1e1abb605d2a243199eb7a7ab05e30..794accc48399d7095bea85aac88e0bb5954594cc 100644
|
| --- a/src/typing.cc
|
| +++ b/src/typing.cc
|
| @@ -410,7 +410,12 @@ void AstTyper::VisitObjectLiteral(ObjectLiteral* expr) {
|
| if (!prop->is_computed_name() &&
|
| prop->key()->AsLiteral()->value()->IsInternalizedString() &&
|
| prop->emit_store()) {
|
| - prop->RecordTypeFeedback(oracle());
|
| + // Record type feed back for the property.
|
| + TypeFeedbackId id = prop->key()->AsLiteral()->LiteralFeedbackId();
|
| + SmallMapList maps;
|
| + oracle()->CollectReceiverTypes(id, &maps);
|
| + prop->set_receiver_type(maps.length() == 1 ? maps.at(0)
|
| + : Handle<Map>::null());
|
| }
|
| }
|
|
|
| @@ -562,7 +567,17 @@ void AstTyper::VisitCall(Call* expr) {
|
|
|
| void AstTyper::VisitCallNew(CallNew* expr) {
|
| // Collect type feedback.
|
| - expr->RecordTypeFeedback(oracle());
|
| + FeedbackVectorSlot allocation_site_feedback_slot =
|
| + FLAG_pretenuring_call_new ? expr->AllocationSiteFeedbackSlot()
|
| + : expr->CallNewFeedbackSlot();
|
| + expr->set_allocation_site(
|
| + oracle()->GetCallNewAllocationSite(allocation_site_feedback_slot));
|
| + bool monomorphic =
|
| + oracle()->CallNewIsMonomorphic(expr->CallNewFeedbackSlot());
|
| + expr->set_is_monomorphic(monomorphic);
|
| + if (monomorphic) {
|
| + expr->set_target(oracle()->GetCallNewTarget(expr->CallNewFeedbackSlot()));
|
| + }
|
|
|
| RECURSE(Visit(expr->expression()));
|
| ZoneList<Expression*>* args = expr->arguments();
|
|
|