Closed Bug 1896118 Opened 5 months ago Closed 4 months ago

ICF detection code doesn't work correctly

Categories

(Firefox Build System :: General, defect, P5)

defect

Tracking

(firefox128 fixed)

RESOLVED FIXED
128 Branch
Tracking Status
firefox128 --- fixed

People

(Reporter: sergesanspaille, Assigned: sergesanspaille)

References

Details

Attachments

(1 file)

The following configure invocation shows that icf is not correctly activated when it should be:

./mach configure --enable-release --enable-linker=lld --enable-optimize | grep Folding
 0:03.62 checking whether the linker supports Identical Code Folding... no
 0:04.67 js/src> checking whether the linker supports Identical Code Folding... (cached) no

Otherwise the two symbols checked have different code and icf doesn't happen.

The severity field is not set for this bug.
:ahochheiden, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(ahochheiden)
Severity: -- → S4
Flags: needinfo?(ahochheiden)
Priority: -- → P5
Attachment #9401095 - Attachment description: Bug 1896118 - icf detection check requires at least -O1 r=glandium → Bug 1896118 - Rework icf detection check r=glandium!
Attachment #9401095 - Attachment description: Bug 1896118 - Rework icf detection check r=glandium! → Bug 1896118 - Rework identical code folding detection check r=glandium
Pushed by sguelton@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/81a2357443c8 Rework identical code folding detection check r=glandium
Status: NEW → RESOLVED
Closed: 4 months ago
Resolution: --- → FIXED
Target Milestone: --- → 128 Branch
See Also: → 1899972

Does this only impact Linux? i.e. did we have ICF working on Windows?

Flags: needinfo?(sguelton)

No ICF on WIndows not OSX (because of the linker used). But We should have it on Android soo (see #1899972)

Flags: needinfo?(sguelton)

Actually, lld has ICF support for both macho and COFF, but that's through different flags.

In fact, we're already enabling ICF on Windows through https://searchfox.org/mozilla-central/rev/59d854a90e036cfa77f3c5b70c8c6ef1d60ebb98/python/mozbuild/mozbuild/frontend/context.py#492
We should probably handle it similarly to what we do on Linux.

Blocks: 1896116
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: