Re: jhc vs ghc and the surprising result involving ghcgeneratedassembly.

2005-11-02 Thread Florian Weimer
* Lennart Augustsson: > Simon Marlow wrote: >>>Is it correct that you use indirect gotos across functions? Such >>>gotos aren't supported by GCC and work only by accident. >> Yes, but cross-function gotos are always to the beginning of a >> function. > > Is that enough to ensure that the constant

Re: jhc vs ghc and the surprising result involving ghcgeneratedassembly.

2005-11-02 Thread Lennart Augustsson
Simon Marlow wrote: Is it correct that you use indirect gotos across functions? Such gotos aren't supported by GCC and work only by accident. Yes, but cross-function gotos are always to the beginning of a function. Is that enough to ensure that the constant pool base register is reloaded on

Re: jhc vs ghc and the surprising result involving ghcgeneratedassembly.

2005-11-02 Thread Florian Weimer
* Simon Marlow: >> However, beginning with GCC 3.4, you can use: >> >> extern void bar(); >> >> void foo() >> { >> void (*p)(void) = bar; >> p(); >> } > > Interesting.. though I'm not sure I'm comfortable with relying on gcc's > tail call optimisation to do the right thing. Aren't there sid

RE: jhc vs ghc and the surprising result involving ghcgeneratedassembly.

2005-11-02 Thread Simon Marlow
On 02 November 2005 13:59, Florian Weimer wrote: > However, beginning with GCC 3.4, you can use: > > extern void bar(); > > void foo() > { > void (*p)(void) = bar; > p(); > } Interesting.. though I'm not sure I'm comfortable with relying on gcc's tail call optimisation to do the right thing

RE: jhc vs ghc and the surprising result involving ghcgeneratedassembly.

2005-10-27 Thread Simon Marlow
On 27 October 2005 12:12, John Meacham wrote: >> Note that GHC's back end is really aimed at producing good code when >> there are registers available for passing arguments - this isn't >> true on x86 or x86_64 at the moment, though. > > Hrm? why are registers not available on x86_64? I thought i