ghc.git
4 years agoRevert "Add --verbose and --help flags to gen_contents_index" ghc-7.4
Ben Gamari [Mon, 6 Jul 2015 09:15:58 +0000 (11:15 +0200)] 
Revert "Add --verbose and --help flags to gen_contents_index"

This reverts commit e1e68550026b83ba15158fa776f406844cccedd1 which was
accidentally pushed.

6 years ago-package P was loading all versions of P in GHCi (#7030)
Simon Marlow [Mon, 2 Jul 2012 14:04:05 +0000 (15:04 +0100)] 
-package P was loading all versions of P in GHCi (#7030)

-package P means "the latest version of P" if multiple versions are
installed.  It was working as advertised, but we were
eagerly *linking* all versions of P, which might cause an error if the
package has some C code, because we can't link multiple instances of
the same symbol.

MERGED from commit 62164cf56bd91ddd9449d345f8d710fbbdbf4827

7 years agoAdd --verbose and --help flags to gen_contents_index
Thomas Dziedzic [Thu, 21 Jun 2012 02:22:44 +0000 (21:22 -0500)] 
Add --verbose and --help flags to gen_contents_index

Fixes http://hackage.haskell.org/trac/ghc/ticket/5992

7 years agoDon't put auto sccs on INLINE functions (#6131)
Simon Marlow [Fri, 15 Jun 2012 09:30:35 +0000 (10:30 +0100)] 
Don't put auto sccs on INLINE functions (#6131)

There was also a bug caused by INLINEs getting SCCs, but unfortunately
I have lost the test case.  The Note in the code describes the problem
though.

MERGED from commit 6181e007f0e1e8eddba7acf0d5fbcbaf46806249

7 years agoBuild fix for Hurd.
Paolo Capriotti [Sun, 17 Jun 2012 15:28:36 +0000 (16:28 +0100)] 
Build fix for Hurd.

Patch by Samuel Thibault.

See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=659530.

MERGED from commit d2b538c80c00a99a51e4892dec475eae38cf9888

7 years agoDrop the per-task timing stats, give a summary only (#5897)
Simon Marlow [Fri, 2 Mar 2012 10:53:34 +0000 (10:53 +0000)] 
Drop the per-task timing stats, give a summary only (#5897)

We were keeping around the Task struct (216 bytes) for every worker we
ever created, even though we only keep a maximum of 6 workers per
Capability.  These Task structs accumulate and cause a space leak in
programs that do lots of safe FFI calls; this patch frees the Task
struct as soon as a worker exits.

One reason we were keeping the Task structs around is because we print
out per-Task timing stats in +RTS -s, but that isn't terribly useful.
What is sometimes useful is knowing how *many* Tasks there were.  So
now I'm printing a single-line summary, this is for the program in

  TASKS: 2001 (1 bound, 31 peak workers (2000 total), using -N1)

So although we created 2k tasks overall, there were only 31 workers
active at any one time (which is exactly what we expect: the program
makes 30 safe FFI calls concurrently).

This also gives an indication of how many capabilities were being
used, which is handy if you use +RTS -N without an explicit number.

MERGED from commit 085c7fe5d4ea6e7b59f944d46ecfeba3755a315b

7 years agoFix ref to ticket in 7.4.2 release notes.
Paolo Capriotti [Mon, 11 Jun 2012 08:31:28 +0000 (09:31 +0100)] 
Fix ref to ticket in 7.4.2 release notes.

7 years agothrowTo: unlock the MSG_THROWTO object before returning (#6103)
Simon Marlow [Tue, 5 Jun 2012 08:05:47 +0000 (09:05 +0100)] 
throwTo: unlock the MSG_THROWTO object before returning (#6103)

MERGED from commit 20ba7f1a7a7b05acd81124f1567a3a103bcd0d1b

7 years agoFix for earger blackholing of thunks with no free variables (#6146)
Simon Marlow [Thu, 7 Jun 2012 14:45:32 +0000 (15:45 +0100)] 
Fix for earger blackholing of thunks with no free variables (#6146)

A thunk with no free variables was not getting blackholed when
-feager-blackholing was on, but we were nevertheless pushing the
stg_bh_upd_frame version of the update frame that expects to see a
black hole.

I fixed this twice for good measure:

 - we now call blackHoleOnEntry when pushing the update frame to check
   whether the closure was actually blackholed, and so that we use the
   same predicate in both places

 - we now black hole thunks even if they have no free variables.
   These only occur when optimisation is off, but presumably if you say
   -feager-blackholing then that's what you want to happen.

MERGED from commit 21a53a1cd5a9784aca7b78cc972f917e71938124

7 years agoSet RELEASE back to NO
Ian Lynagh [Thu, 7 Jun 2012 14:08:00 +0000 (15:08 +0100)] 
Set RELEASE back to NO

7 years agoRead the source file timestamp *before* preprocessing (#6106) ghc-7.4.2-release
Simon Marlow [Tue, 22 May 2012 10:51:46 +0000 (11:51 +0100)] 
Read the source file timestamp *before* preprocessing (#6106)

MERGED from commit d82da293078b00d0f2d85c947e70382d398aab64

7 years agocheckStability: respect -fforce-recomp (#6105)
Simon Marlow [Tue, 22 May 2012 11:30:36 +0000 (12:30 +0100)] 
checkStability: respect -fforce-recomp (#6105)

MERGED from commit c95342cef63fad2edfaf3868de11ff7781b440c8

7 years agoTabs -> Spaces in GhcMake.hs.
Paolo Capriotti [Tue, 5 Jun 2012 12:11:38 +0000 (13:11 +0100)] 
Tabs -> Spaces in GhcMake.hs.

7 years agoescape(): don't forget the final '\0'
Simon Marlow [Wed, 23 May 2012 11:30:38 +0000 (06:30 -0500)] 
escape(): don't forget the final '\0'

Hopefully should fix random "bad heap profile" failures in the nightly
builds.

MERGED from commit 634fb8d3b569276504be317783ade54508633b10

7 years agoSet RELEASE to YES, and version to 7.4.2
Ian Lynagh [Fri, 1 Jun 2012 13:51:27 +0000 (14:51 +0100)] 
Set RELEASE to YES, and version to 7.4.2

7 years agoUpdate ANNOUNCE for 7.4.1
Ian Lynagh [Fri, 1 Jun 2012 13:31:48 +0000 (14:31 +0100)] 
Update ANNOUNCE for 7.4.1

7 years agoMERGE: Be less aggressive about the result discount
Ian Lynagh [Wed, 30 May 2012 09:43:07 +0000 (10:43 +0100)] 
MERGE: Be less aggressive about the result discount

Merge of:
    commit 4fa3f16ddb9fa8e5d59bde5354918a39e0430a74
    Author: Simon Peyton Jones <simonpj@microsoft.com>
    Date:   Mon May 28 17:33:42 2012 +0100

Be less aggressive about the result discount

This patch fixes Trac #6099 by reducing the result discount in CoreUnfold.conSize.
See Note [Constructor size and result discount] in CoreUnfold.

The existing version is definitely too aggressive. Simon M found it an
"unambiguous win" but it is definitely what led to the bloat. In a function
with a lot of case branches, all returning a constructor, the discount could
grow arbitrarily large.

I also had to increase the -funfolding-creation-threshold from 450 to 750,
otherwise some functions that should inline simply never get an unfolding.
(The massive result discount was allow the unfolding to appear before.)

The nofib results are these, picking a handful of outliers to show.

        Program           Size    Allocs   Runtime   Elapsed  TotalMem
--------------------------------------------------------------------------------
         fulsom          -0.5%     -1.6%     -2.8%     -2.6%    +31.1%
       maillist          -0.2%     -0.0%      0.09      0.09     -3.7%
         mandel          -0.4%     +6.6%      0.12      0.12     +0.0%
       nucleic2          -0.2%    +18.5%      0.11      0.11     +0.0%
        parstof          -0.4%     +4.0%      0.00      0.00     +0.0%
--------------------------------------------------------------------------------
            Min          -0.9%     -1.6%    -19.7%    -19.7%     -3.7%
            Max          +0.3%    +18.5%     +2.7%     +2.7%    +31.1%
 Geometric Mean          -0.3%     +0.4%     -3.0%     -3.0%     +0.2%

Turns out that nucleic2 has a function
  Main.$wabsolute_pos =
    \ (ww_s4oj :: Types.Tfo) (ww1_s4oo :: Types.FloatT)
      (ww2_s4op :: Types.FloatT) (ww3_s4oq :: Types.FloatT) ->
      case ww_s4oj
      of _
      { Types.Tfo a_a1sS b_a1sT c_a1sU d_a1sV e_a1sW f_a1sX g_a1sY h_a1sZ i_a1t0 tx_a1t1 ty_a1t2 tz_a1t3 ->
      (# case ww1_s4oo of _ { GHC.Types.F# x_a2sO ->
         case a_a1sS of _ { GHC.Types.F# y_a2sS ->
         case ww2_s4op of _ { GHC.Types.F# x1_X2y9 ->
         case d_a1sV of _ { GHC.Types.F# y1_X2yh ->
         case ww3_s4oq of _ { GHC.Types.F# x2_X2yj ->
         case g_a1sY of _ { GHC.Types.F# y2_X2yr ->
         case tx_a1t1 of _ { GHC.Types.F# y3_X2yn ->
         GHC.Types.F#
           (GHC.Prim.plusFloat#
              (GHC.Prim.plusFloat#
                 (GHC.Prim.plusFloat#
                    (GHC.Prim.timesFloat# x_a2sO y_a2sS)
                    (GHC.Prim.timesFloat# x1_X2y9 y1_X2yh))
                 (GHC.Prim.timesFloat# x2_X2yj y2_X2yr))
              y3_X2yn)
         } } }}}}},

        <similar>,
        <similar> )

This is pretty big, but inlining it does get rid of that F# allocation.
But we'll also get rid of it with deep CPR: Trac #2289. For now we just
accept the change.

7 years agoFix typo in 7.4.2 release notes.
Paolo Capriotti [Wed, 16 May 2012 11:52:19 +0000 (12:52 +0100)] 
Fix typo in 7.4.2 release notes.

7 years agoUpdate 7.4.2 release notes.
Paolo Capriotti [Wed, 16 May 2012 11:27:36 +0000 (12:27 +0100)] 
Update 7.4.2 release notes.

7 years agoBuild fix.
Paolo Capriotti [Tue, 8 May 2012 15:50:04 +0000 (16:50 +0100)] 
Build fix.

7 years agoCatch illegal imports earlier (#6007)
Simon Marlow [Fri, 27 Apr 2012 12:07:50 +0000 (13:07 +0100)] 
Catch illegal imports earlier (#6007)

MERGED from commit b6e28266cf29bfdf07fe08e894df77b400da8a04

7 years agohs_init(): cope with argc and/or argv being NULL (#6006)
Simon Marlow [Fri, 27 Apr 2012 12:20:56 +0000 (13:20 +0100)] 
hs_init(): cope with argc and/or argv being NULL (#6006)

MERGED from commit 4ca281829c70331571291ed3dcf813a6028cc904

7 years agoCast memory primops in the C backend (#5976)
Paolo Capriotti [Wed, 2 May 2012 14:24:46 +0000 (15:24 +0100)] 
Cast memory primops in the C backend (#5976)

To prevent conflicts with GCC builtins, generate identical code for
calls to mem primos and FFI calls.

Based on a patch by Joachim Breitner.
MERGED from commit 40c1106c338e209f07023d165f32bff0f75e2e54

7 years agoOmit -osuf/-odir -hisuf/-hidir and -stubdir from the flag checker
Simon Marlow [Tue, 28 Feb 2012 09:28:09 +0000 (09:28 +0000)] 
Omit -osuf/-odir -hisuf/-hidir and -stubdir from the flag checker

The reasoning is that GHC will only skip recompilation if it has found
a valid up-to-date object file and .hi file, so there is no need to
also check that these flags have not changed, and indeed there are
valid reasons to want to change them.

7 years agoCompile link .note section separately from main.c
Nathan Howell [Wed, 15 Feb 2012 19:41:09 +0000 (11:41 -0800)] 
Compile link .note section separately from main.c

Fixes gas errors when -g is enabled:

Error: can't resolve `.debug-ghc-link-info' {.debug-ghc-link-info section} - `.Ltext0' {.text section}

7 years agoDoc: updated list of warnings not enabled by -Wall (#4817)
Paolo Capriotti [Fri, 27 Apr 2012 08:46:06 +0000 (09:46 +0100)] 
Doc: updated list of warnings not enabled by -Wall (#4817)

MERGED from commit 18c2a2f71e38fad5e677b8f448f6135e5a691868

7 years agoFlags documentation: -fwarn-unrecognized-pragmas is enabled by -Wall (#6050)
Paolo Capriotti [Fri, 27 Apr 2012 08:40:40 +0000 (09:40 +0100)] 
Flags documentation: -fwarn-unrecognized-pragmas is enabled by -Wall (#6050)

MERGED from commit 44098b3dab032a83cc869855de67377f41d82384

7 years agoFix worker/wrapper for CPR functions
Simon Peyton Jones [Fri, 13 Apr 2012 16:38:32 +0000 (17:38 +0100)] 
Fix worker/wrapper for CPR functions

A long-standing and egregious bug in the worker/wrapper code meant
that some functions with the CPR property weren't getting a CPR
w/w. And that had the effect of making a tail-recursive function not
tail recursive.  As well as increasing allocation.

Fixes Trac #5920, and #5997.

Nofib results (highlights):

        Program           Size    Allocs   Runtime   Elapsed  TotalMem
--------------------------------------------------------------------------------
         boyer2          -0.1%    -15.3%      0.01      0.01     +0.0%
        mandel2          -0.0%     -8.1%      0.01      0.01     +0.0%
           para          -0.1%    -11.8%     -7.9%     -7.8%     +0.0%
--------------------------------------------------------------------------------
            Min          -0.1%    -15.3%     -7.9%     -7.8%    -33.3%
            Max          +0.0%     +0.2%     +6.3%     +6.3%     +3.7%
 Geometric Mean          -0.0%     -0.4%     +0.1%     +0.1%     -0.5%

Looks like a clear win.  And I have not even recompiled the libraries, so
it'll probably be a bit better in the ed.

MERGED from commit b8ff4448d899f783fc112f3774aab626979a4f22

7 years agoUpdate 7.4.2 release notes.
Paolo Capriotti [Mon, 16 Apr 2012 09:14:03 +0000 (10:14 +0100)] 
Update 7.4.2 release notes.

7 years agoFix crash with tiny initial stack size (#5993)
Simon Marlow [Thu, 12 Apr 2012 10:41:17 +0000 (11:41 +0100)] 
Fix crash with tiny initial stack size (#5993)

MERGED from commit 5eabdc1675b8b5bc9fcdfb96ab63d14d42ca2d5b

7 years agoFix a #define
Ian Lynagh [Sun, 15 Jan 2012 19:21:38 +0000 (19:21 +0000)] 
Fix a #define

I don't think it was causing any problems, but
    TimeToUS(x+y)
would have evaluated to
    x + (y / 1000)

MERGED from commit 54121fffb5ee069d9b7a5628104ff1114ea87182

On the 7.4 branch, this was causing a wrong conversion in
getDelayTarget.

Signed-off-by: Paolo Capriotti <p.capriotti@gmail.com>
7 years agoDisable the timer signal while blocked in select() (#5991)
Simon Marlow [Wed, 11 Apr 2012 09:12:14 +0000 (10:12 +0100)] 
Disable the timer signal while blocked in select() (#5991)

The threaded RTS had a fix for this a long time ago (#1623) but this
patch applies a similar fix to the non-threaded RTS.

MERGED from commit dd24d6bc37879c6b32a3d5ac4ee765e59e13501c

7 years agoImprove the handling of threadDelay in the non-threaded RTS
Simon Marlow [Wed, 11 Apr 2012 10:38:24 +0000 (11:38 +0100)] 
Improve the handling of threadDelay in the non-threaded RTS

Firstly, we were rounding up too much, such that the smallest delay
was 20ms.  Secondly, there is no need to use millisecond resolution on
a 64-bit machine where we have room in the TSO to use the normal
nanosecond resolution that we use elsewhere in the RTS.

MERGED from commit 9d26519c20194abc3832578a55fbe31327519eeb

7 years agoFix GHC API with respect to safe haskell. (#5989)
David Terei [Tue, 3 Apr 2012 02:00:51 +0000 (19:00 -0700)] 
Fix GHC API with respect to safe haskell. (#5989)

This fixes haddock so it correctly reports
the safe haskell mode of a module.

7 years agoUpdate safe haskell error/warn formatting
David Terei [Tue, 3 Apr 2012 19:37:30 +0000 (12:37 -0700)] 
Update safe haskell error/warn formatting

7 years agoFix tracking of reason safe inference failed. (#5988)
David Terei [Tue, 3 Apr 2012 01:58:43 +0000 (18:58 -0700)] 
Fix tracking of reason safe inference failed. (#5988)

7 years agoPrevent nested TH exceptions from bubbling up to the top level (#5976)
Paolo Capriotti [Fri, 30 Mar 2012 11:30:28 +0000 (12:30 +0100)] 
Prevent nested TH exceptions from bubbling up to the top level (#5976)

MERGED from commit e7e5e277eb58a5ef6207200174e7982fdb9780bb

7 years agoMake the LocalRdrEnv keep track of all the Names that are in scope
Simon Peyton Jones [Wed, 28 Mar 2012 08:57:57 +0000 (09:57 +0100)] 
Make the LocalRdrEnv keep track of all the Names that are in scope

This allows us to give a sensible error message when a Template Haskell
splice generates an occurrence without a binding site.

Fixes Trac #5959 and #5971

MERGED from commit cb5a3f2d66e4dac2f6f44f56e365d18df884c943

7 years agoRevert "Refer to Control.Concurrent instead of GHC.Conc"
Paolo Capriotti [Mon, 2 Apr 2012 13:15:48 +0000 (14:15 +0100)] 
Revert "Refer to Control.Concurrent instead of GHC.Conc"

This reverts commit 6a217ed6f10d440902eb166d2e0ab4127eb3f699.

7 years agoAdd release notes for 7.4.2.
Paolo Capriotti [Mon, 2 Apr 2012 08:47:46 +0000 (09:47 +0100)] 
Add release notes for 7.4.2.

7 years agoFix a bug in threadStackOverflow() (maybe #5214)
Simon Marlow [Wed, 28 Mar 2012 10:45:39 +0000 (11:45 +0100)] 
Fix a bug in threadStackOverflow() (maybe #5214)

If we overflow the current stack chunk and copy its entire contents
into the next stack chunk, we could end up with two UNDERFLOW_FRAMEs.
We had a special case to catch this in the case when the old stack
chunk was the last one (ending in STOP_FRAME), but it went wrong for
other chunks.

I found this bug while poking around in the core dump attached to
options and running the nofib suite: imaginary/wheel_sieve2 crashed
with +RTS -kc600 -kb300.

I don't know if this is the cause of all the symptoms reported in

MERGED from commit 734f1d484b12b785795b249b4116cfb4817ab55d

7 years agoRespect package qualifier when validating imports in GHCi (#5979)
Paolo Capriotti [Sat, 31 Mar 2012 14:48:57 +0000 (15:48 +0100)] 
Respect package qualifier when validating imports in GHCi (#5979)

MERGED from commit a39a19254003f593e49fa0b29c8a10444cc204c2

7 years agoUpdate documentation of DatatypeContexts (#5964)
Paolo Capriotti [Fri, 30 Mar 2012 14:46:30 +0000 (15:46 +0100)] 
Update documentation of DatatypeContexts (#5964)

MERGED from commit ac2fbb4f6ce7bf9f0742207e1b974bbd556af85a

7 years agoAdd linker support for ELF on ARM
Ben Gamari [Wed, 12 Oct 2011 04:49:12 +0000 (00:49 -0400)] 
Add linker support for ELF on ARM

Add support for ELF objects on ARM to the runtime linker. While the list of
relocation types in the "ELF for the ARM Architecture" specification spans four
pages, we thankfully only see a handful of these in the wild. Thus, at the
moment we only support the following .rel relocation types,

 * R_ARM_ABS32
 * R_ARM_TARGET1
 * R_ARM_REL32
 * R_ARM_CALL
 * R_ARM_JUMP24
 * R_ARM_MOVT_ABS
 * R_ARM_MOVW_ABS_NC
 * R_ARM_THM_CALL
 * R_ARM_THM_JUMP24
 * R_ARM_THM_MOVT_ABS
 * R_ARM_THM_MOVW_ABS_NC
 * R_ARM_THM_JUMP8
 * R_ARM_THM_JUMP11

Signed-off-by: Ben Gamari <bgamari.foss@gmail.com>
MERGED from commit b22501b408ddb0503a06a188b06d9cff9be697cd

7 years agoUpdate the user guide with details on new flag +RTS -lu
Duncan Coutts [Thu, 22 Mar 2012 23:24:57 +0000 (23:24 +0000)] 
Update the user guide with details on new flag +RTS -lu

It's for user events emitted from Haskell code, like traceEvent.
Fixes #5790

MERGED from commit 050f714150282695746534174c4550c90c2d9f4e

7 years agofix #5534 (ghci -fobject-code strangeness)
Simon Marlow [Wed, 15 Feb 2012 10:01:21 +0000 (10:01 +0000)] 
fix #5534 (ghci -fobject-code strangeness)

MERGED from commit 9fa9dd773fc10a89b05d1456cfe55b79c5bd608c

7 years agoImprove support for LLVM >= 3.0 write barrier. (#5814)
Paolo Capriotti [Mon, 26 Mar 2012 17:56:14 +0000 (18:56 +0100)] 
Improve support for LLVM >= 3.0 write barrier. (#5814)

MERGED from commit d2d5ee16cf21c5b32333ff57ba0a65f89ff7e988

7 years agollvmGen: Use new fence instruction
Ben Gamari [Wed, 25 Jan 2012 00:56:35 +0000 (19:56 -0500)] 
llvmGen: Use new fence instruction

Signed-off-by: David Terei <davidterei@gmail.com>
MERGED from commit 766da942097613fed56417e3e149997812f83105

7 years agoFix closure_type_names, BLACKHOLE and BLOCKING_QUEUE were swapped
Joachim Breitner [Mon, 12 Mar 2012 10:21:05 +0000 (11:21 +0100)] 
Fix closure_type_names, BLACKHOLE and BLOCKING_QUEUE were swapped

MERGED from commit 4bbe9f719f4c26e7f2d8e5a3a8096ac956e1be6c

7 years agoPPC: Handle right shift of > 31 bits. Fix #5999.
Erik de Castro Lopo [Wed, 29 Feb 2012 20:29:24 +0000 (07:29 +1100)] 
PPC: Handle right shift of > 31 bits. Fix #5999.

MERGED from commit 42c8e80165bb087493b95a768bbbf276870c7056

7 years agoPPC ppr: tabs -> spaces.
Erik de Castro Lopo [Wed, 29 Feb 2012 20:15:56 +0000 (07:15 +1100)] 
PPC ppr: tabs -> spaces.

MERGED from commit 857cd8edc4ab10286466e6ff6153766ba1e9d905

7 years agohp2ps: escape backslashes when generating output file (#5800).
Paolo Capriotti [Thu, 22 Mar 2012 20:16:27 +0000 (20:16 +0000)] 
hp2ps: escape backslashes when generating output file (#5800).

MERGED from commit ee8bf699516dd8e603e26a7c862538e83da2c250

7 years agoTweak to flag parsing (#5921)
Simon Marlow [Tue, 13 Mar 2012 11:30:13 +0000 (11:30 +0000)] 
Tweak to flag parsing (#5921)

-o2/Main.exe should be an invalid flag, not a linker input

MERGED from commit 93299cce9a4f7bc65b8164f779a37ef7f9f7c4a0

7 years agoIn ghci, reload after :e. Patch from Paolo Capriotti. Fixes #5343
Ian Lynagh [Sun, 11 Mar 2012 17:52:48 +0000 (17:52 +0000)] 
In ghci, reload after :e. Patch from Paolo Capriotti. Fixes #5343

MERGED from commit e212079dce3b86df4124d4dd819640f85f479a71

7 years agoGet correct options when calling 'clang' inplace of 'as' (#5903)
David Terei [Mon, 5 Mar 2012 04:53:37 +0000 (23:53 -0500)] 
Get correct options when calling 'clang' inplace of 'as' (#5903)

MERGED from commit 5e383469a9cb1fc17af3882f6217e5382a80fc67

7 years agoDocumentation update: Enumerations of Integers are subject to list fusion (#5670)
Joachim Breitner [Thu, 1 Dec 2011 21:31:05 +0000 (22:31 +0100)] 
Documentation update: Enumerations of Integers are subject to list fusion (#5670)

MERGED from commit 5adbc7535d755429b4cb80b0106eec42ec20b4b9

7 years agoAdd Haiku platform (#5828)
Paolo Capriotti [Wed, 7 Mar 2012 14:20:31 +0000 (14:20 +0000)] 
Add Haiku platform (#5828)

MERGED from commit 28f783f1c367784e0adcac2447682061a38f2ba3

7 years agoFix crash caused by allowing duplicate *-modules in the context (#5904)
Simon Marlow [Fri, 2 Mar 2012 11:57:32 +0000 (11:57 +0000)] 
Fix crash caused by allowing duplicate *-modules in the context (#5904)

MERGED from commit 0bc6055bdc140b35c563c0fc9a7a1b2ca92494cc

7 years agoRemove documentation that a feature was missing, because it is not. (#5896)
Simon Marlow [Mon, 27 Feb 2012 13:17:40 +0000 (13:17 +0000)] 
Remove documentation that a feature was missing, because it is not. (#5896)

MERGED from commit b1bd566a40d3cfe3db51aa1399b293cdbceff185

7 years agoMention -threaded in the intro to Concurrent Haskell
Simon Marlow [Mon, 27 Feb 2012 13:33:11 +0000 (13:33 +0000)] 
Mention -threaded in the intro to Concurrent Haskell

And make the docs a bit more concrete.

MERGED from commit 151b0dcd4e16e28d76fbdceadeea7287b49b9e29

7 years agoslight tweak to help text (#5896)
Simon Marlow [Mon, 27 Feb 2012 13:39:50 +0000 (13:39 +0000)] 
slight tweak to help text (#5896)

MERGED from commit eeaa573717ddd7a575edc075d869a1dfaadc5ddf

7 years agoBe less conservative about recompiling after changes to -main-is (#5878)
Simon Marlow [Thu, 16 Feb 2012 09:34:43 +0000 (09:34 +0000)] 
Be less conservative about recompiling after changes to -main-is (#5878)

MERGED from commits eda2c7316883e7d107755c08ad696e669ead0447 and
444e2fedb951a94a289d909b843f3281b9d2dc0a

7 years agoReplace createDirectoryHierarchy with createDirectoryIfMissing True
Takano Akio [Wed, 22 Feb 2012 02:18:29 +0000 (10:18 +0800)] 
Replace createDirectoryHierarchy with createDirectoryIfMissing True

createDirectoryHierarchy consisted of an existence test followed by
createDirectory, which failed if that directory was creted just after
the test. createDirectoryifMissing does not have this problem.

MERGED from commit ffe282cef4213ab8de515a8574d366994d38d5dd

7 years agopoint to the wiki for "Setting up your system for building GHC" (#5874)
Simon Marlow [Thu, 16 Feb 2012 10:37:03 +0000 (10:37 +0000)] 
point to the wiki for "Setting up your system for building GHC" (#5874)

MERGED from commit 95d2e12cbee185dd78a66e4cd44d6915519f1fa9

7 years agoraiseAsync: cope with ATOMICALLY_FRAMES inside UPDATE_FRAMES (#5866)
Simon Marlow [Mon, 27 Feb 2012 14:32:44 +0000 (14:32 +0000)] 
raiseAsync: cope with ATOMICALLY_FRAMES inside UPDATE_FRAMES (#5866)

MERGED from commit 014f1e1feee4c85a82f787ef8f01b44072051172

7 years agoFix a memory allocation bug (rts_argv wasn't big enough)
Simon Marlow [Wed, 14 Dec 2011 10:42:47 +0000 (10:42 +0000)] 
Fix a memory allocation bug (rts_argv wasn't big enough)

MERGED from commit dff852b1b65d07a4a400d3f20c854172c8fcecaf

7 years agoRefer to Control.Concurrent instead of GHC.Conc
Simon Marlow [Tue, 3 Jan 2012 11:32:10 +0000 (11:32 +0000)] 
Refer to Control.Concurrent instead of GHC.Conc

Modified version of a patch by shelarcy <shelarcy@gmail.com>

MERGED from commit 7d7809de3c6e264ae4af92c37da499502fc2fb20

7 years agofix ARM's StgCRun clobbered register list for both ARM and Thumb modes
Karel Gardas [Tue, 14 Feb 2012 07:01:47 +0000 (08:01 +0100)] 
fix ARM's StgCRun clobbered register list for both ARM and Thumb modes

MERGED from commit f3f8c90638e38088c3c8ea251f5c8e54e4047fe7

7 years agofix ARM StgCRun to not save and restore r11/fp register twice
Karel Gardas [Tue, 14 Feb 2012 07:03:07 +0000 (08:03 +0100)] 
fix ARM StgCRun to not save and restore r11/fp register twice

MERGED from commit 0bca11de22e7ad274608dc1198e51f68aae91694

7 years agoavoid 32-bit integer overflow (#5838)
Simon Marlow [Thu, 2 Feb 2012 10:28:34 +0000 (10:28 +0000)] 
avoid 32-bit integer overflow (#5838)

MERGED from commit bf456a09f9ef68436db48eb5ea25193d3b2f2ed5

7 years agoCheck that imported modules actually exist (#5836)
Simon Marlow [Wed, 1 Feb 2012 12:57:54 +0000 (12:57 +0000)] 
Check that imported modules actually exist (#5836)

MERGED from commit e46d26686034448a311f48f7e685f159af865d7c

7 years agoAdd a "tag" command to sync-all
Ian Lynagh [Thu, 2 Feb 2012 21:38:29 +0000 (21:38 +0000)] 
Add a "tag" command to sync-all

7 years agoMerge branch 'ghc-7.4' of http://darcs.haskell.org/ghc into ghc-7.4
Simon Peyton Jones [Thu, 2 Feb 2012 13:23:33 +0000 (13:23 +0000)] 
Merge branch 'ghc-7.4' of darcs.haskell.org/ghc into ghc-7.4

7 years agoFix dependency-analysis of type/class decls
Simon Peyton Jones [Thu, 2 Feb 2012 13:21:46 +0000 (13:21 +0000)] 
Fix dependency-analysis of type/class decls

Family instances don't define a new type, but we were bogusly
pretending they bound the family tycon.  The led to incorrect
dependencies with strange results; it showed up as Trac #5792.

This slightly hacky fix is on the branch only; I am doing a more
substantial refactoring on HEAD.

7 years agoSet RELEASE back to NO
Ian Lynagh [Thu, 2 Feb 2012 12:46:51 +0000 (12:46 +0000)] 
Set RELEASE back to NO

7 years agoUpdate ANNOUNCE for 7.4.1 ghc-7.4.1-release
Ian Lynagh [Tue, 31 Jan 2012 15:58:03 +0000 (15:58 +0000)] 
Update ANNOUNCE for 7.4.1

7 years agoSet version to 7.4.1, and RELEASE to YES
Ian Lynagh [Tue, 31 Jan 2012 15:52:19 +0000 (15:52 +0000)] 
Set version to 7.4.1, and RELEASE to YES

7 years agoAdd a note that PolyKinds are not yet fully mature
Ian Lynagh [Tue, 31 Jan 2012 12:52:38 +0000 (12:52 +0000)] 
Add a note that PolyKinds are not yet fully mature

and that bug reports are welcome.

7 years agoARM StgRun: Ensure r11 state is preserved
Ben Gamari [Mon, 30 Jan 2012 21:52:40 +0000 (16:52 -0500)] 
ARM StgRun: Ensure r11 state is preserved

7 years agoFix register clobber list in StgRun for ARM
Ben Gamari [Sat, 28 Jan 2012 21:55:04 +0000 (16:55 -0500)] 
Fix register clobber list in StgRun for ARM

The ARM implementation of StgRun does not claim that it clobbers r7-r12. As a
result, the compiler will sometimes put the returned RegTable in one of these
registers, resulting in an invalid RegTable to be returned. Hilarity ensues.

Signed-off-by: Ben Gamari <bgamari.foss@gmail.com>
7 years agoDon't record outputFile in the hashed flags
Simon Marlow [Tue, 3 Jan 2012 10:28:39 +0000 (10:28 +0000)] 
Don't record outputFile in the hashed flags

We don't want

    ghc --make M -o <file>

to force recompilation of all modules when <file> changes.  The -o
value is already taken into account by the recompilation machinery
when we check the modification time on the object file or the
executable.

7 years agoMERGED: FIX #5819: add -XDataKinds to the language options section of the user's...
Ian Lynagh [Mon, 30 Jan 2012 18:08:53 +0000 (18:08 +0000)] 
MERGED: FIX #5819: add -XDataKinds to the language options section of the user's guide

7 years agoFinish the release note TODOs
Ian Lynagh [Thu, 26 Jan 2012 15:58:51 +0000 (15:58 +0000)] 
Finish the release note TODOs

7 years agoImprove release notes
Ian Lynagh [Thu, 26 Jan 2012 03:13:54 +0000 (03:13 +0000)] 
Improve release notes

7 years agoFix bug introduced in fac8ecbbafde17dd92439c41747223c43e9d2b80
Simon Marlow [Thu, 19 Jan 2012 09:33:52 +0000 (09:33 +0000)] 
Fix bug introduced in fac8ecbbafde17dd92439c41747223c43e9d2b80

Fixes recent failures in hGetBuf001.

7 years agoAllow default superclass methods for multi-parameter type classes
Simon Peyton Jones [Tue, 17 Jan 2012 08:35:38 +0000 (08:35 +0000)] 
Allow default superclass methods for multi-parameter type classes

They were prohibited by mistake, a historical hangover

7 years agoDataConIds need to be treated specially in VectInfo
Manuel M T Chakravarty [Mon, 16 Jan 2012 01:58:42 +0000 (12:58 +1100)] 
DataConIds need to be treated specially in VectInfo

7 years agoFix vectorisation of classes
Manuel M T Chakravarty [Sun, 15 Jan 2012 11:10:28 +0000 (22:10 +1100)] 
Fix vectorisation of classes

- Make sure that we have no implicit names in ifaces
- Any vectorisation info makes a module an orphan module
- Allow 'Show' in vectorised code without vectorising it for the moment

7 years agoAdd a couple of release note TODOs
Ian Lynagh [Wed, 25 Jan 2012 14:25:12 +0000 (14:25 +0000)] 
Add a couple of release note TODOs

7 years agoFix build
Ian Lynagh [Wed, 25 Jan 2012 13:52:46 +0000 (13:52 +0000)] 
Fix build

7 years agoDocumentation for -XDataKinds
Jose Pedro Magalhaes [Mon, 16 Jan 2012 14:02:31 +0000 (15:02 +0100)] 
Documentation for -XDataKinds

7 years agoMERGED: Split -XDataKinds from -XPolyKinds
Ian Lynagh [Wed, 25 Jan 2012 13:20:21 +0000 (13:20 +0000)] 
MERGED: Split -XDataKinds from -XPolyKinds

commit 384f60996747b74aad7f3477e55433e822dd6398
Author: Jose Pedro Magalhaes <jpm@cs.uu.nl>
Date:   Mon Jan 16 14:18:22 2012 +0100

7 years agoAdd a missing newline in the ghci :h text; spotted by Alexander McPhail
Ian Lynagh [Tue, 24 Jan 2012 19:09:10 +0000 (19:09 +0000)] 
Add a missing newline in the ghci :h text; spotted by Alexander McPhail

7 years agoMERGED: Do not combine dictionaries in the EvVarCache when simplEqsOnly is on
Ian Lynagh [Tue, 24 Jan 2012 20:17:31 +0000 (20:17 +0000)] 
MERGED: Do not combine dictionaries in the EvVarCache when simplEqsOnly is on

commit f002a461768cb334355c17053dcd331aa9ed1e06
Author: Simon Peyton Jones <simonpj@microsoft.com>
Date:   Tue Jan 17 12:15:26 2012 +0000

Do not combine dictionaries in the EvVarCache when simplEqsOnly is on

This fixes Trac #5776; the background is in
Note [Simplifying RULE lhs constraints] in TcSimplify

7 years agoFix Trac #5658: strict bindings not floated in
Simon Peyton Jones [Thu, 12 Jan 2012 17:17:22 +0000 (17:17 +0000)] 
Fix Trac #5658: strict bindings not floated in

Two changes here

* The main change here is to enhance the FloatIn pass so that it can
  float case-bindings inwards.  In particular the case bindings for
  array indexing.

* Also change the code in Simplify, to allow a case on array
  indexing (ie can_fail is true) to be discarded altogether if its
  results are unused.

Lots of new comments in PrimOp about can_fail and has_side_effects

Some refactoring to share the FloatBind data structure between
FloatIn and FloatOut

7 years agoAdd comments about the meaning of can_fail and has_side_effects
Simon Peyton Jones [Mon, 12 Dec 2011 11:16:49 +0000 (11:16 +0000)] 
Add comments about the meaning of can_fail and has_side_effects

Taken from Trac #5658

7 years agoDocument -T RTS flag in manual.
Edward Z. Yang [Wed, 18 Jan 2012 04:55:53 +0000 (23:55 -0500)] 
Document -T RTS flag in manual.

Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
7 years agoIncorrect type conversion in LLVM backend (#5785).
Ubuntu [Wed, 18 Jan 2012 01:22:35 +0000 (01:22 +0000)] 
Incorrect type conversion in LLVM backend (#5785).

7 years agoUse nested tuples to desugar recursive do-notation
Simon Peyton Jones [Tue, 17 Jan 2012 16:40:03 +0000 (16:40 +0000)] 
Use nested tuples to desugar recursive do-notation

Easy fix for Trac #5742.

7 years agoFix bug causing polling instead of blocking in the non-threaded RTS (#5773)
Simon Marlow [Mon, 16 Jan 2012 09:49:24 +0000 (09:49 +0000)] 
Fix bug causing polling instead of blocking in the non-threaded RTS (#5773)

This was a regression introduced accidentally in
6b1098511aaabd2c9503ee7be6da1944466f9cb4.  We were previously passing
a large time value to select() to simulate blocking, and this broke
due to a change from unsigned to signed arithmetic.  I've refactored
it to be less fragile now - we just pass NULL as the timeval parameter
to select(), which is the correct way to do blocking.