Bug 159775 - WebAssembly: support the newer spec
Summary: WebAssembly: support the newer spec
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Keith Miller
URL:
Keywords:
: 161728 (view as bug list)
Depends on: 161709 162976 165231 165833 165856 165862 166349 166442 168788 168836 169566 169792 169976 170215 170343 170360 170557 170690 170748 170773 170774 170788 170826 170970 170998 171263 160603 160681 160914 160928 161707 161710 161727 161728 161778 162693 163807 163919 163959 164444 164459 164724 165345 165471 165805 166199 166295 168672 168673 168694 168784 168822 168857 168861 169187 169794 169815 169882 169890 169892 170137 170218 170219 170227 170380 170628 170740 170782 170825 170909
Blocks: 146064
  Show dependency treegraph
 
Reported: 2016-07-14 11:47 PDT by Keith Miller
Modified: 2017-04-25 00:43 PDT (History)
14 users (show)

See Also:


Attachments
Patch (31.91 KB, patch)
2016-10-20 13:39 PDT, Keith Miller
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Keith Miller 2016-07-14 11:47:09 PDT
We should totes do this.
Comment 1 Keith Miller 2016-10-20 13:39:04 PDT
Created attachment 292244 [details]
Patch
Comment 2 Keith Miller 2016-10-20 13:42:07 PDT
Crap, I uploaded this to the wrong bug...
Comment 3 Geoffrey Garen 2016-10-20 13:54:56 PDT
Comment on attachment 292244 [details]
Patch

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

> Source/JavaScriptCore/ChangeLog:12
> +        address we need to call to.  For each callsite in the compiling function WASM remembers what

remembers what => remembers

> Source/JavaScriptCore/ChangeLog:14
> +        each functions callsites are linked to the appropriate entrypoint.

each callsite is linked to the appropriate entrypoint

> Source/JavaScriptCore/wasm/WASMB3IRGenerator.cpp:220
> +    Vector<UnlinkedLocationInfo>& m_unlinkedCalls;

UnlinkedLocationInfo holds a single CodeLocationCall. What's the "list of of callsites"?

> Source/JavaScriptCore/wasm/WASMB3IRGenerator.cpp:588
> +                    *callSiteLinkLocation = { linkBuffer.locationOf(call), functionIndex };

If m_unlinkedCalls grows enough before this patchpoint generator runs, callSiteLinkLocation becomes a stale pointer. I think you want an index instead of a pointer.

> Source/JavaScriptCore/wasm/WASMFormat.h:131
> +struct UnlinkedLocationInfo {

Can we call this UnlinkedCall or UnlinkedWASMCall or UnlinkedCallInfo? 'Location' is pretty vague.
Comment 4 JF Bastien 2017-01-03 20:39:10 PST
*** Bug 161728 has been marked as a duplicate of this bug. ***