[Git][ghc/ghc][wip/marge_bot_batch_merge_job] 9 commits: Add outputable instances for the types in GHC.Iface.Ext.Types, add -ddump-hie
Marge Bot
gitlab at gitlab.haskell.org
Thu Apr 2 16:44:12 UTC 2020
Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC
Commits:
3eee6d7d by Zubin Duggal at 2020-04-02T12:43:56-04:00
Add outputable instances for the types in GHC.Iface.Ext.Types, add -ddump-hie
flag to dump pretty printed contents of the .hie file
Metric Increase:
hie002
Because of the regression on i386:
compile_time/bytes allocated increased from i386-linux-deb9 baseline @ HEAD~10:
Expected hie002 (normal) compile_time/bytes allocated: 583014888.0 +/-10%
Lower bound hie002 (normal) compile_time/bytes allocated: 524713399
Upper bound hie002 (normal) compile_time/bytes allocated: 641316377
Actual hie002 (normal) compile_time/bytes allocated: 877986292
Deviation hie002 (normal) compile_time/bytes allocated: 50.6 %
*** unexpected stat test failure for hie002(normal)
- - - - -
7b976f7e by Andreas Klebinger at 2020-04-02T12:43:56-04:00
Improve and refactor StgToCmm codegen for DataCons.
We now differentiate three cases of constructor bindings:
1)Bindings which we can "replace" with a reference to
an existing closure. Reference the replacement closure
when accessing the binding.
2)Bindings which we can "replace" as above. But we still
generate a closure which will be referenced by modules
importing this binding.
3)For any other binding generate a closure. Then reference
it.
Before this patch 1) did only apply to local bindings and we
didn't do 2) at all.
- - - - -
43973bd6 by Moritz Bruder at 2020-04-02T12:43:57-04:00
Add singleton to NonEmpty in libraries/base
This adds a definition to construct a singleton non-empty list
(Data.List.NonEmpty) according to issue #17851.
- - - - -
aa86107a by Sylvain Henry at 2020-04-02T12:43:59-04:00
Testsuite: measure compiler stats for T16190
We were mistakenly measuring program stats
- - - - -
ed63ae22 by Sylvain Henry at 2020-04-02T12:43:59-04:00
Move blob handling into StgToCmm
Move handling of big literal strings from CmmToAsm to StgToCmm. It
avoids the use of `sdocWithDynFlags` (cf #10143). We might need to move
this handling even higher in the pipeline in the future (cf #17960):
this patch will make it easier.
- - - - -
6e3d0cb1 by Sylvain Henry at 2020-04-02T12:43:59-04:00
Refactor CmmStatics
In !2959 we noticed that there was some redundant code (in GHC.Cmm.Utils
and GHC.Cmm.StgToCmm.Utils) used to deal with `CmmStatics` datatype
(before SRT generation) and `RawCmmStatics` datatype (after SRT
generation).
This patch removes this redundant code by using a single GADT for
(Raw)CmmStatics.
- - - - -
bb413155 by Maxim Koltsov at 2020-04-02T12:44:01-04:00
Fix haddock formatting in Control.Monad.ST.Lazy.Imp.hs
- - - - -
026dcb5d by Andreas Klebinger at 2020-04-02T12:44:02-04:00
Turn newlines into spaces for hadrian/ghci.
The newlines break the command on windows.
- - - - -
0465a64d by Simon Peyton Jones at 2020-04-02T12:44:02-04:00
Major improvements to the specialiser
This patch is joint work of Alexis King and Simon PJ. It does some
significant refactoring of the type-class specialiser. Main highlights:
* We can specialise functions with types like
f :: Eq a => a -> Ord b => b => blah
where the classes aren't all at the front (#16473). Here we can
correctly specialise 'f' based on a call like
f @Int @Bool dEqInt x dOrdBool
This change really happened in an earlier patch
commit 2d0cf6252957b8980d89481ecd0b79891da4b14b
Author: Sandy Maguire <sandy at sandymaguire.me>
Date: Thu May 16 12:12:10 2019 -0400
work that this new patch builds directly on that work, and refactors
it a bit.
* We can specialise functions with implicit parameters (#17930)
g :: (?foo :: Bool, Show a) => a -> String
Previously we could not, but now they behave just like a non-class
argument as in 'f' above.
* We can specialise under-saturated calls, where some (but not all of
the dictionary arguments are provided (#17966). For example, we can
specialise the above 'f' based on a call
map (f @Int dEqInt) xs
even though we don't (and can't) give Ord dictionary.
This may sound exotic, but #17966 is a program from the wild, and
showed significant perf loss for functions like f, if you need
saturation of all dictionaries.
* We fix a buglet in which a floated dictionary had a bogus demand
(#17810), by using zapIdDemandInfo in the NonRec case of specBind.
* A tiny side benefit: we can drop dead arguments to specialised
functions; see Note [Drop dead args from specialisations]
* Fixed a bug in deciding what dictionaries are "interesting"; see
Note [Keep the old dictionaries interesting]
This is all achieved by by building on Sandy Macguire's work in
defining SpecArg, which mkCallUDs uses to describe the arguments of
the call. Main changes:
* Main work is in specHeader, which marched down the [InBndr] from the
function definition and the [SpecArg] from the call site, together.
* specCalls no longer has an arity check; the entire mechanism now
handles unders-saturated calls fine.
* mkCallUDs decides on an argument-by-argument basis whether to
specialise a particular dictionary argument; this is new.
See mk_spec_arg in mkCallUDs.
It looks as if there are many more lines of code, but I think that
all the extra lines are comments!
- - - - -
30 changed files:
- compiler/GHC/Cmm.hs
- compiler/GHC/Cmm/DebugBlock.hs
- compiler/GHC/Cmm/Info.hs
- compiler/GHC/Cmm/Info/Build.hs
- compiler/GHC/Cmm/Parser.y
- compiler/GHC/Cmm/Ppr/Decl.hs
- compiler/GHC/Cmm/Utils.hs
- compiler/GHC/CmmToAsm/PPC/CodeGen.hs
- compiler/GHC/CmmToAsm/PPC/Ppr.hs
- compiler/GHC/CmmToAsm/PPC/RegInfo.hs
- compiler/GHC/CmmToAsm/Ppr.hs
- compiler/GHC/CmmToAsm/SPARC/CodeGen.hs
- compiler/GHC/CmmToAsm/SPARC/CodeGen/Gen32.hs
- compiler/GHC/CmmToAsm/SPARC/Ppr.hs
- compiler/GHC/CmmToAsm/SPARC/ShortcutJump.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToAsm/X86/Ppr.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/CmmToLlvm.hs
- compiler/GHC/CmmToLlvm/Data.hs
- compiler/GHC/CmmToLlvm/Ppr.hs
- compiler/GHC/Core/Op/Specialise.hs
- compiler/GHC/Core/Subst.hs
- compiler/GHC/Core/Unfold.hs
- compiler/GHC/Driver/Flags.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Driver/Session.hs
- compiler/GHC/HsToCore/Binds.hs
- compiler/GHC/Iface/Ext/Debug.hs
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/14d8f5f360b195f79a04a73949d16b5861d5700e...0465a64d798cc8913325f571445a3d7504f2d92e
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/14d8f5f360b195f79a04a73949d16b5861d5700e...0465a64d798cc8913325f571445a3d7504f2d92e
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20200402/d713bb9f/attachment.html>
More information about the ghc-commits
mailing list