Open Bug 2089972 Opened 13 days ago Updated 6 days ago

Fix an impossible condition in wasm Instance::submitCallRefHints logging

Categories

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

task

Tracking

()

ASSIGNED

People

(Reporter: Sylvestre, Assigned: poglesbyg, Mentored)

References

(Blocks 1 open bug)

Details

(Keywords: good-first-bug, Whiteboard: [lang=c++])

Attachments

(1 external file)

Filing as a good first bug to learn workflows.

In Instance::submitCallRefHints, numCandidates > 0 && allCandidatesAreImports can never be true, so the JITSPEW log never reports that reason. It should test numCandidates == 0 (all candidates were imports and were skipped). Only the debug log text changes; generated code is unaffected.

Current code:

      skipReason = "(no individually tracked targets)";
    } else if (numCandidates > 0 && allCandidatesAreImports) {
      // Imported functions can't be inlined.

Link to the code:
https://searchfox.org/firefox-main/source/js/src/wasm/WasmInstance.cpp

To verify the fix:

./mach build
./mach jit-test wasm

This was reported by Coverity Scan (CID 1636951). The analyzer will stop reporting it once the change lands.

Tutorial to contribute:
https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html
https://firefox-source-docs.mozilla.org/contributing/stack_quickref.html

Please don't ask for the bug to be assigned. It will be automatically assigned to the first patch.

Severity: -- → N/A
Priority: -- → P3
Assignee: nobody → poglesbyg
Status: NEW → ASSIGNED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: