From: Johan K. <joh...@id...> - 2001-03-24 18:07:14
|
Option --stack-auto without e.g. --int-long-reent crashed the compiler for: int mul(int i1, int i2) { return i1*i2; } int test (int a, int b) { return mul(a,b); } because no variables were generated for the second _mulsint() parameter in mul(). This confused SDCCopt.c:convilong() and SDCCopt.c:cnvToFcall(). Of course no one should ever want this, but since you can it has to be right. Fixed in SDCCsymt.c:processFuncArgs(). Now we still have the problem that for test(), b is pushed, but a isn't reg-parm-ed. Parameters aren't reg-parmed anyway (in the mcs51 port, I recall some discussions about this for the ds390 port) for reent or vararg functions. So that's the next challenge. Johan |