Discussion:
[9fans] maxround and stack frame sizes
(too old to reply)
Anthony Martin
2013-01-22 10:49:17 UTC
Permalink
I'm curious about the origins of the maxround
function in the compilers. Specifically, why is
5c different from all the others?

It seems the common implementation gives rise
to unnecessarily large stack frames.

For convenience:

/sys/src/cmd/6c/swt.c:/^maxround
/sys/src/cmd/5c/swt.c:/^maxround
/sys/src/cmd/cc/dcl.c:/^adecl

Thanks,
Anthony
erik quanstrom
2013-01-22 15:24:53 UTC
Permalink
Post by Anthony Martin
It seems the common implementation gives rise
to unnecessarily large stack frames.
yes, at first glance, it seems it could. surprising given the
kernel macro, that round() rounds up.

- erik

Loading...