Bug 210922 - Return BigInt32 whenever we can
Summary: Return BigInt32 whenever we can
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Saam Barati
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-04-23 10:19 PDT by Saam Barati
Modified: 2020-04-27 14:56 PDT (History)
17 users (show)

See Also:


Attachments
patch (67.76 KB, patch)
2020-04-24 14:57 PDT, Saam Barati
no flags Details | Formatted Diff | Diff
patch (69.74 KB, patch)
2020-04-24 15:53 PDT, Saam Barati
ysuzuki: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Saam Barati 2020-04-23 10:19:34 PDT
...
Comment 1 Saam Barati 2020-04-24 14:57:16 PDT
Created attachment 397514 [details]
patch
Comment 2 Saam Barati 2020-04-24 15:53:40 PDT
Created attachment 397523 [details]
patch
Comment 3 Yusuke Suzuki 2020-04-24 17:04:36 PDT
Comment on attachment 397523 [details]
patch

View in context: https://bugs.webkit.org/attachment.cgi?id=397523&action=review

r=me

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:555
> +        } else if (node->binaryUseKind() == HeapBigIntUse) {

Use `node->isBinaryUseKind(HeapBigIntUse)`.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:560
> +        } else if (node->binaryUseKind() == AnyBigIntUse)

Ditto.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:750
> +        if (node->binaryUseKind() == HeapBigIntUse) {

Use `node->isBinaryUseKind(HeapBigIntUse)`.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:755
> +        } else if (node->binaryUseKind() == AnyBigIntUse || node->binaryUseKind() == BigInt32Use)

Use `node->isBinaryUseKind(AnyBigIntUse) || node->isBinaryUseKind(BigInt32Use)`.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:1024
> +        if (node->binaryUseKind() == HeapBigIntUse) {

Use `node->isBinaryUseKind(HeapBigIntUse)`.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:1029
> +        } else if (node->binaryUseKind() == AnyBigIntUse || node->binaryUseKind() == BigInt32Use)

Ditto.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:1040
> +        if (node->binaryUseKind() == HeapBigIntUse) {

Ditto.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:1045
> +        } else if (node->binaryUseKind() == AnyBigIntUse || node->binaryUseKind() == BigInt32Use)

Ditto.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:1109
> +        if (node->binaryUseKind() == HeapBigIntUse) {

Ditto.

> Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:1114
> +        } else if (node->binaryUseKind() == AnyBigIntUse || node->binaryUseKind() == BigInt32Use)

Ditto.

> Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp:3748
> +    if (node->binaryUseKind() == HeapBigIntUse) {

`node->isBinaryUseKind(HeapBigIntUse)` would be better.

> Source/WebCore/ChangeLog:8
> +        No new tests (OOPS!).

Just remove it. This is already covered by existing tests.
Comment 4 Saam Barati 2020-04-24 17:36:03 PDT
landed in:
https://trac.webkit.org/changeset/260683/webkit
Comment 5 Radar WebKit Bug Importer 2020-04-24 17:37:14 PDT
<rdar://problem/62351393>