Skip to content
Snippets Groups Projects
Forked from Glasgow Haskell Compiler / GHC
Loading
Cheng Shao's avatar
Cheng Shao authored
When -fsplit-sections is passed to GHC, pass -ffunction-sections
-fdata-sections to gcc/clang when building C/C++. Previously,
-fsplit-sections was only respected by the NCG/LLVM backends, but not
the unregisterised backend; the GHC driver did not pass
-fdata-sections and -ffunction-sections to the C compiler, which
resulted in excessive executable sizes.

Fixes #23381.

-------------------------
Metric Decrease:
    size_hello_artifact
    size_hello_unicode
-------------------------

(cherry picked from commit 02b1f91e)
74cdf564
History
Name Last commit Last update