Skip to content
Snippets Groups Projects
  1. Sep 24, 2016
  2. Sep 23, 2016
    • Matthew Pickering's avatar
      Mark mapUnionFV as INLINABLE rather than INLINE · d1229353
      Matthew Pickering authored
      It is a self-recursive function so will always be the loop-breaker
      and hence never able to be inlined. It is dubious whether the INLINABLE
      pragma will ever help as it is not a very polymorphic function
      but some specialisation could occur.
      d1229353
    • Richard Eisenberg's avatar
      Fix #12442. · 9766b0c8
      Richard Eisenberg authored
      The problem is described in the ticket.
      
      This patch adds new variants of the access points to the pure
      unifier that allow unification of types only when the caller
      wants this behavior. (The unifier used to also unify kinds.)
      This behavior is appropriate when the kinds are either already
      known to be the same, or the list of types provided are a
      list of well-typed arguments to some type constructor. In the
      latter case, unifying earlier types in the list will unify the
      kinds of any later (dependent) types.
      
      At use sites, I went through and chose the unification function
      according to the criteria above.
      
      This patch includes some modest performance improvements as we
      are now doing less work.
      9766b0c8
    • Simon Marlow's avatar
      Improved documentation for Foreign.Concurrent (#12547) · 3a17916b
      Simon Marlow authored
      We had better docs for the underlying functions in GHC.ForeignPtr, but
      this wasn't propagated to the re-exported versions in
      Foreign.Concurrent.
      3a17916b
    • Simon Marlow's avatar
      Expose hs_exit_(rtsFalse) as hs_exit_nowait() · 74c4ca02
      Simon Marlow authored
      Summary: And document it.  See the docmentation for the reason I want this.
      
      Test Plan: It's an existing API, just exposing it.
      
      Reviewers: bgamari, niteria, austin, erikd
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D2531
      74c4ca02
    • Simon Marlow's avatar
      shutdownHaskellAndExit: just do a normal hs_exit() (#5402) · 9cbcdb48
      Simon Marlow authored
      If we want to keep the RTS alive a bit longer by having another
      hs_init()/hs_exit() pair in a library that will destruct itself after
      main() has exited, then the forced shutdown here thwarts that.
      
      I think we just "fixed" #5402 in the wrong way before, this should be
      better.
      9cbcdb48
  3. Sep 21, 2016
    • Tamar Christina's avatar
      Fix failing test T12504 · 8bd3d417
      Tamar Christina authored
      Summary:
      Test T12504 does it's checking in the Makefile using grep but still specified an stdout.
      the stdout has the old output and would always fail.
      
      Since the stdout isn't needed, let's not check it.
      
      Test Plan: make test TEST=T12504
      
      Reviewers: bgamari, austin, erikd, rcook
      
      Reviewed By: rcook
      
      Subscribers: thomie, #ghc_windows_task_force
      
      Differential Revision: https://phabricator.haskell.org/D2537
      
      GHC Trac Issues: #12504
      8bd3d417
  4. Sep 20, 2016
  5. Sep 16, 2016
    • Ben Gamari's avatar
      Remove directories from include paths · ea310f99
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      Previously this was a relative path which worked in the GHC tree, but
      failed elsewhere. This caused trouble for out-of-tree users as well as
      Hadrian, which wants to move build artifacts out of the working
      directory. Fixes #8040.
      
      Test Plan: Validate
      
      Reviewers: thomie, austin, snowleopard, hvr
      
      Reviewed By: snowleopard, hvr
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D2530
      
      GHC Trac Issues: #8040
      ea310f99
  6. Sep 15, 2016
  7. Sep 13, 2016
  8. Sep 12, 2016
    • Simon Peyton Jones's avatar
      Testsuite wibbles, to the same files · ec3edd56
      Simon Peyton Jones authored
      Sigh.  I added some comments to the source files,
      and failed to revalidate.  But the comments change the
      line number in the error messages.  Doh.
      ec3edd56
    • Simon Peyton Jones's avatar
      Test wibbles for commit 03541cba · 5eeabe25
      Simon Peyton Jones authored
      I must have failed to validate properly, sorry.
      These testsuite wibbles belong with
      
        commit 03541cba
        Author: Simon Peyton Jones <simonpj@microsoft.com>
        Date:   Fri Sep 9 17:42:42 2016 +0100
      
            Be less picky about reporing inaccessible code
      5eeabe25
    • Ben Gamari's avatar
      rts: Disable -hb with multiple capabilities · 6555c6bb
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      Biographical profiling is not thread-safe as documented in #12019. Throw
      an error when it is used in this way.
      
      Test Plan: Validate
      
      Reviewers: simonmar, austin, erikd
      
      Reviewed By: erikd
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D2516
      
      GHC Trac Issues: #12019
      6555c6bb
    • Ben Gamari's avatar
      users_guide: TH now partially supports typed holes · c6ac1e5f
      Ben Gamari authored
      As requested in #10267. However we still lack support in typed splices.
      See #10945 and #10946.
      c6ac1e5f
    • Ben Gamari's avatar
      users_guide: #8761 is now fixed · b451feff
      Ben Gamari authored
      Remove a leftover note in the users guide claiming that TH doesn't
      support pattern synonyms.
      b451feff
    • Ben Gamari's avatar
      users_guide: Fix Docbook remnant · 35086d4d
      Ben Gamari authored
      Not sure how this snuck through but it seems to be the only one.
      35086d4d
    • Simon Peyton Jones's avatar
      Remove unused exports · 21d0bfe1
      Simon Peyton Jones authored
      21d0bfe1
    • Simon Peyton Jones's avatar
      Be less picky about reporing inaccessible code · 03541cba
      Simon Peyton Jones authored
      Triggered by the discussion on Trac #12466, this patch
      makes GHC less aggressive about reporting an error when
      there are insoluble Givens.
      
      Being so agressive was making some libraries fail to
      compile, and is arguably wrong in at least some cases.
      See the discussion on the ticket.
      
      Several test now pass when they failed before; see
      the files-modified list for this patch.
      03541cba
    • Simon Marlow's avatar
      Add hs_try_putmvar() · 454033b5
      Simon Marlow authored
      Summary:
      This is a fast, non-blocking, asynchronous, interface to tryPutMVar that
      can be called from C/C++.
      
      It's useful for callback-based C/C++ APIs: the idea is that the callback
      invokes hs_try_putmvar(), and the Haskell code waits for the callback to
      run by blocking in takeMVar.
      
      The callback doesn't block - this is often a requirement of
      callback-based APIs.  The callback wakes up the Haskell thread with
      minimal overhead and no unnecessary context-switches.
      
      There are a couple of benchmarks in
      testsuite/tests/concurrent/should_run.  Some example results comparing
      hs_try_putmvar() with using a standard foreign export:
      
          ./hs_try_putmvar003 1 64 16 100 +RTS -s -N4     0.49s
          ./hs_try_putmvar003 2 64 16 100 +RTS -s -N4     2.30s
      
      hs_try_putmvar() is 4x faster for this workload (see the source for
      hs_try_putmvar003.hs for details of the workload).
      
      An alternative solution is to use the IO Manager for this.  We've tried
      it, but there are problems with that approach:
      * Need to create a new file descriptor for each callback
      * The IO Manger thread(s) become a bottleneck
      * More potential for things to go wrong, e.g. throwing an exception in
        an IO Manager callback kills the IO Manager thread.
      
      Test Plan: validate; new unit tests
      
      Reviewers: niteria, erikd, ezyang, bgamari, austin, hvr
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D2501
      454033b5
  9. Sep 11, 2016
  10. Sep 10, 2016
    • Tamar Christina's avatar
      Add platform warning to Foreign.C.Types · 710f21cc
      Tamar Christina authored
      Summary:
      The generated documentation for thhe Foreign.C.Types
      module is generated based on the platform which ran Haddock.
      
      This is generating incorrect types for e.g. Windows.
      
      Add a disclaimer to the top of the page to ask people to
      keep this in mind.
      
      Test Plan: make documentation and inspect Haddock
      
      Reviewers: erikd, austin, hvr, bgamari
      
      Reviewed By: erikd
      
      Subscribers: RyanGlScott, #ghc_windows_task_force, thomie
      
      Differential Revision: https://phabricator.haskell.org/D2523
      
      GHC Trac Issues: #12586
      710f21cc
    • Ryan Scott's avatar
      Remove -flocal-ghci-history from default flags · 7b4bb405
      Ryan Scott authored
      Summary:
      D2461 seemed to (inadvertently, I think) add the
      `-flocal-ghci-history` flag to the list of `defaultFlags` that are enabled
      automatically. As a result, every invocation of `ghci` caused a local GHCi
      history to be saved to the current directory, which probably shouldn't be the
      default.
      
      Test Plan:
      Run `ghci`, observe the lack of a `.ghci_history` file in your
      working directory
      
      Reviewers: austin, thomie, bgamari
      
      Reviewed By: bgamari
      
      Subscribers: ak3n
      
      Differential Revision: https://phabricator.haskell.org/D2520
      
      GHC Trac Issues: #9089
      7b4bb405
  11. Sep 09, 2016
    • bitonic's avatar
      Make start address of `osReserveHeapMemory` tunable via command line -xb · 1b5f9207
      bitonic authored and Tamar Christina's avatar Tamar Christina committed
      Summary:
      We stumbled upon a case where an external library (OpenCL) does not work
      if a specific address (0x200000000) is taken.
      
      It so happens that `osReserveHeapMemory` starts trying to mmap at 0x200000000:
      
      ```
              void *hint = (void*)((W_)8 * (1 << 30) + attempt * BLOCK_SIZE);
              at = osTryReserveHeapMemory(*len, hint);
      ```
      
      This makes it impossible to use Haskell programs compiled with GHC 8
      with C functions that use OpenCL.
      
      See this example ​https://github.com/chpatrick/oclwtf for a repro.
      
      This patch allows the user to work around this kind of behavior outside
      our control by letting the user override the starting address through an
      RTS command line flag.
      
      Reviewers: bgamari, Phyx, simonmar, erikd, austin
      
      Reviewed By: Phyx, simonmar
      
      Subscribers: rwbarton, thomie
      
      Differential Revision: https://phabricator.haskell.org/D2513
      1b5f9207
    • Alan Zimmerman's avatar
      Add hook for creating ghci external interpreter · 65d9597d
      Alan Zimmerman authored
      Summary:
      The external interpreter is launched by calling
      'System.Process.createProcess' with a 'CreateProcess' parameter.
      
      The current value for this has the 'std_in', 'std_out' and 'std_err'
      fields use the default of 'Inherit', meaning that the remote interpreter
      shares the stdio with the original ghc/ghci process.
      
      This patch introduces a new hook to the DynFlags, which has an
      opportunity to override the 'CreateProcess' fields, launch the process,
      and retrieve the stdio handles actually used.
      
      So if a ghci external interpreter session is launched from the GHC API
      the stdio can be redirected if required, which is useful for tooling/IDE
      integration.
      
      Test Plan: ./validate
      
      Reviewers: austin, hvr, simonmar, bgamari
      
      Reviewed By: simonmar, bgamari
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D2518
      65d9597d
  12. Sep 08, 2016
Loading