Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: e1171d7da90fa90cbec9c2881007361fa6516660
      
https://github.com/WebKit/WebKit/commit/e1171d7da90fa90cbec9c2881007361fa6516660
  Author: Sergey Rubanov <[email protected]>
  Date:   2026-07-16 (Thu, 16 Jul 2026)

  Changed paths:
    M JSTests/wasm/stress/exnref-global-get-segv.js
    M Source/JavaScriptCore/wasm/WasmGlobal.h
    M Source/JavaScriptCore/wasm/js/WebAssemblyModuleRecord.cpp

  Log Message:
  -----------
  [WASM] Allow linking immutable exnref global imports
https://bugs.webkit.org/show_bug.cgi?id=293340

Reviewed by Keith Miller.

Importing an immutable (ref null exn) global called Global::get(), which
rejects exnref for the JS API. Wasm-to-wasm linking only needs the stored
reference, not a JS-visible value.

Add Global::getReference() and use it when linking immutable exnref imports.
JS Global.value still rejects exnref.

* Source/JavaScriptCore/wasm/WasmGlobal.h:
(JSC::Wasm::Global::getReference): Added.
* Source/JavaScriptCore/wasm/js/WebAssemblyModuleRecord.cpp:
(JSC::WebAssemblyModuleRecord::initializeImports): Copy exnref via 
getReference().
* JSTests/wasm/stress/exnref-global-get-segv.js: Assert successful import and 
null value.

Canonical link: https://commits.webkit.org/317326@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to