Closed Bug 1995522 Opened 6 months ago Closed 6 months ago

Use clang-include-cleaner to prevent inclusion of unused mfbt headers

Categories

(Core :: MFBT, task)

task

Tracking

()

RESOLVED FIXED
147 Branch
Tracking Status
firefox147 --- fixed

People

(Reporter: sergesanspaille, Assigned: sergesanspaille)

References

(Blocks 1 open bug, Regressed 1 open bug)

Details

Attachments

(2 files)

clang-include-cleaner has several option that make it a good candidate for an incremental adoption of an automated include cleaner:

  • one can limit the analysis to a few headers
  • one can limit the analysis to include removal

I've been cleaning mfbt header inclusion recently, I think we're good to start small with that tool with a focus on "no unused mfbt header inclusion"

Assignee: nobody → sguelton

The Bugbug bot thinks this bug should belong to the 'Core::MFBT' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: General → MFBT
Attachment #9521363 - Attachment description: WIP: Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium → WIP: Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium!
Depends on: 1996223
Depends on: 1996048
Depends on: 1996047
Depends on: 1996049
Depends on: 1996255
Depends on: 1990280
Depends on: 1991858
Depends on: 1991864
Depends on: 1993115
Depends on: 1993127
Depends on: 1993159
Depends on: 1993174
Depends on: 1993176
Depends on: 1993178
Depends on: 1993189
Depends on: 1993970
Depends on: 1993972
Depends on: 1993977
Depends on: 1993979
Depends on: 1994000
Depends on: 1994393
Depends on: 1994434
Depends on: 1994475
Depends on: 1994477
Depends on: 1994626
Depends on: 1994628
Depends on: 1995723
Depends on: 1995938
Attachment #9521363 - Attachment description: WIP: Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium! → Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium!
Depends on: 1996523
Depends on: 1996566
Depends on: 1996596
Depends on: 1996600
Depends on: 1993940
Depends on: 1992012
Depends on: 1990296
Depends on: 1996641
Depends on: 1996662
Depends on: 1996697
Depends on: 1996766
Depends on: 1996767
Depends on: 1996908
Depends on: 1996909
Depends on: 1996911
Depends on: 1996912
Depends on: 1996913
Depends on: 1996916
Depends on: 1996917
Depends on: 1996920
Depends on: 1996939
Depends on: 1997160
Depends on: 1997162
Depends on: 1997163
Depends on: 1997165
Depends on: 1997166
Depends on: 1997204

Those are the remaining parts required before we land the new mhbt
header inclusion linter

Attachment #9521363 - Attachment description: Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium! → Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=emilio
Attachment #9521363 - Attachment description: Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=emilio → Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=standard8!
Attachment #9523704 - Attachment description: Bug 1995522 - Cleanup remaining unused mfbt includes r=emilio → Bug 1995522 - Cleanup remaining unused mfbt includes r=emilio!
Pushed by sguelton@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/f7628a0557f7 https://hg.mozilla.org/integration/autoland/rev/1f79153b0370 New Linter - ensure we don't include unnecessary mfbt headers r=glandium,linter-reviewers,ahal
Pushed by agoloman@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/4c7ef1719715 https://hg.mozilla.org/integration/autoland/rev/b4f0df728692 Revert "Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium,linter-reviewers,ahal" for causing linting failures @MemMapSnapshot.h.

Backed out for causing linting failures @MemMapSnapshot.h.

Flags: needinfo?(sguelton)
Pushed by sguelton@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/d0eaaff18d27 https://hg.mozilla.org/integration/autoland/rev/3ebfe1ca67d0 Cleanup remaining unused mfbt includes r=emilio,necko-reviewers,media-playback-reviewers,webrtc-reviewers,profiler-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,layout-reviewers,dom-worker-reviewers,emz,mstange,TYLin,alwu,pehrsons,dom-storage-reviewers,valentin,jari,jwatt,hsingh,edenchuang,janv
Pushed by sguelton@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/3f4162216343 https://hg.mozilla.org/integration/autoland/rev/5755734bbadb New Linter - ensure we don't include unnecessary mfbt headers r=glandium,linter-reviewers,ahal
Flags: needinfo?(sguelton)
Status: NEW → RESOLVED
Closed: 6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 147 Branch
Pushed by chorotan@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/17287b2ae8ef https://hg.mozilla.org/integration/autoland/rev/5ed2a8d8d0c1 Revert "Bug 1995522 - Cleanup remaining unused mfbt includes r=emilio,necko-reviewers,media-playback-reviewers,webrtc-reviewers,profiler-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,layout-reviewers,dom-worker-reviewers,emz,mstange,TYLin,alwu,pehrsons,dom-storage-reviewers,valentin,jari,jwatt,hsingh,edenchuang,janv" for causing conflict on reverting Bug 1998267
Pushed by chorotan@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/dada95df6235 https://hg.mozilla.org/integration/autoland/rev/8f16036f9483 Revert "Bug 1995522 - New Linter - ensure we don't include unnecessary mfbt headers r=glandium,linter-reviewers,ahal" in addition to Bug 1995522

Backed out here https://hg.mozilla.org/integration/autoland/rev/5ed2a8d8d0c1872bc50d5323b87af317827dfbec and https://hg.mozilla.org/integration/autoland/rev/8f16036f9483a48357d16a63fdec8674a2520a9d for causing build bustages when https://bugzilla.mozilla.org/show_bug.cgi?id=1998267 was backed out.

The backout wasn't caused by any issue you introduced, but by a dependency problem, sorry about that.

Status: RESOLVED → REOPENED
Flags: needinfo?(sguelton)
Resolution: FIXED → ---
Target Milestone: 147 Branch → ---
Pushed by sguelton@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/5507f1c19ac1 https://hg.mozilla.org/integration/autoland/rev/bf315e222e06 Cleanup remaining unused mfbt includes r=emilio,necko-reviewers,media-playback-reviewers,webrtc-reviewers,profiler-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,layout-reviewers,dom-worker-reviewers,emz,mstange,TYLin,alwu,pehrsons,dom-storage-reviewers,valentin,jari,jwatt,hsingh,edenchuang,janv https://github.com/mozilla-firefox/firefox/commit/ae90c334421a https://hg.mozilla.org/integration/autoland/rev/2a821d61fc12 New Linter - ensure we don't include unnecessary mfbt headers r=glandium,linter-reviewers,ahal
Flags: needinfo?(sguelton)
Status: REOPENED → RESOLVED
Closed: 6 months ago6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 147 Branch
QA Whiteboard: [qa-triage-done-c148/b147]
Regressions: 2038003
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: