When compiling the attached sample, iCode 37 is dead. It writes iTemp1, which will never be read.
kilLDeadCode from SDCCopt.c doesn't catch this due to
/* 2. if assignment and result is a temp & isaddr then skip */
/* since this means array & pointer access, will be taken */
/* care of by alias analysis. */
/* if the result is a temp & isaddr then skip */
if (IC_RESULT (ic) && POINTER_SET (ic))
Then, in live range analysis, we mark Temp1 as alive at iCode 37, but no subsequent ones (findNextUse won't find a next use). Thus this problem increases register pressure unnecessarily.
I found and can reproduce this on the Z80, but it's probably there for all ports.