int scopeLevel;
int lvaluereq;
-extern int labelKey ;
-
symbol *returnLabel ; /* function return label */
symbol *entryLabel ; /* function entry label */
/*-----------------------------------------------------------------*/
else
return FALSE;
}
-
- etype = getSpec(operandType(op));
+ else
+ {
+ etype = getSpec(operandType(op));
+ }
return (IN_FARSPACE(SPEC_OCLS(etype)) ? TRUE : FALSE);
}
/* under the following conditions create a
register equivalent for a local symbol */
if (sym->level && sym->etype && SPEC_OCLS(sym->etype) &&
- IN_FARSPACE(SPEC_OCLS(sym->etype)) &&
+ (IN_FARSPACE(SPEC_OCLS(sym->etype)) && (!IS_DS390_PORT)) &&
options.stackAuto == 0)
ok =0;
}
/* if register parm then make it a send */
- if ((parms->argSym && IS_REGPARM(parms->argSym->etype)) ||
- IS_REGPARM(parms->etype)) {
+ if (((parms->argSym && IS_REGPARM(parms->argSym->etype)) ||
+ IS_REGPARM(parms->etype)) &&
+ !IS_RENT(fetype)) {
ic = newiCode(SEND,pval,NULL);
ADDTOCHAIN(ic);
} else {
and before liveRange calculation */
if (!sym->addrtaken && !IS_VOLATILE(sym->etype)) {
- if(IN_FARSPACE(SPEC_OCLS(sym->etype)) &&
- options.stackAuto == 0) {
+ if (IN_FARSPACE(SPEC_OCLS(sym->etype)) &&
+ options.stackAuto == 0 &&
+ !IS_DS390_PORT) {
} else {
opl = newiTempOperand(args->type,0);
sym->reqv = opl ;
tree->opval.op != SWITCH &&
tree->opval.op != FUNCTION &&
tree->opval.op != INLINEASM ) {
+
if (IS_ASSIGN_OP(tree->opval.op) ||
IS_DEREF_OP(tree) ||
(tree->opval.op == '&' && !tree->right) ||
tree->opval.op == PTR_OP) {
- lvaluereq++;
- if (IS_ARRAY_OP(tree->left) && IS_ARRAY_OP(tree->left->left))
+ lvaluereq++;
+ if ((IS_ARRAY_OP(tree->left) && IS_ARRAY_OP(tree->left->left)) ||
+ (IS_DEREF_OP(tree) && IS_ARRAY_OP(tree->left)))
{
- lvaluereq--;
+ int olvr = lvaluereq ;
+ lvaluereq = 0;
left = operandFromAst(tree->left);
+ lvaluereq = olvr - 1;
} else {
left = operandFromAst(tree->left);
lvaluereq--;