Closed Bug 1744711 Opened 2 years ago Closed 2 years ago

Permanent cranelift 2:13.57 /builds/worker/checkouts/gecko/js/src/wasm/WasmCraneliftCompile.cpp:252:57: error: no member named 'Dynamic' in 'js::wasm::CallSiteDesc'

Categories

(Core :: JavaScript: WebAssembly, defect, P3)

defect

Tracking

()

RESOLVED FIXED
97 Branch
Tracking Status
firefox-esr91 --- unaffected
firefox95 --- unaffected
firefox96 --- disabled
firefox97 --- fixed

People

(Reporter: intermittent-bug-filer, Assigned: yury)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: intermittent-failure, regression)

Attachments

(1 file)

Filed by: archaeopteryx [at] coole-files.de
Parsed log: https://treeherder.mozilla.org/logviewer?job_id=359380927&repo=mozilla-central
Full log: https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/PlqJyNJ8Rqa_oavw30BDPQ/runs/0/artifacts/public/logs/live_backing.log


[task 2021-11-26T16:13:11.381Z]  2:13.57 In file included from Unified_cpp_js_src_wasm1.cpp:38:
[task 2021-11-26T16:13:11.381Z]  2:13.57 /builds/worker/checkouts/gecko/js/src/wasm/WasmCraneliftCompile.cpp:252:57: error: no member named 'Dynamic' in 'js::wasm::CallSiteDesc'
[task 2021-11-26T16:13:11.381Z]  2:13.57         CallSiteDesc desc(bytecodeOffset, CallSiteDesc::Dynamic);
[task 2021-11-26T16:13:11.382Z]  2:13.57                                           ~~~~~~~~~~~~~~^

Oh, this'll be interesting.

Assignee: nobody → lhansen
Blocks: 1742930
Status: NEW → ASSIGNED
Flags: needinfo?(lhansen)
Priority: P5 → P3

Easy compile fix:

diff --git a/js/src/wasm/WasmCraneliftCompile.cpp b/js/src/wasm/WasmCraneliftCompile.cpp
--- a/js/src/wasm/WasmCraneliftCompile.cpp
+++ b/js/src/wasm/WasmCraneliftCompile.cpp
@@ -249,7 +249,7 @@ static bool GenerateCraneliftCode(
         break;
       }
       case CraneliftMetadataEntry::Which::IndirectCall: {
-        CallSiteDesc desc(bytecodeOffset, CallSiteDesc::Dynamic);
+        CallSiteDesc desc(bytecodeOffset, CallSiteDesc::Indirect);
         masm.append(desc, CodeOffset(offset.value()));
         break;
       }

but of course after that the test failures start trickling in because the calling conventions need to be adapted:

FAILURES:
    --wasm-compiler=optimizing wasm/resizing.js
    wasm/resizing.js
    --test-wasm-await-tier2 wasm/resizing.js
    --disable-wasm-huge-memory wasm/resizing.js
    --no-baseline --no-blinterp wasm/table-gc.js
    --no-baseline --no-blinterp --wasm-compiler=optimizing wasm/table-gc.js
    --no-baseline --no-blinterp --test-wasm-await-tier2 wasm/table-gc.js
    --no-baseline --no-blinterp --disable-wasm-huge-memory wasm/table-gc.js
    --wasm-compiler=optimizing wasm/timeout/2.js
    --test-wasm-await-tier2 wasm/timeout/2.js
    wasm/timeout/2.js
    --disable-wasm-huge-memory wasm/timeout/2.js

I think in order to fix this we need to port at least some of the recent changesets to WasmCraneliftCompile.cpp and its subsystem, possibly including cranelift itself. Going from earlier to later:

From this one, I believe we need to take the distinction between indirect calls and import calls.

changeset:   670921:314070fed10e
user:        Lars T Hansen <lhansen@mozilla.com>
date:        Fri Nov 26 08:20:12 2021 +0000
summary:     Bug 1742053 - Renamings and other prep work. r=dbezhetskov

From this one, we need to take the handling of realm swithcing and register reloading from the code generator and macro assembler:

changeset:   670930:324375982e5d
user:        Lars T Hansen <lhansen@mozilla.com>
date:        Fri Nov 26 08:20:16 2021 +0000
summary:     Bug 1742053 - Switchover part 1: calls and frames. r=dbezhetskov

Assignee: lhansen → nobody
Status: ASSIGNED → NEW

After a group discussion, the conclusion is that we will disable tier-2 compilation & testing of the cranelift configuration for now, and we'll alert the cranelift people to this discussion to let them have their say. If that decision is a problem we can instead try to backport the patches mentioned in the previous comment. If nobody complains, we will consider whether to update cranelift to the new ABI before the next ESR.

Assignee: nobody → ydelendik
Status: NEW → ASSIGNED
Pushed by ydelendik@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/694f8ab8602f
Stop running arm64-cranelift-sim during mc testing. r=lth
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 97 Branch
Has Regression Range: --- → yes
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: