- 06 Feb, 2018 1 commit
-
-
Michal Terepeta authored
Test Plan: ./validate Reviewers: goldfire, bgamari, simonmar Reviewed By: bgamari Subscribers: rwbarton, thomie, carter Differential Revision: https://phabricator.haskell.org/D4367
-
- 22 Nov, 2017 1 commit
-
-
Ben Gamari authored
Test Plan: validate Reviewers: bgamari, simonmar Reviewed By: bgamari Subscribers: rwbarton, thomie GHC Trac Issues: #14437 Differential Revision: https://phabricator.haskell.org/D4180
-
- 19 Sep, 2017 1 commit
-
-
Herbert Valerio Riedel authored
This switches the compiler/ component to get compiled with -XNoImplicitPrelude and a `import GhcPrelude` is inserted in all modules. This is motivated by the upcoming "Prelude" re-export of `Semigroup((<>))` which would cause lots of name clashes in every modulewhich imports also `Outputable` Reviewers: austin, goldfire, bgamari, alanz, simonmar Reviewed By: bgamari Subscribers: goldfire, rwbarton, thomie, mpickering, bgamari Differential Revision: https://phabricator.haskell.org/D3989
-
- 01 Aug, 2017 1 commit
-
-
Ryan Scott authored
GHC 8.2.1 is out, so now GHC's support window only extends back to GHC 8.0. This means we can delete gobs of code that was only used for GHC 7.10 support. Hooray! Test Plan: ./validate Reviewers: hvr, bgamari, austin, goldfire, simonmar Reviewed By: bgamari Subscribers: Phyx, rwbarton, thomie Differential Revision: https://phabricator.haskell.org/D3781
-
- 28 Apr, 2017 1 commit
-
-
Simon Peyton Jones authored
This patch in in preparation for the fix to Trac #13397 The code generator has a special case for case tagToEnum (a>#b) of False -> e1 True -> e2 but it was not doing nearly so well on case a>#b of DEFAULT -> e1 1# -> e2 This patch arranges to behave essentially identically in both cases. In due course we can eliminate the special case for tagToEnum#, once we've completed Trac #13397. The changes are: * Make CmmSink swizzle the order of a conditional where necessary; see Note [Improving conditionals] in CmmSink * Hack the general case of StgCmmExpr.cgCase so that it use NoGcInAlts for conditionals. This doesn't seem right, but it's the same choice as the tagToEnum version. Without it, code size increases a lot (more heap checks). There's a loose end here. * Add comments in CmmOpt.cmmMachOpFoldM
-
- 11 Feb, 2017 1 commit
-
-
Sergei Trofimovich authored
When adding a new primop cinimod noticed uninformative ghc panic: cmmMachOpFoldM: unknown unary op This change tweaks panic to contain the op: cmmMachOpFoldM: unknown unary op: MO_F_Neg W64 Signed-off-by:
Sergei Trofimovich <slyfox@gentoo.org>
-
- 05 Sep, 2016 1 commit
-
-
takano-akio authored
This implements #5615 for divInt# and modInt#. I also included rules to do constant-folding when the both arguments are known. Test Plan: validate Reviewers: austin, simonmar, bgamari Reviewed By: bgamari Subscribers: hvr, thomie Differential Revision: https://phabricator.haskell.org/D2486 GHC Trac Issues: #5615
-
- 10 Apr, 2016 1 commit
-
-
Herbert Valerio Riedel authored
The commit 28f951ed introduced the `-fmax-pmcheck-iterations` flag and set the default limit to 1e7 iterations. However, this value is still high enough that it can result GHC to exhibit memory spikes beyond 1 GiB of RAM usage (heap profile showed several `(:)`s, as well as `THUNK_2_0`, and `PmCon` during the memory spikes) A value of 2e6 seems to be a safer upper bound which still manages to let the checker not run into the limit in most cases. Test Plan: Validate, try building a few Hackage packages Reviewers: austin, gkaracha, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2095
-
- 21 Aug, 2015 1 commit
-
-
thomie authored
This reverses some of the work done in #1405, and goes back to the assumption that the bootstrap compiler understands GHC-haskell. In particular: * use MagicHash instead of _ILIT and _CLIT * pattern matching on I# if possible, instead of using iUnbox unnecessarily * use Int#/Char#/Addr# instead of the following type synonyms: - type FastInt = Int# - type FastChar = Char# - type FastPtr a = Addr# * inline the following functions: - iBox = I# - cBox = C# - fastChr = chr# - fastOrd = ord# - eqFastChar = eqChar# - shiftLFastInt = uncheckedIShiftL# - shiftR_FastInt = uncheckedIShiftRL# - shiftRLFastInt = uncheckedIShiftRL# * delete the following unused functions: - minFastInt - maxFastInt - uncheckedIShiftRA# - castFastPtr - panicDocFastInt and pprPanicFastInt * rename panicFastInt back to panic# These functions remain, since they actually do something: * iUnbox * bitAndFastInt * bitOrFastInt Test Plan: validate Reviewers: austin, bgamari Subscribers: rwbarton Differential Revision: https://phabricator.haskell.org/D1141 GHC Trac Issues: #1405
-
- 15 May, 2014 1 commit
-
-
Herbert Valerio Riedel authored
In some cases, the layout of the LANGUAGE/OPTIONS_GHC lines has been reorganized, while following the convention, to - place `{-# LANGUAGE #-}` pragmas at the top of the source file, before any `{-# OPTIONS_GHC #-}`-lines. - Moreover, if the list of language extensions fit into a single `{-# LANGUAGE ... -#}`-line (shorter than 80 characters), keep it on one line. Otherwise split into `{-# LANGUAGE ... -#}`-lines for each individual language extension. In both cases, try to keep the enumeration alphabetically ordered. (The latter layout is preferable as it's more diff-friendly) While at it, this also replaces obsolete `{-# OPTIONS ... #-}` pragma occurences by `{-# OPTIONS_GHC ... #-}` pragmas.
-
- 16 Jan, 2014 1 commit
-
-
Simon Marlow authored
By using the constant-folder to reduce it to an integer.
-
- 16 Oct, 2013 2 commits
-
-
Jan Stolarek authored
I am removing old loopification code that has been commented out for long long time. We now have loopification implemented in the code generator (see Note [Self-recursive tail calls]) so we won't need to resurect this old code.
-
Jan Stolarek authored
-
- 12 Nov, 2012 2 commits
-
-
Simon Marlow authored
-
Simon Marlow authored
This removes the OldCmm data type and the CmmCvt pass that converts new Cmm to OldCmm. The backends (NCGs, LLVM and C) have all been converted to consume new Cmm. The main difference between the two data types is that conditional branches in new Cmm have both true/false successors, whereas in OldCmm the false case was a fallthrough. To generate slightly better code we occasionally need to invert a conditional to ensure that the branch-not-taken becomes a fallthrough; this was previously done in CmmCvt, and it is now done in CmmContFlowOpt. We could go further and use the Hoopl Block representation for native code, which would mean that we could use Hoopl's postorderDfs and analyses for native code, but for now I've left it as is, using the old ListGraph representation for native code.
-
- 30 Oct, 2012 1 commit
-
-
gmainlan@microsoft.com authored
All Cmm procedures now include the set of global registers that are live on procedure entry, i.e., the global registers used to pass arguments to the procedure. Only global registers that are use to pass arguments are included in this list.
-
- 23 Oct, 2012 1 commit
-
-
Simon Marlow authored
(PicBaseReg + lit) + N ==> PicBaseReg + (lit+N)
-
- 08 Oct, 2012 1 commit
-
-
Simon Marlow authored
The main change here is that the Cmm parser now allows high-level cmm code with argument-passing and function calls. For example: foo ( gcptr a, bits32 b ) { if (b > 0) { // we can make tail calls passing arguments: jump stg_ap_0_fast(a); } return (x,y); } More details on the new cmm syntax are in Note [Syntax of .cmm files] in CmmParse.y. The old syntax is still more-or-less supported for those occasional code fragments that really need to explicitly manipulate the stack. However there are a couple of differences: it is now obligatory to give a list of live GlobalRegs on every jump, e.g. jump %ENTRY_CODE(Sp(0)) [R1]; Again, more details in Note [Syntax of .cmm files]. I have rewritten most of the .cmm files in the RTS into the new syntax, except for AutoApply.cmm which is generated by the genapply program: this file could be generated in the new syntax instead and would probably be better off for it, but I ran out of enthusiasm. Some other changes in this batch: - The PrimOp calling convention is gone, primops now use the ordinary NativeNodeCall convention. This means that primops and "foreign import prim" code must be written in high-level cmm, but they can now take more than 10 arguments. - CmmSink now does constant-folding (should fix #7219) - .cmm files now go through the cmmPipeline, and as a result we generate better code in many cases. All the object files generated for the RTS .cmm files are now smaller. Performance should be better too, but I haven't measured it yet. - RET_DYN frames are removed from the RTS, lots of code goes away - we now have some more canned GC points to cover unboxed-tuples with 2-4 pointers, which will reduce code size a little.
-
- 25 Sep, 2012 1 commit
-
-
Simon Marlow authored
-
- 12 Sep, 2012 1 commit
-
-
ian@well-typed.com authored
-
- 06 Aug, 2012 2 commits
-
-
ian@well-typed.com authored
This is a bit odd by itself, but it's a stepping stone on the way to putting "target unregisterised" into the settings file.
-
Simon Marlow authored
-
- 30 Jul, 2012 1 commit
-
-
Simon Marlow authored
Proc-point splitting is only required by backends that do not support having proc-points within a code block (that is, everything except the native backend, i.e. LLVM and C). Not doing proc-point splitting saves some compilation time, and might produce slightly better code in some cases.
-
- 04 Jul, 2012 1 commit
-
-
Simon Marlow authored
-
- 20 Jun, 2012 1 commit
-
-
Ian Lynagh authored
-
- 12 Jun, 2012 1 commit
-
-
Ian Lynagh authored
-
- 15 Mar, 2012 1 commit
-
-
Simon Marlow authored
-
- 09 Mar, 2012 1 commit
-
-
Simon Marlow authored
-
- 06 Mar, 2012 2 commits
-
-
Simon Marlow authored
-
Simon Marlow authored
This reverts commit 5ff03ca7.
-
- 02 Mar, 2012 1 commit
-
-
Simon Marlow authored
This reverts commit 3d8ab554.
-
- 27 Feb, 2012 1 commit
-
-
Ian Lynagh authored
-
- 23 Feb, 2012 1 commit
-
-
Ian Lynagh authored
No special-casing in any NCGs yet
-
- 15 Feb, 2012 1 commit
-
-
Simon Marlow authored
- inline x = R1, even if x occurs many times - inline past a store, if the expression is not a load (we could further refine this of course, but the idea here is to get reasonable code for not much effort)
-
- 10 Jan, 2012 1 commit
-
-
dterei authored
We now carry around with CmmJump statements a list of the STG registers that are live at that jump site. This is used by the LLVM backend so it can avoid unnesecarily passing around dead registers, improving perfromance. This gives us the framework to finally fix trac #4308.
-
- 06 Jan, 2012 2 commits
- 29 Nov, 2011 1 commit
-
-
Simon Marlow authored
This field was doing nothing. I think it originally appeared in a very old incarnation of the new code generator.
-
- 05 Nov, 2011 2 commits
-
-
Ian Lynagh authored
-
Ian Lynagh authored
-