Remove a jump in StrictEqual stub when type feedback is not required.

CodeStubAssembler::StrictEqual is modified to collect type feedback when
requested (https://chromium-review.googlesource.com/c/483399/). There 
are a couple of Gotos introduced in that cl, which are only necessary
when collecting type feedback. Changed it to generate these Gotos only
whencollecting type feedback.

Bug: v8:4280
Change-Id: I322a6065efcfb601bd9f5dc25be6e6bb00b2d1c0
Reviewed-on: https://chromium-review.googlesource.com/496268
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Mythri Alle <mythria@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45135}
This commit is contained in:
Mythri 2017-05-04 18:03:49 +01:00 committed by Commit Bot
parent 2ed278f04a
commit 919530ac54

View File

@ -7866,9 +7866,11 @@ Node* CodeStubAssembler::StrictEqual(Node* lhs, Node* rhs,
}
BIND(&if_lhsisnotstring);
GotoIfNot(IsJSReceiverInstanceType(lhs_instance_type), &if_notequal);
GotoIfNot(IsJSReceiverInstanceType(rhs_instance_type), &if_notequal);
if (var_type_feedback != NULL) {
GotoIfNot(IsJSReceiverInstanceType(lhs_instance_type),
&if_notequal);
GotoIfNot(IsJSReceiverInstanceType(rhs_instance_type),
&if_notequal);
var_type_feedback->Bind(
SmiConstant(CompareOperationFeedback::kReceiver));
}