Cheng Shao pushed to branch wip/fix-use-std-ap-thunk at Glasgow Haskell Compiler / GHC Commits: db03380d by Cheng Shao at 2026-07-13T19:34:33+02:00 compiler: fix redundant AP thunk codegen when not using -ticky-ap-thunk This patch fixes a typo in !7525 that results in some redundant AP thunk code generation when not using -ticky-ap-thunk. Fixes #27502. ------------------------- Metric Decrease: T3064 ------------------------- Co-authored-by: Codex <codex@openai.com> - - - - - 2 changed files: - + changelog.d/fix-use-std-ap-thunk - compiler/GHC/StgToCmm/Bind.hs Changes: ===================================== changelog.d/fix-use-std-ap-thunk ===================================== @@ -0,0 +1,4 @@ +section: codegen +synopsis: Fix redundant AP thunk codegen when not using -ticky-ap-thunk +issues: #27502 +mrs: !16340 ===================================== compiler/GHC/StgToCmm/Bind.hs ===================================== @@ -280,7 +280,7 @@ cgRhs id (StgRhsClosure fvs cc upd_flag args body _typ) = do profile <- getProfile check_tags <- stgToCmmDoTagCheck <$> getStgToCmmConfig - use_std_ap_thunk <- stgToCmmTickyAP <$> getStgToCmmConfig + use_std_ap_thunk <- not . stgToCmmTickyAP <$> getStgToCmmConfig mkRhsClosure profile use_std_ap_thunk check_tags id cc (nonVoidIds (dVarSetElems fvs)) upd_flag args body ------------------------------------------------------------------------ View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/db03380daf537bf29afdf65fc9128ea0... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/db03380daf537bf29afdf65fc9128ea0... You're receiving this email because of your account on gitlab.haskell.org. Manage all notifications: https://gitlab.haskell.org/-/profile/notifications | Help: https://gitlab.haskell.org/help
participants (1)
-
Cheng Shao (@TerrorJack)