Skip to content
Snippets Groups Projects
  1. Jan 31, 2023
    • Ben Gamari's avatar
      configure: Always create the VERSION file · a2d814dc
      Ben Gamari authored and Marge Bot's avatar Marge Bot committed
      Teach the `configure` script to create the `VERSION` file.
      This will serve as the stable interface to allow the user to determine
      the version number of a working tree.
      
      Fixes #22322.
      a2d814dc
    • Krzysztof Gogolewski's avatar
      Support "unusable UNPACK pragma" warning with -O0 · f83374f8
      Krzysztof Gogolewski authored and Marge Bot's avatar Marge Bot committed
      Fixes #11270
      f83374f8
    • Simon Peyton Jones's avatar
      Improve exprOkForSpeculation for classops · a83c810d
      Simon Peyton Jones authored and Marge Bot's avatar Marge Bot committed
      This patch fixes #22745 and #15205, which are about GHC's
      failure to discard unnecessary superclass selections that
      yield coercions.  See
        GHC.Core.Utils Note [exprOkForSpeculation and type classes]
      
      The main changes are:
      
      * Write new Note [NON-BOTTOM_DICTS invariant] in GHC.Core, and
        refer to it
      
      * Define new function isTerminatingType, to identify those
        guaranteed-terminating dictionary types.
      
      * exprOkForSpeculation has a new (very simple) case for ClassOpId
      
      * ClassOpId has a new field that says if the return type is
        an unlifted type, or a terminating type.
      
      This was surprisingly tricky to get right.  In particular note
      that unlifted types are not terminating types; you can write an
      expression of unlifted type, that diverges.  Not so for dictionaries
      (or, more precisely, for the dictionaries that GHC constructs).
      
      Metric Decrease:
          LargeRecord
      a83c810d
    • jeffrey young's avatar
      FastString: add fastStringToShorText · 765fab98
      jeffrey young authored and Marge Bot's avatar Marge Bot committed
      765fab98
    • jeffrey young's avatar
      InfoTableProv: ShortText --> ShortByteString · 19c1fbcd
      jeffrey young authored and Marge Bot's avatar Marge Bot committed
      19c1fbcd
    • Cheng Shao's avatar
      testsuite: use tgamma for cg007 · 7716cbe6
      Cheng Shao authored and Marge Bot's avatar Marge Bot committed
      gamma is a glibc-only deprecated function, use tgamma instead. It's
      required for fixing cg007 when testing the wasm unregisterised
      codegen.
      7716cbe6
    • Joachim Breitner's avatar
      Update note at beginning of GHC.Builtin.NAmes · 085a6db6
      Joachim Breitner authored and Marge Bot's avatar Marge Bot committed
      some things have been renamed since it was written, it seems.
      085a6db6
    • Cheng Shao's avatar
      rts: prevent potential divide-by-zero when tickInterval=0 · fd8f32bf
      Cheng Shao authored and Marge Bot's avatar Marge Bot committed
      This patch fixes a few places in RtsFlags.c that may result in
      divide-by-zero error when tickInterval=0, which is the default on
      wasm. Fixes #22603.
      fd8f32bf
    • Matthew Pickering's avatar
      Fixes for cabal-reinstall CI job · 7cbdaad0
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      * Allow filepath to be reinstalled
      * Bump some version bounds to allow newer versions of libraries
      * Rework testing logic to avoid "install --lib" and package env files
      
      Fixes #22344
      7cbdaad0
    • jship's avatar
      User's guide: Clarify overlapping instance candidate elimination · b69461a0
      jship authored and Marge Bot's avatar Marge Bot committed
      This commit updates the user's guide section on overlapping instance candidate
      elimination to use "or" verbiage instead of "either/or" in regards to the
      current pair of candidates' being overlappable or overlapping. "Either IX is
      overlappable, or IY is overlapping" can cause confusion as it suggests "Either
      IX is overlappable, or IY is overlapping, but not both".
      
      This was initially discussed on this Discourse topic:
      
      https://discourse.haskell.org/t/clarification-on-overlapping-instance-candidate-elimination/5677
      b69461a0
    • Matthew Pickering's avatar
      gen_ci: Only consider release jobs for job metadata · 68eb8877
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      In particular we do not have a release job for FreeBSD so the generation
      of the platform mapping was failing.
      68eb8877
    • Matthew Pickering's avatar
      rel_eng: Fix the name of the ubuntu-* jobs · 7619c0b4
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      These were not uploaded for alpha1
      
      Fixes #22844
      7619c0b4
    • Matthew Pickering's avatar
      rel_eng: Add check to make sure that release jobs are downloaded by fetch-gitlab · f26d27ec
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      This check makes sure that if a job is a prefixed by "release-" then the
      script downloads it and understands how to map the job name to the
      platform.
      f26d27ec
    • Matthew Pickering's avatar
      ci: Remove FreeBSD job from release pipelines · de963cb6
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      We no longer attempt to build or distribute this release
      de963cb6
    • Simon Peyton Jones's avatar
      Take account of loop breakers in specLookupRule · d0f34f25
      Simon Peyton Jones authored and Marge Bot's avatar Marge Bot committed
      The key change is that in GHC.Core.Opt.Specialise.specLookupRule
      we were using realIdUnfolding, which ignores the loop-breaker
      flag.  When given a loop breaker, rule matching therefore
      looped infinitely -- #22802.
      
      In fixing this I refactored a bit.
      
      * Define GHC.Core.InScopeEnv as a data type, and use it.
        (Previously it was a pair: hard to grep for.)
      
      * Put several functions returning an IdUnfoldingFun into
        GHC.Types.Id, namely
           idUnfolding
           alwaysActiveUnfoldingFun,
           whenActiveUnfoldingFun,
           noUnfoldingFun
        and use them.  (The are all loop-breaker aware.)
      d0f34f25
    • Ryan Scott's avatar
      Fix two bugs in TypeData TH reification · 2f145052
      Ryan Scott authored and Marge Bot's avatar Marge Bot committed
      This patch fixes two issues in the way that `type data` declarations were
      reified with Template Haskell:
      
      * `type data` data constructors are now properly reified using `DataConI`.
        This is accomplished with a special case in `reifyTyCon`. Fixes #22818.
      
      * `type data` type constructors are now reified in `reifyTyCon` using
        `TypeDataD` instead of `DataD`. Fixes #22819.
      2f145052
    • Ryan Scott's avatar
      Handle `type data` properly in tyThingParent_maybe · 20598ef6
      Ryan Scott authored and Marge Bot's avatar Marge Bot committed
      Unlike most other data constructors, data constructors declared with `type data`
      are represented in `TyThing`s as `ATyCon` rather than `ADataCon`. The `ATyCon`
      case in `tyThingParent_maybe` previously did not consider the possibility of
      the underlying `TyCon` being a promoted data constructor, which led to the
      oddities observed in #22817. This patch adds a dedicated special case in
      `tyThingParent_maybe`'s `ATyCon` case for `type data` data constructors to fix
      these oddities.
      
      Fixes #22817.
      20598ef6
    • Andreas Klebinger's avatar
      ghc-the-library: Retain cafs in both static in dynamic builds. · 08ba8720
      Andreas Klebinger authored and Marge Bot's avatar Marge Bot committed
      We use keepCAFsForGHCi.c to force -fkeep-cafs behaviour by using a
      __attribute__((constructor)) function.
      
      This broke for static builds where the linker discarded the object file
      since it was not reverenced from any exported code. We fix this by
      asserting that the flag is enabled using a function in the same module
      as the constructor. Which causes the object file to be retained by the
      linker, which in turn causes the constructor the be run in static builds.
      
      This changes nothing for dynamic builds using the ghc library. But causes
      static to also retain CAFs (as we expect them to).
      
      Fixes #22417.
      
      -------------------------
      Metric Decrease:
          T21839r
      -------------------------
      08ba8720
  2. Jan 30, 2023
    • Cheng Shao's avatar
      compiler: fix data section alignment in the wasm NCG · da468391
      Cheng Shao authored and Marge Bot's avatar Marge Bot committed
      Previously we tried to lower the alignment requirement as far as
      possible, based on the section kind inferred from the CLabel. For info
      tables, .p2align 1 was applied given the GC should only need the
      lowest bit to tag forwarding pointers. But this would lead to
      unaligned loads/stores, which has a performance penalty even if the
      wasm spec permits it. Furthermore, the test suite has shown memory
      corruption in a few cases when compacting gc is used.
      
      This patch takes a more conservative approach: all data sections
      except C strings align to word size.
      da468391
    • Ben Gamari's avatar
      nativeGen: Disable asm-shortcutting on Darwin · 8bed166b
      Ben Gamari authored and Marge Bot's avatar Marge Bot committed
      Asm-shortcutting may produce relative references to symbols defined in
      other compilation units. This is not something that MachO relocations
      support (see #21972). For this reason we disable the optimisation on
      Darwin. We do so without a warning since this flag is enabled by `-O2`.
      
      Another way to address this issue would be to rather implement a
      PLT-relocatable jump-table strategy. However, this would only benefit
      Darwin and does not seem worth the effort.
      
      Closes #21972.
      8bed166b
  3. Jan 28, 2023
Loading