Revert "Use CopyElements (which uses memcpy) to copy FixedDoubleArray."
This reverts commit fac6f63eb8
.
Reason for revert: https://bugs.chromium.org/p/chromium/issues/detail?id=907479
Original change's description:
> Use CopyElements (which uses memcpy) to copy FixedDoubleArray.
>
> This improves the performance of ExtractFixedArray and
> CloneFastJSArray for double arrays, which in turn improve the
> performance of cloning double arrays with slice() or spreading.
>
> This, however, does not improve performance of spreading holey
> double arrays, because spreading needs extra work to convert
> holes to undefined.
>
> Bug: v8:7980
> Change-Id: Ib8aed74abbb0b06982a3b754e134fa415cb7de2d
> Reviewed-on: https://chromium-review.googlesource.com/c/1280308
> Reviewed-by: Michael Stanton <mvstanton@chromium.org>
> Reviewed-by: Georg Neis <neis@chromium.org>
> Reviewed-by: Sigurd Schneider <sigurds@chromium.org>
> Commit-Queue: Hai Dang <dhai@google.com>
> Cr-Commit-Position: refs/heads/master@{#56680}
TBR=mvstanton@chromium.org,neis@chromium.org,sigurds@chromium.org,dhai@google.com
# Not skipping CQ checks because original CL landed > 1 day ago.
Bug: v8:7980, chromium:907479
Change-Id: Iacf37fa3276345fe8e264fe976d296b015ed6790
Reviewed-on: https://chromium-review.googlesource.com/c/1351003
Reviewed-by: Sigurd Schneider <sigurds@chromium.org>
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57864}
This commit is contained in:
parent
a8152aac70
commit
ca39f55ae1
@ -4445,12 +4445,11 @@ TNode<FixedArrayBase> CodeStubAssembler::ExtractFixedArray(
|
||||
// the target are FixedDoubleArray. That it is PACKED or HOLEY does not
|
||||
// matter.
|
||||
ElementsKind kind = PACKED_DOUBLE_ELEMENTS;
|
||||
TNode<FixedArrayBase> to_elements = AllocateFixedArray(
|
||||
kind, capacity, parameter_mode, allocation_flags, source_map);
|
||||
Node* to_elements = AllocateFixedArray(kind, capacity, parameter_mode,
|
||||
allocation_flags, source_map);
|
||||
var_result.Bind(to_elements);
|
||||
CopyElements(kind, to_elements, IntPtrConstant(0), CAST(source),
|
||||
ParameterToIntPtr(first, parameter_mode),
|
||||
ParameterToIntPtr(count, parameter_mode));
|
||||
CopyFixedArrayElements(kind, source, kind, to_elements, first, count,
|
||||
capacity, SKIP_WRITE_BARRIER, parameter_mode);
|
||||
}
|
||||
|
||||
Goto(&done);
|
||||
|
Loading…
Reference in New Issue
Block a user