C.Reinke | 2 Oct 2003 17:50
Picon
Favicon

Pre-Call for Contributions -- HC&A Report (November 2003 edition)


[apologies for multiple copies - experience has shown that not 
 all Haskellers can be reached via the main Haskell list anymore]

An entry for your diaries (no other action required right now):

------------------------------Pre-Call--------------------------------

   Your contributions to the November 2003 edition of the Haskell
       Communities & Activities Report will be invited soon.

                http://www.haskell.org/communities/

      Submissions are welcome between 20th and 31st of October

----------------------------------------------------------------------

The real Call for Contributions will follow closer to the submission
window, in about two weeks. This is just an early warning. You will
need to plan about 15 minutes for composing your contribution, which
would be a brief, ASCII-format, description of your Haskell activities
(see earlier editions for plenty of examples).

Cheers,

Claus (current editor of HC&A Reports)
ketil+haskell | 3 Oct 2003 11:07
Picon
Picon

Reading Floats


Hi,

I recently encountered something I found a bit peculiar when reading
floats from strings.  Leading zeroes seem okay, as long as there is no
decimal point.  To wit:

        Main> (map read ["1.0", "00000", "01", "01.0"]) :: [Float]
        [1.0,0.0,1.0,*** Exception: Prelude.read: no parse

Neither is leading decimal point allowed:

        Main> (read ".01") :: Float
        *** Exception: Prelude.read: no parse

Is this how it's supposed to be?

-kzm
--

-- 
If I haven't seen further, it is by standing in the footprints of giants
Abraham Egnor | 6 Oct 2003 00:22

force garbage collection?

Is there any way to force collection of all unreachable data structures?

Abe
Mark Carroll | 6 Oct 2003 04:13

Re: force garbage collection?

On Sun, 5 Oct 2003, Abraham Egnor wrote:

> Is there any way to force collection of all unreachable data structures?

I would guess that System.Mem.performGC would be worth a try.

-- Mark
Simon Peyton-Jones | 6 Oct 2003 13:43
Picon
Favicon
Gravatar

RE: Reading Floats

It's a definite bug. It'll be fixed in 6.02.  Thanks for reporting it.

Simon

| -----Original Message-----
| From: glasgow-haskell-users-bounces <at> haskell.org
[mailto:glasgow-haskell-users-
| bounces <at> haskell.org] On Behalf Of ketil+haskell <at> ii.uib.no
| Sent: 03 October 2003 10:08
| To: glasgow-haskell-users <at> haskell.org
| Subject: Reading Floats
| 
| 
| Hi,
| 
| I recently encountered something I found a bit peculiar when reading
| floats from strings.  Leading zeroes seem okay, as long as there is no
| decimal point.  To wit:
| 
|         Main> (map read ["1.0", "00000", "01", "01.0"]) :: [Float]
|         [1.0,0.0,1.0,*** Exception: Prelude.read: no parse
| 
| Neither is leading decimal point allowed:
| 
|         Main> (read ".01") :: Float
|         *** Exception: Prelude.read: no parse
| 
| Is this how it's supposed to be?
| 
| -kzm
(Continue reading)

Volker Stolz | 9 Oct 2003 16:03
Picon
Picon

Re: getSignalMask ghc6.0.1

In local.glasgow-haskell-users, you wrote:
> I can't do much with the provided examples, because getSignalMask exits 
> the program with:
> 
> Fail: invalid argument
> Action: getSignalMask
> Reason: Invalid argument

Looks like an actual bug in the library. Should be fixed in CVS now.
--

-- 
http://www-i2.informatik.rwth-aachen.de/stolz/ *** PGP *** S/MIME
rage against the finite state machine 
Donald Bruce Stewart | 11 Oct 2003 05:53
Picon
Picon
Favicon
Gravatar

mips-sgi-irix bootstrapping

rmartine:
> On Fri, 12 Sep 2003, Simon Marlow wrote:
> 
> > > ----------
> > > ../../ghc/utils/ghc-pkg/ghc-pkg-inplace --update-package
> > > <package.conf.inplace
> > > /usr/users/eden/scratch/ghc-6.0.1/ghc/driver/package.conf.inpl
> > > ace: parse error in package config file
> > > gmake[1]: *** [../../ghc/driver/stamp-pkg-conf-base] Error 1
> > > gmake: *** [boot] Error 1
> >
> > Have you done 'make boot' in ghc/driver?
> >

Yes, I had this error too. I've solved it by adding:

    [] into driver/package.conf.inplace
and
    touch driver/stamp-pkg-conf-rts

It is not so nice that ghc-inplace dumps core if package.conf.inplace
is an empty file... I think Ian has mentioned this too.

> 2.- Now the problem seems to be another one:
> 
> bash-2.05$ ghc/compiler/ghc-inplace  hello.hs
> 
> crash, and tracing the core it seems a problem having to do with gmp
> software:
> 
(Continue reading)

Donald Bruce Stewart | 11 Oct 2003 09:01
Picon
Picon
Favicon
Gravatar

Re: mips-sgi-irix bootstrapping

dons:
> rmartine:
> > 2.- Now the problem seems to be another one:
> > 
> > bash-2.05$ ghc/compiler/ghc-inplace  hello.hs
> > 
> > crash, and tracing the core it seems a problem having to do with gmp
> > software:
> > 
> > bash-2.05a$ gdb ghc-6.0.1 core
> > 
> > # 0x1153a208 in __decodeFloat ()
> > 
> > if I apply the "-v" flag, then
> > 
> > bash-2.05$ ghc/compiler/ghc-inplace -v hello.hs
> > bash-2.05a$ gdb ghc-6.0.1  core
> > 
> > # 0x11554ae4 in __gmpn_tdiv_qr / ( qp=0x454ed518 ...)
> > 
> > Any idea ?

Well, I had an idea :)

When you build an external gmp, you might just notice wizzing by
some statements about gmp linking to mips64 directories. At
least, I saw that.

So I went and rebuilt libgmp with --build=mips-sgi-irix, 
so that it would explicitly use the mips32 assembly. A patch to GHC to
(Continue reading)

Donald Bruce Stewart | 11 Oct 2003 14:21
Picon
Picon
Favicon
Gravatar

Re: mips-sgi-irix bootstrapping

dons:
> rmartine:
> > On Fri, 12 Sep 2003, Simon Marlow wrote:
> > 
> > > > ----------
> > > > ../../ghc/utils/ghc-pkg/ghc-pkg-inplace --update-package
> > > > <package.conf.inplace
> > > > /usr/users/eden/scratch/ghc-6.0.1/ghc/driver/package.conf.inpl
> > > > ace: parse error in package config file
> > > > gmake[1]: *** [../../ghc/driver/stamp-pkg-conf-base] Error 1
> > > > gmake: *** [boot] Error 1
> > >
> > > Have you done 'make boot' in ghc/driver?
> > >
> 
> Yes, I had this error too. I've solved it by adding:
> 
>     [] into driver/package.conf.inplace
> and
>     touch driver/stamp-pkg-conf-rts
> 
> It is not so nice that ghc-inplace dumps core if package.conf.inplace
> is an empty file... I think Ian has mentioned this too.

As a final note on this bug, the core dumps disappear on
mips-sgi-irix if I start from the beginning with 64bit code, i.e.
mips64-sgi-irix.

By setting -mabi=64 in CFLAGS, longs become 8 bytes, and
bugs disappear. No need for my hack of tricking gmp into using 32
(Continue reading)

Andreas.Schroeder | 14 Oct 2003 17:33
Picon

GHC with MS .Net 2003 C compiler

Hi all,

i am just evaluating Haskell (GHC) for the use in the company i work. I
have done some performance tests with Haskell, Java and C++
for some finance mathematical algorithms (you know, some folks are addicted
to performance - not i). Unfortunately, pure Haskell did not
perform very well. I then used a hybrid solution with some foreing called C
code (25 lines of C) to get some boost on performance after
some profiling analysis on "where is all the time gone?".

I don't know exactly why, but even with the optimize flags on, the hybrid
haskell solution takes six times longer than the C++ version
compiled with the MS .Net 2003 C++ compiler. This one is even three times
faster than the cygwin C++ compiler itself.
That's what made me think:
could i use the MS .Net 2003 C compiler to get the GHC libraries object
code and then link them with the generated C code from GHC
compiled again with the MS compiler?

If it's possible, how to?

Can anyone anticipate a performance improvement (like i do - well, at least
i hope)?

Btw, if you're interested, java (JDK 1.4.2_01 Server JVM) takes twice the
time of MS .Net compiled C++ for my test.

If you want, i can also post the Haskell code i tested.

Regards,
(Continue reading)


Gmane