Closed Bug 1475444 Opened 6 years ago Closed 5 years ago

Spidermonkey source files aren't being instrumented for order files

Categories

(Firefox Build System :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: away, Unassigned)

References

Details

https://taskcluster-artifacts.net/ZNPCH_0UTIqylQAIaBBMpg/0/public/logs/live_backing.log

Garden-variety xul.dll files, e.g. Unified_cpp_crashreporter0.cpp, have `-Xclang -finstrument-functions-after-inlining` on their first compilation, as desired.

Spidermonkey files, e.g. Unified_cpp_js_src2.cpp and Interpreter.cpp, do not have those flags.
glandium, any ideas here? Does the `code_for_xul` check in emitter.py behave correctly for Spidermonkey files?
Flags: needinfo?(mh+mozilla)
No, spidermonkey doesn't set FINAL_LIBRARY. Many other things don't, by the way. The right way to find all the sources involved in libxul is to recurse through the libxul Library instance's linked_libraries. See what we do for LIBRARY_DEFINES.
Flags: needinfo?(mh+mozilla)
Doing the same thing as for LIBRARY_DEFINES to add the necessary flags to SM files (and possibly others?) is going to require reordering lots of things in the emitter, as we do linkage-related stuff after emitting flags, so we'd have to shuffle flags emission around until much later in the process...I think.
Oh, wait, we save the computed_flags objects in emit_from_context and only emit them later in _emit_libs_derived (even though, weirdly, we emit link flags when we might not be linking anything?).  So maybe this is not so bad.
Dumb question: can we get away with checking FINAL_LIBRARY against ('xul', 'js', 'gkmedias', 'webrtc', 'browsercomps')?
That would be a hack, but yes, that might work.

We also need to see if the JS shell would build properly.  A quick eyeballing of js/src/shell/backend.mk from a configured objdir suggests that everything would be OK, but there's no proof like building everything to see.
Not a single high-confidence perf change: https://treeherder.mozilla.org/perf.html#/compare?originalProject=try&originalRevision=58146443d7b7&newProject=try&newRevision=a11cee37910a&framework=1&showOnlyConfident=1

I looked over what files still didn't get the instrumentation flag and nothing stuck out. I guess I missed 'icu' in the list but that shouldn't matter.

So what do we do... incomplete?
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.