Skip to content
Snippets Groups Projects
  1. Mar 04, 2019
  2. Mar 02, 2019
  3. Feb 20, 2019
    • Herbert Valerio Riedel's avatar
      Fix regression incorrectly advertising TH support · bdc9680c
      Herbert Valerio Riedel authored and Ben Gamari's avatar Ben Gamari committed
      `--supported-languages` must only advertise language extensions
      which are supported by the compiler in order for tooling such
      as Cabal relying on this signalling not to behave incorrectly.
      
      Fixes #16331
      
      (cherry picked from commit db4372cda7f6c87e7ad26efe3fca4b3f7f527a48)
      bdc9680c
    • Ömer Sinan Ağacan's avatar
      Fix two bugs in stg_ap_0_fast in profiling runtime · a481b199
      Ömer Sinan Ağacan authored
      This includes two bug fixes in profiling version of stg_ap_0_fast:
      
      - PAPs allocated by stg_ap_0_fast are now correctly tagged. This
        invariant is checked in Sanity.c:checkPAP.
      
        (This was originally implemented in 2693eb11, later reverted with
        ab55b4dd because it revealed the bug below, but it wasn't clear at
        the time whether the bug was the one below or something in the commit)
      
      - The local variable `untaggedfun` is now marked as a pointer so it
        survives GC.
      
      With this we finally fix all known bugs caught in #15508. `concprog001`
      now works reliably with prof+threaded and prof runtimes (with and
      without -debug).
      
      (cherry picked from commit 908b4b86)
      a481b199
  4. Feb 12, 2019
  5. Feb 11, 2019
    • Tamar Christina's avatar
      Stack: fix name mangling. · 0f253b89
      Tamar Christina authored and Ben Gamari's avatar Ben Gamari committed
      (cherry picked from commit fb031b9b)
      0f253b89
    • Ben Gamari's avatar
      GhcPlugins: Fix lookup of TH names · 5abfd982
      Ben Gamari authored
      Previously `thNameToGhcName` was calling `lookupOrigNameCache` directly, which
      failed to handle the case that the name wasn't already in the name cache. This
      happens, for instance, when the name was in scope in a plugin being used during
      compilation but not in scope in the module being compiled. In this case we the
      interface file containing the name won't be loaded and `lookupOrigNameCache`
      fails. This was the cause of #16104.
      
      The solution is simple: use the nicely packaged `lookupOrigIO` instead.
      
      (cherry picked from commit 0d9f105b)
      5abfd982
    • Ben Gamari's avatar
      testsuite: Add test for #16104 · 8c2dbc16
      Ben Gamari authored
      8c2dbc16
  6. Feb 09, 2019
  7. Feb 03, 2019
  8. Jan 28, 2019
    • Ömer Sinan Ağacan's avatar
      Fix checkPtrInArena · 14001294
      Ömer Sinan Ağacan authored
      (See comments)
      
      (cherry picked from commit 448f0e7d)
      14001294
    • Ömer Sinan Ağacan's avatar
      Fix raiseAsync() UNDERFLOW_FRAME handling in profiling runtime · cf5b5a74
      Ömer Sinan Ağacan authored
      UNDERFLOW_FRAMEs don't have profiling headers so we have to use the
      AP_STACK's function's CCS as the new frame's CCS.
      
      Fixes one of the many bugs caught by concprog001 (#15508).
      
      (cherry picked from commit 74cd4ec5)
      cf5b5a74
    • Ömer Sinan Ağacan's avatar
      Implement a sanity check for CCS fields in profiling builds · 4f712fb3
      Ömer Sinan Ağacan authored
      This helped me debug one of the bugs in #15508. I'm not sure if this is
      a good idea, but it worked for me, so wanted to submit this as a MR.
      
      (cherry picked from commit 82d1a88d)
      4f712fb3
    • Ömer Sinan Ağacan's avatar
      Fix a MSG_BLACKHOLE sanity check, add some comments · ee6e4fcc
      Ömer Sinan Ağacan authored
      Reviewers: simonmar, bgamari, erikd
      
      Reviewed By: simonmar
      
      Subscribers: rwbarton, carter
      
      GHC Trac Issues: #15508
      
      Differential Revision: https://phabricator.haskell.org/D5178
      
      (cherry picked from commit d90946ce)
      ee6e4fcc
    • Ben Gamari's avatar
      rts: Use always-available locking operations in pthread Itimer implementation · 4f180640
      Ben Gamari authored
      Previously we ACQUIRE_LOCK and RELEASE_LOCK but these compile to a noop in the
      non-threaded RTS, as noted in #16150. Use OS_ACQUIRE_LOCK and OS_RELEASE_LOCK
      instead.
      
      (cherry picked from commit ce11f6f2)
      4f180640
    • Ben Gamari's avatar
      itimer: Don't free condvar until we know ticker is stopped · 7ec385f4
      Ben Gamari authored
      When we are shutting down the pthread ticker we signal the start_cond condition
      variable to ensure that the ticker thread wakes up and exits in a reasonable
      amount of time. Previously, when the ticker thread would shut down it was
      responsible for freeing the start_cond condition variable. However, this would
      lead to a race wherein the ticker would free start_cond, then the main thread
      would try to signal it in an effort to wake the ticker (#16150).
      
      Avoid this by moving the mutex destruction to the main thread.
      
      (cherry picked from commit 7b12b3f0)
      7ec385f4
    • Simon Peyton Jones's avatar
      Fix bogus worker for newtypes · ff47e60a
      Simon Peyton Jones authored
      The "worker" for a newtype is actually a function
      with a small (compulsory) unfolding, namely a cast.
      
      But the construction of this function was plain wrong
      for newtype /instances/; it cast the arguemnt to the
      family type rather than the representation type.
      
      This never actually bit us because, in the case of a
      family instance, we immediately cast the result to
      the family type.  So we get
         \x. (x |> co1) |> co2
      
      where the compositio of co1 and co2 is ill-kinded.
      However the optimiser (even the simple optimiser)
      just collapsed those casts, ignoring the mis-match
      in the middle, so we never saw the problem.
      
      Trac #16191 is indeed a dup of #16141; but the resaon
      these tickets produce Lint errors is not the unnecessary
      forcing; it's because of the ill-typed casts.
      
      This patch fixes the ill-typed casts, properly.  I can't
      see a way to trigger an actual failure prior to this
      patch, but it's still wrong wrong wrong to have ill-typed
      casts, so better to get rid of them.
      
      (cherry picked from commit a5373c1f)
      ff47e60a
  9. Jan 17, 2019
  10. Jan 16, 2019
  11. Jan 11, 2019
  12. Jan 07, 2019
    • Simon Marlow's avatar
      Fix recompilation bug with default class methods (#15970) · 08cfa615
      Simon Marlow authored and Ben Gamari's avatar Ben Gamari committed
      If a module uses a class, then it can instantiate the class and
      thereby use its default methods, so we must include the default
      methods when calculating the fingerprint for the class.
      
      Test Plan:
      New unit test: driver/T15970
      
      Before:
      
      ```
      =====> T15970(normal) 1 of 1 [0, 0, 0]
      cd "T15970.run" && $MAKE -s --no-print-directory T15970
      Wrong exit code for T15970()(expected 0 , actual 2 )
      Stdout ( T15970 ):
      Makefile:13: recipe for target 'T15970' failed
      Stderr ( T15970 ):
      C.o:function Main_zdfTypeClassMyDataType1_info: error: undefined
      reference to 'A_toTypedData2_closure'
      C.o:function Main_main1_info: error: undefined reference to
      'A_toTypedData2_closure'
      C.o(.data+0x298): error: undefined reference to 'A_toTypedData2_closure'
      C.o(.data+0x480): error: undefined reference to 'A_toTypedData2_closure'
      collect2: error: ld returned 1 exit status
      `gcc' failed in phase `Linker'. (Exit code: 1)
      ```
      
      After: test passes.
      
      Reviewers: bgamari, simonpj, erikd, watashi, afarmer
      
      Subscribers: rwbarton, carter
      
      GHC Trac Issues: #15970
      
      Differential Revision: https://phabricator.haskell.org/D5394
      
      (cherry picked from commit 288f681e)
      08cfa615
  13. Dec 30, 2018
  14. Dec 29, 2018
  15. Dec 27, 2018
  16. Dec 24, 2018
  17. Dec 15, 2018
  18. Dec 06, 2018
    • Ben Gamari's avatar
      Release 8.6.3 · 31cd867e
      Ben Gamari authored
    • Ben Gamari's avatar
      users guide: Add release notes for 8.6.3 · d59812ce
      Ben Gamari authored
      d59812ce
    • Ben Gamari's avatar
      Windows: Use the "big" PE object format on amd64 · ed86e3b5
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      Test Plan: Do full build on Windows.
      
      Reviewers: AndreasK, Phyx
      
      Reviewed By: AndreasK
      
      Subscribers: rwbarton, erikd, carter
      
      GHC Trac Issues: #15934
      
      Differential Revision: https://phabricator.haskell.org/D5383
      
      (cherry picked from commit 1ef90f99)
      ed86e3b5
    • Tamar Christina's avatar
      linker: store entire link map and use it. · c64918c1
      Tamar Christina authored and Ben Gamari's avatar Ben Gamari committed
      Summary:
      This fixes a corner case in which we have seen the symbol multiple times in
      different static libraries, but due to a depencency we end up loading the
      symbol from a library other than the first one.
      
      Previously the runtime linker would only track symbols from the first
      library and did not store the full link map.  In this case it was unable
      to find the address for the symbols in the second library during delay
      loading.
      
      This change stores the address of all symbols seen so a full link map
      is generated, such that when we make a different decision later than what
      was expected we're able to still correctly load the library.
      
      Test Plan: ./validate, new testcase T15894
      
      Reviewers: angerman, bgamari, erikd, simonmar
      
      Reviewed By: bgamari
      
      Subscribers: rwbarton, carter
      
      GHC Trac Issues: #15894
      
      Differential Revision: https://phabricator.haskell.org/D5353
      
      (cherry picked from commit a8b7cef4)
      c64918c1
    • Ben Gamari's avatar
      Bump iserv versions · bf074e3e
      Ben Gamari authored
      This fixes #15866, the original fix for which didn't merge cleanly to
      the stable branch.
      bf074e3e
    • Alexander Vershilov's avatar
      Remove explicit recursion in retainer profiling (fixes #14758) · 6db7d11e
      Alexander Vershilov authored and Ben Gamari's avatar Ben Gamari committed
      Retainer profiling contained a recursion that under
      certain circumstances could lead to the stack overflow
      in C code.
      
      The idea of the improvement is to keep an explicit stack for the
      object, more precise to reuse existing stack, but allow new type of
      objects to be stored there.
      
      There is no reliable reproducer that is not a big program
      but in some cases foldr (+) 0 [1..10000000] can work.
      
      Reviewers: bgamari, simonmar, erikd, osa1
      
      Reviewed By: bgamari, osa1
      
      Subscribers: osa1, rwbarton, carter
      
      GHC Trac Issues: #14758
      
      Differential Revision: https://phabricator.haskell.org/D5351
      
      (cherry picked from commit 5f1d949a)
      6db7d11e
  19. Nov 22, 2018
Loading