| Index: src/type-info.cc
|
| diff --git a/src/type-info.cc b/src/type-info.cc
|
| index 83fcd0f25e79f030a6593b5984ab1ea25235806e..ca3baa1215ff29afba9e3a11b7c628c3040e4b22 100644
|
| --- a/src/type-info.cc
|
| +++ b/src/type-info.cc
|
| @@ -97,9 +97,7 @@ bool TypeFeedbackOracle::StoreIsKeyedPolymorphic(TypeFeedbackId ast_id) {
|
|
|
| bool TypeFeedbackOracle::CallIsMonomorphic(int slot) {
|
| Handle<Object> value = GetInfo(slot);
|
| - return FLAG_pretenuring_call_new
|
| - ? value->IsJSFunction()
|
| - : value->IsAllocationSite() || value->IsJSFunction();
|
| + return value->IsAllocationSite() || value->IsJSFunction();
|
| }
|
|
|
|
|
| @@ -134,7 +132,10 @@ KeyedAccessStoreMode TypeFeedbackOracle::GetStoreMode(
|
|
|
| Handle<JSFunction> TypeFeedbackOracle::GetCallTarget(int slot) {
|
| Handle<Object> info = GetInfo(slot);
|
| - if (FLAG_pretenuring_call_new || info->IsJSFunction()) {
|
| + if (info->IsAllocationSite()) {
|
| + ASSERT(!FLAG_pretenuring_call_new);
|
| + return Handle<JSFunction>(isolate()->native_context()->array_function());
|
| + } else {
|
| return Handle<JSFunction>::cast(info);
|
| }
|
|
|
| @@ -154,6 +155,15 @@ Handle<JSFunction> TypeFeedbackOracle::GetCallNewTarget(int slot) {
|
| }
|
|
|
|
|
| +Handle<AllocationSite> TypeFeedbackOracle::GetCallAllocationSite(int slot) {
|
| + Handle<Object> info = GetInfo(slot);
|
| + if (info->IsAllocationSite()) {
|
| + return Handle<AllocationSite>::cast(info);
|
| + }
|
| + return Handle<AllocationSite>::null();
|
| +}
|
| +
|
| +
|
| Handle<AllocationSite> TypeFeedbackOracle::GetCallNewAllocationSite(int slot) {
|
| Handle<Object> info = GetInfo(slot);
|
| if (FLAG_pretenuring_call_new || info->IsAllocationSite()) {
|
|
|