summaryrefslogtreecommitdiff
path: root/compiler/GHC/Stg/Pipeline.hs
diff options
context:
space:
mode:
authorAndreas Klebinger <klebinger.andreas@gmx.at>2023-01-30 21:59:47 +0100
committerAndreas Klebinger <klebinger.andreas@gmx.at>2023-02-13 13:51:47 +0100
commit75b87ef65cda23ac48a48de485c7d229100144ea (patch)
tree3bc453320a583372ba47fac381734cde45d47a4e /compiler/GHC/Stg/Pipeline.hs
parent133516af8426d775fa0dc75c787edd56299ee6cf (diff)
downloadhaskell-wip/andreask/infer-bytecode.tar.gz
Fix some correctness issues around tag inference when targeting the bytecode generator.wip/andreask/infer-bytecode
* Let binders are now always assumed untagged for bytecode. * Imported referenced are now always assumed to be untagged for bytecode. Fixes #22840
Diffstat (limited to 'compiler/GHC/Stg/Pipeline.hs')
-rw-r--r--compiler/GHC/Stg/Pipeline.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/GHC/Stg/Pipeline.hs b/compiler/GHC/Stg/Pipeline.hs
index 9e20010cf7..348d8e0e8f 100644
--- a/compiler/GHC/Stg/Pipeline.hs
+++ b/compiler/GHC/Stg/Pipeline.hs
@@ -50,6 +50,7 @@ data StgPipelineOpts = StgPipelineOpts
-- ^ Should we lint the STG at various stages of the pipeline?
, stgPipeline_pprOpts :: !StgPprOpts
, stgPlatform :: !Platform
+ , stgPipeline_forBytecode :: !Bool
}
newtype StgM a = StgM { _unStgM :: ReaderT Char IO a }
@@ -89,7 +90,7 @@ stg2stg logger extra_vars opts this_mod binds
-- annotations (which is used by code generator to compute offsets into closures)
; let binds_sorted_with_fvs = depSortWithAnnotStgPgm this_mod binds'
-- See Note [Tag inference for interactive contexts]
- ; inferTags (stgPipeline_pprOpts opts) logger this_mod binds_sorted_with_fvs
+ ; inferTags (stgPipeline_pprOpts opts) (stgPipeline_forBytecode opts) logger this_mod binds_sorted_with_fvs
}
where