Bug 191729 - KnownCellUse should also have SpecCellCheck as its type filter
Summary: KnownCellUse should also have SpecCellCheck as its type filter
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: 2018-11-15 17:53 PST by Saam Barati
Modified: 2018-11-16 12:43 PST (History)
12 users (show)

See Also:


Attachments
patch (3.57 KB, patch)
2018-11-15 17:59 PST, Saam Barati
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Saam Barati 2018-11-15 17:53:18 PST
We write transformations in the compiler like this where we emit edges with KnownCellUse if we know we're inserting code at a point where we're dominated by a Cell check:

a: SomeValue
b: Something(Cell:@a)
c: SomethingElse(@b)
d: CheckNotEmpty(@a)

=>

a: SomeValue
b: Something(Cell:@a)
e: RandomOtherThing(KnownCellUse:@a)
c: SomethingElse(@b)
d: CheckNotEmpty(@a)

However, doing this may lead to subtly incorrect programs since KnownCellUse doesn't allow the empty value to flow through it. We end up deleting @d in the above program, which is wrong. We need to have KnownCellUse allow the empty value to flow through.
Comment 1 Saam Barati 2018-11-15 17:53:53 PST
<rdar://problem/45872852>
Comment 2 Saam Barati 2018-11-15 17:59:35 PST
Created attachment 355005 [details]
patch
Comment 3 WebKit Commit Bot 2018-11-16 12:43:01 PST
Comment on attachment 355005 [details]
patch

Clearing flags on attachment: 355005

Committed r238297: <https://trac.webkit.org/changeset/238297>
Comment 4 WebKit Commit Bot 2018-11-16 12:43:03 PST
All reviewed patches have been landed.  Closing bug.