/* if iCodes are not the same */
/* see the operands maybe interchanged */
if (ic->op == cdp->diCode->op &&
- (ic->op == '+' || ic->op == '*') &&
+ IS_ASSOCIATIVE(ic) &&
isOperandEqual (IC_LEFT (ic), IC_RIGHT (cdp->diCode)) &&
isOperandEqual (IC_RIGHT (ic), IC_LEFT (cdp->diCode)))
{
ic->op != '-')
return 0;
- /* this check is a hueristic to prevent live ranges
+ /* this check is a heuristic to prevent live ranges
from becoming too long */
if (IS_PTR (operandType (IC_RESULT (ic))))
return 0;
return 0;
/* check if we can find a definition for the
- right hand side */
+ left hand side */
if (!(applyToSet (cseSet, diCodeForSym, IC_LEFT (ic), &dic)))
return 0;