Fixed problems with OptPrecalc. It removed insns because it results were known
- but the insns generate a carry which may be needed later. git-svn-id: svn://svn.cc65.org/cc65/trunk@4115 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
67d64e67d5
commit
f6c589bf8e
1 changed files with 2 additions and 7 deletions
|
@ -1880,9 +1880,7 @@ unsigned OptPrecalc (CodeSeg* S)
|
|||
}
|
||||
break;
|
||||
|
||||
case OP65_ASL:
|
||||
case OP65_EOR:
|
||||
case OP65_LSR:
|
||||
if (RegValIsKnown (Out->RegA)) {
|
||||
/* Accu op zp with known contents */
|
||||
Arg = MakeHexArg (Out->RegA);
|
||||
|
@ -1901,9 +1899,6 @@ unsigned OptPrecalc (CodeSeg* S)
|
|||
/* 0-0 or 0+0 -> remove */
|
||||
CS_DelEntry (S, I);
|
||||
++Changes;
|
||||
} else if (RegValIsKnown (Out->RegA)) {
|
||||
/* Accu op zp with known contents */
|
||||
Arg = MakeHexArg (Out->RegA);
|
||||
}
|
||||
break;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue