1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-24 11:31:31 +00:00

Minor improvement in last change

git-svn-id: svn://svn.cc65.org/cc65/trunk@4014 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
uz 2009-08-15 13:42:40 +00:00
parent 3717443f3b
commit b391929acb

View File

@ -1478,14 +1478,16 @@ unsigned OptTransfers4 (CodeSeg* S)
* replace the transfer by a load and remove the initial load.
*/
if ((GetRegInfo (S, I, LoadEntry->Chg) & LoadEntry->Chg) == 0 &&
(LoadEntry->AM == AM65_ABS || LoadEntry->AM == AM65_ZP) &&
(LoadEntry->AM == AM65_ABS ||
LoadEntry->AM == AM65_ZP ||
LoadEntry->AM == AM65_IMM) &&
!MemAccess (S, Load+1, Xfer-1, E->Arg)) {
/* Generate the replacement load insn */
CodeEntry* X = 0;
switch (XferEntry->OPC) {
case OP65_TXA:
case OP65_TXA:
case OP65_TYA:
X = NewCodeEntry (OP65_LDA,
LoadEntry->AM,