[MLton-devel] Re: HiPE/x86 Erlang compiler paper

Matthew Fluet fluet@CS.Cornell.EDU
Fri, 7 Jun 2002 08:27:16 -0400 (EDT)


> To me it seems that item 3 is mostly a consequence of the other two.

That's true.  

> I've updated our HiPE/x86 paper's comment about MLTon; it's necessarily
> brief but please let me know if it in any way misrepresents MLTon:
> ...

That's concise and accurate.  One minor note, it is "MLton" not "MLTon".

> Also, could to say how may register you use for parameter passing? I was
> never able to quite deduce that while browsing your code.

Intraprocedurally, we use up to 5 general purpose registers and 6
floating-point registers to pass temporaries.  Interprocedurally, we don't
use any, although it would be a nice idea to do so for leaf-functions.
The exception to the above is that heap and stack pointers are always
passed in their respective registers, both intra- and inter- procedurally.

> Any why does your stack grow towards higher addresses? Can't the backend
> decide for itself how to implement the stack?

In principle, yes, we could grow in the other direction.  The x86-backend
was developed after the C-backend was well established and initially we
wanted to remain compatible with the runtime and garbage collector.  Steve
can probably answer why the original C-backend chose to grow the stack in
that direction.



_______________________________________________________________

Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm

_______________________________________________
MLton-devel mailing list
MLton-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlton-devel