> > I'm currently building ghc 4.08.2 on HP-UX using gcc 
> 2.95.2, so we'll
> > see how that goes.  I have one or two local patches in my 
> > tree from last
> > time I did this that may have an impact on the dynamic 
> calling issue.
> 
> Good luck to you. While I have a pretty good idea of how the regular C
> runtime environment functions on HP-UX, I think I'm getting 
> too lost in the
> GHC modifications to this for my attempts to work. Let me 
> know if you hit
> any HP specific stumbling blocks that you think I may be able 
> to help with.

Phew.  I've just got around to trying this, and the initial results are
as expected: gcc 2.95.2 causes the generated program to crash, whereas
gcc 2.7.2.1 worked.

There are some obvious differences in the code generated by 2.95.2.  Try
the following program:

        extern void f(void);
        void g(void) { void (*h)(void) = f; }

compile it with gcc 2.95.2 and gcc 2.7.2.  In the 2.95.2 version, there
is an extra indirection for f: the compiler generates some kind of
static constant for it.  That's what is causing GHC trouble.  I assume
this is the shared library support you were talking about before?

Is there any way to stop gcc doing this, or do we just have to accept
the extra indirection for every jump?

> > That sounds reasonable: you could try adding NSUBSPA to the
> > T_MOVE_DIRVS
> > declaration for HPPA in the mangler and see if that makes a 
> > difference.
> 
> I'll give it a spin.

did it work?

Cheers,
        Simon

_______________________________________________
Glasgow-haskell-bugs mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to