perf: add ghc 9.12 options -fexpose-overloaded-unfoldings -fspecialise-aggressively

Before 9.12.1 it was necessary to mark functions as INLINABLE or INLINE to make GHC consider cross-module specialization of polymorphic functions.
9.12 added a new -fexpose-overloaded-unfoldings flag that exposes optimized polymorphic functions in interface files. -fspecialise-aggressively then makes GHC apply aggresive specialization.
This commit is contained in:
Michał Kłeczek
2026-06-17 13:13:48 +05:00
committed by Taimoor Zaeem
parent 9048332b0e
commit 9f97147cc3
+2
View File
@@ -178,6 +178,8 @@ library
ghc-options: -fhpc -hpcdir .hpc
else
ghc-options: -O2
if impl(ghc >= 9.12)
ghc-options: -fexpose-overloaded-unfoldings -fspecialise-aggressively
if !os(windows)
build-depends: