Skip to content
Snippets Groups Projects
  1. Apr 04, 2023
    • Josh Meredith's avatar
      JS: fix bounds checking · 75ea4767
      Josh Meredith authored
      75ea4767
    • sheaf's avatar
      Relax assertion in varToRecFieldOcc · cd00e321
      sheaf authored and Marge Bot's avatar Marge Bot committed
      When using Template Haskell, it is possible to re-parent a field OccName
      belonging to one data constructor to another data constructor. The
      lsp-types package did this in order to "extend" a data constructor
      with additional fields.
      
      This ran into an assertion in 'varToRecFieldOcc'. This assertion
      can simply be relaxed, as the resulting splices are perfectly sound.
      
      Fixes #23220
      cd00e321
    • Matthew Craven's avatar
      StgToCmm: Upgrade -fcheck-prim-bounds behavior · f7da530c
      Matthew Craven authored and Marge Bot's avatar Marge Bot committed
      Fixes #21054. Additionally, we can now check for range overlap
      when generating Cmm for primops that use memcpy internally.
      f7da530c
    • Matthew Craven's avatar
      Add a few more memcpy-ish primops · 9095e297
      Matthew Craven authored and Marge Bot's avatar Marge Bot committed
      * copyMutableByteArrayNonOverlapping#
      * copyAddrToAddr#
      * copyAddrToAddrNonOverlapping#
      * setAddrRange#
      
      The implementations of copyBytes, moveBytes, and fillBytes
      in base:Foreign.Marshal.Utils now use these new primops,
      which can cause us to work a bit harder generating code for them,
      resulting in the metric increase in T21839c observed by CI on
      some architectures.  But in exchange, we get better code!
      
      Metric Increase:
          T21839c
      9095e297
  2. Apr 03, 2023
    • Krzysztof Gogolewski's avatar
      Fixes around unsafeCoerce# · 220a7a48
      Krzysztof Gogolewski authored and Marge Bot's avatar Marge Bot committed
      1. `unsafeCoerce#` was documented in `GHC.Prim`. But since the overhaul
      in 74ad75e8, `unsafeCoerce#` is no longer defined there.
      I've combined the documentation in `GHC.Prim` with the `Unsafe.Coerce` module.
      
      2. The documentation of `unsafeCoerce#` stated that you should not
      cast a function to an algebraic type, even if you later cast it back
      before applying it. But ghci was doing that type of cast, as can be seen
      with 'ghci -ddump-ds' and typing 'x = not'. I've changed it to use Any
      following the documentation.
      220a7a48
    • Haskell-mouse's avatar
      Convert diagnostics in GHC.Rename.HsType to proper TcRnMessage · 8b092910
      Haskell-mouse authored and Marge Bot's avatar Marge Bot committed
      I've turned all occurrences of TcRnUnknownMessage in GHC.Rename.HsType
      module into a proper TcRnMessage.
      Instead, these TcRnMessage messages were introduced:
      
      TcRnDataKindsError
      TcRnUnusedQuantifiedTypeVar
      TcRnIllegalKindSignature
      TcRnUnexpectedPatSigType
      TcRnSectionPrecedenceError
      TcRnPrecedenceParsingError
      TcRnIllegalKind
      TcRnNegativeNumTypeLiteral
      TcRnUnexpectedKindVar
      TcRnBindMultipleVariables
      TcRnBindVarAlreadyInScope
      8b092910
    • Sylvain Henry's avatar
      JS: fix issues with FD api support · a8e36892
      Sylvain Henry authored and Marge Bot's avatar Marge Bot committed
      - Add missing implementations for fcntl_read/write/lock
      - Fix fdGetMode
      
      These were found while implementing TH in !9779. These functions must be
      used somehow by the external interpreter code.
      a8e36892
    • Krzysztof Gogolewski's avatar
      hadrian: Improve option parsing · 53e4d513
      Krzysztof Gogolewski authored and Marge Bot's avatar Marge Bot committed
      Several options in Hadrian had their argument marked as optional
      (`OptArg`), but if the argument wasn't there they were just giving an
      error. It's more idiomatic to mark the argument as required instead;
      the code uses less Maybes, the parser can enforce that the argument
      is present, --help gives better output.
      53e4d513
    • Matthew Pickering's avatar
      ci: Add job to test 9.6 bootstrapping · c2605e25
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      c2605e25
    • Matthew Pickering's avatar
      hadrian: Update bootstrap plans for 9.2.6, 9.2.7, 9.4.4, 9.4.5, 9.6.1 · 2b2afff3
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      Also fixes the ./generate_bootstrap_plans script which was recently
      broken
      
      We can hopefully drop the 9.2 plans soon but they still work so kept
      them around for now.
      2b2afff3
    • Sylvain Henry's avatar
      ghc-heap: remove wrong Addr# coercion (#23181) · ab9cd52d
      Sylvain Henry authored and Marge Bot's avatar Marge Bot committed
      Conversion from Addr# to I# isn't correct with the JS backend.
      ab9cd52d
  3. Apr 02, 2023
  4. Apr 01, 2023
    • sheaf's avatar
      TH: revert changes to GadtC & RecGadtC · 3b7bbb39
      sheaf authored and Marge Bot's avatar Marge Bot committed
      Commit 3f374399 included a breaking-change to the template-haskell
      library when it made the GadtC and RecGadtC constructors take non-empty
      lists of names. As this has the potential to break many users' packages,
      we decided to revert these changes for now.
      3b7bbb39
    • sheaf's avatar
      Improve haddocks of template-haskell Con datatype · 3da69346
      sheaf authored and Marge Bot's avatar Marge Bot committed
      This adds a bit more information, in particular about the lists of
      constructors in the GadtC and RecGadtC cases.
      3da69346
    • jeffrey young's avatar
      JS: Linker: use saturated JExpr · 6e2eb275
      jeffrey young authored and Marge Bot's avatar Marge Bot committed
      Follow on to MR!10142 in pursuit of #22736
      6e2eb275
    • Torsten Schmits's avatar
      Add structured error messages for GHC.Tc.TyCl · a84fba6e
      Torsten Schmits authored and Marge Bot's avatar Marge Bot committed
      Tracking ticket: #20117
      
      MR: !10183
      
      This converts uses of `mkTcRnUnknownMessage` to newly added constructors
      of `TcRnMessage`.
      a84fba6e
    • jeffrey young's avatar
      driver: Unit State Data.Map -> GHC.Unique.UniqMap · 3b5be05a
      jeffrey young authored and Marge Bot's avatar Marge Bot committed
      In pursuit of #22426. The driver and unit state are major contributors.
      
      This commit also bumps the haddock submodule to reflect the API changes in
      UniqMap.
      
      -------------------------
      Metric Decrease:
          MultiComponentModules
          MultiComponentModulesRecomp
          T10421
          T10547
          T12150
          T12234
          T12425
          T13035
          T16875
          T18140
          T18304
          T18698a
          T18698b
          T18923
          T20049
          T5837
          T6048
          T9198
      -------------------------
      3b5be05a
    • Artem Pelenitsyn's avatar
      User Guide: update copyright year: 2020->2023 · 77c33fb9
      Artem Pelenitsyn authored and Marge Bot's avatar Marge Bot committed
      77c33fb9
    • Magnus Viernickel's avatar
      [feat] make ($) representation polymorphic · 62d25071
      Magnus Viernickel authored and Marge Bot's avatar Marge Bot committed
      - this change was approved by the CLC in [1] following a CLC proposal [2]
      - make ($) representation polymorphic (adjust the type signature)
      - change ($) implementation to allow additional polymorphism
      - adjust the haddock of ($) to reflect these changes
      - add additional documentation to document these changes
      - add changelog entry
      - adjust tests (move now succeeding tests and adjust stdout of some
        tests)
      
      [1] https://github.com/haskell/core-libraries-committee/issues/132#issuecomment-1487456854
      [2] https://github.com/haskell/core-libraries-committee/issues/132
      62d25071
    • Matthew Pickering's avatar
      Add test for T23184 · 0077cb22
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      There was an outright bug, which Simon fixed in July 2021, as a little side-fix on a complicated patch:
      
      ```
      commit 6656f016
      Author: Simon Peyton Jones <simonpj@microsoft.com>
      Date:   Fri Jul 23 23:57:01 2021 +0100
      
          A bunch of changes related to eta reduction
      
          This is a large collection of changes all relating to eta
          reduction, originally triggered by #18993, but there followed
          a long saga.
      
          Specifics:
      
      ...lots of lines omitted...
      
          Other incidental changes
      
          * Fix a fairly long-standing outright bug in the ApplyToVal case of
            GHC.Core.Opt.Simplify.mkDupableContWithDmds. I was failing to take the
            tail of 'dmds' in the recursive call, which meant the demands were All
            Wrong.  I have no idea why this has not caused problems before now.
      ```
      
      Note this "Fix a fairly longstanding outright bug".   This is the specific fix
      ```
      @@ -3552,8 +3556,8 @@ mkDupableContWithDmds env dmds
               --              let a = ...arg...
               --              in [...hole...] a
               -- NB: sc_dup /= OkToDup; that is caught earlier by contIsDupable
      -    do  { let (dmd:_) = dmds   -- Never fails
      -        ; (floats1, cont') <- mkDupableContWithDmds env dmds cont
      +    do  { let (dmd:cont_dmds) = dmds   -- Never fails
      +        ; (floats1, cont') <- mkDupableContWithDmds env cont_dmds cont
               ; let env' = env `setInScopeFromF` floats1
               ; (_, se', arg') <- simplArg env' dup se arg
               ; (let_floats2, arg'') <- makeTrivial env NotTopLevel dmd (fsLit "karg") arg'
      ```
      Ticket #23184 is a report of the bug that this diff fixes.
      0077cb22
  5. Mar 30, 2023
Loading