The default bug view has changed. See this FAQ.

jsapi.cpp hits build warnings (treated as errors) for NativeX64.h: "error: 'nanojit::SavedRegs' defined but not used", "error: 'nanojit::SingleByteStoreRegs' defined but not used"

RESOLVED FIXED

Status

Core Graveyard
Nanojit
RESOLVED FIXED
6 years ago
3 years ago

People

(Reporter: dholbert, Unassigned)

Tracking

(Blocks: 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [build_warning])

(Reporter)

Description

6 years ago
Quoting a recent red "warning as error" build from mozilla-inbound:
{
jsapi.cpp
cc1plus: warnings being treated as errors
[...]
/builds/slave/m-in-lnx64-dbg-spidermonkey-warnaserrdebug/src/js/src/nanojit/NativeX64.h: At global scope:
/builds/slave/m-in-lnx64-dbg-spidermonkey-warnaserrdebug/src/js/src/nanojit/NativeX64.h:347:31: error: 'nanojit::SavedRegs' defined but not used
/builds/slave/m-in-lnx64-dbg-spidermonkey-warnaserrdebug/src/js/src/nanojit/NativeX64.h:355:31: error: 'nanojit::SingleByteStoreRegs' defined but not used
}
http://tinderbox.mozilla.org/showlog.cgi?log=Mozilla-Inbound/1314861122.1314861238.19787.gz
mozilla-inbound_linux64-debug_spidermonkey-warnaserrdebug on 2011/09/01 00:12:02

It looks like there are a bunch of static const variables _defined_ (not declared) in this header, NativeX64.h, and those variables apparently trigger warnings for any .cpp files that #include NativeX64.h without using these variables.

Perhaps we should just be _declaring_ these variables in the header, and move their definitions to NativeX64.cpp?  (In fact, that's the only place SingleByteStoreRegs is even referenced, so in that case the variable could move to the .cpp file entirely, if it made sense.)

Updated

6 years ago
Whiteboard: [build_warning]
Nanojit has been removed.
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
(Assignee)

Updated

3 years ago
Component: Nanojit → Nanojit
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.