Hi Uwe,
I'm sorry about the delay replying to this message. I've investigated
your problem and its another of those "Hmmm, why doesn't this break
all the time things". I'll check a fix into the CVS sources.
In the meantime I have two possible work arounds:
The first is to change the definition of StateTrans in StateTrans.hs
from a newtype to a datatype. Unfortunatley this may distort your
profiles, so .....
The second is a hack, you'd better email me if you want it.
Incidentally, you will need to add the -prof option to the linking
phases of pplc and testNtree in the Makefile.
regards
Kevin
Uwe Schmidt writes:
> hi ghc group,
>
> I'm developing a small compiler for an experimental
> language for image generation, and i tried the profiling
> option to analyse where all the memory is used, and
> then the impossible occured:
>
> here is the listing:
>
> ----------------------
>
> si(4):~:39> cd tmp
> si(4):~/tmp:40> tar xvzf bug.tgz
> pl0/AbstractSyntax.hs
> pl0/Assemble.hs
> pl0/BuildinFunctions.hs
> pl0/BuiltinFunctions.hs
> pl0/CodeGeneration.hs
> pl0/ControlUnit.hs
> pl0/Error.hs
> pl0/GlobalState.hs
> pl0/Instructions.hs
> pl0/Lexer.hs
> pl0/Loader.hs
> pl0/MachineArchitecture.hs
> pl0/MachineStructure.hs
> pl0/Main.hs
> pl0/Matrix.hs
> pl0/MicroCode.hs
> pl0/NTree.hs
> pl0/OPCode.hs
> pl0/PPLInterpreter.hs
> pl0/Parser.hs
> pl0/Picture.hs
> pl0/Ppm.hs
> pl0/SemanticAnalysis.hs
> pl0/ShowAbstractSyntaxTree.hs
> pl0/ShowAttrTree.hs
> pl0/ShowCode.hs
> pl0/ShowJavaCode.hs
> pl0/ShowMS.hs
> pl0/StateTrans.hs
> pl0/Symbol.hs
> pl0/TestNTree.hs
> pl0/t.hs
> pl0/Makefile
> si(4):~/tmp:41> cd pl0/
> si(4):~/tmp/pl0:42> make ControlUnit.o
> ghc -prof -auto-all -K20m -H100m -O -c Instructions.hs
> ghc -prof -auto-all -K20m -H100m -O -c Matrix.hs
> ghc -prof -auto-all -K20m -H100m -O -c Picture.hs
> ghc -prof -auto-all -K20m -H100m -O -c MachineArchitecture.hs
> ghc -prof -auto-all -K20m -H100m -O -c StateTrans.hs
> ghc -prof -auto-all -K20m -H100m -O -c Error.hs
> ghc -prof -auto-all -K20m -H100m -O -c ShowCode.hs
> ghc -prof -auto-all -K20m -H100m -O -c ShowMS.hs
> ghc -prof -auto-all -K20m -H100m -O -c MicroCode.hs
> ghc -prof -auto-all -K20m -H100m -O -c Ppm.hs
> ghc -prof -auto-all -K20m -H100m -O -c OPCode.hs
> ghc -prof -auto-all -K20m -H100m -O -c ControlUnit.hs
>
> panic! (the `impossible' happened):
> CPR Analysis tried to take the lub of a function and a tuple
>
> Please report it as a compiler bug to [EMAIL PROTECTED]
>
>
> make: *** [ControlUnit.o] Error 1
> si(4):~/tmp/pl0:43> ghc --version
> The Glorious Glasgow Haskell Compilation System, version 4.08.2
> si(4):~/tmp/pl0:44> cat /proc/version
> Linux version 2.2.16 (root@sparbier) (gcc version 2.95.2 19991024
> (release)) #4 Thu Oct 5 18:40:46 CEST 2000
> si(4):~/tmp/pl0:45>
>
> -------------------------------------------------------------------
>
> the error does not occur without the profiling option,
> but it also occurs without -O and with -O2 instead of -O
>
>
> I hope, it's not too hard to find it
>
> uwe schmidt
>
> --
> ____________ ______
> \ \~~~\ \ \ / Fachhochschule Wedel | Prof.Dr. Uwe Schmidt
> \ \ \ \ \ / Feldstrasse 143 |
> \ \== \ \==\/ D-22880 Wedel | Tel : +49-4103-8048-45
> \ \ \ \ Fachbereich | Fax : +49-4103-8048-39
> \ / \ / Wirtschaftsinformatik | EMail: [EMAIL PROTECTED]
> \/ \/ "http://www.fh-wedel.de/~si/index.html
_______________________________________________
Glasgow-haskell-bugs mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs