X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=src%2Fcc65%2Fcodeinfo.c;h=322b471ff0e8109a9bfb0d906d870ff67a7cb614;hb=4a667ead00c10797fb57298b3dd33c2efc6c8d3f;hp=ed4fae03b3b5cd6344dd545f9cc97854e99fdb75;hpb=73dfa23c987d8a7f1154801b85c171f9e01dcd58;p=cc65 diff --git a/src/cc65/codeinfo.c b/src/cc65/codeinfo.c index ed4fae03b..322b471ff 100644 --- a/src/cc65/codeinfo.c +++ b/src/cc65/codeinfo.c @@ -616,6 +616,10 @@ unsigned GetKnownReg (unsigned Use, const RegContents* RC) return (RC == 0 || RC->RegY >= 0)? REG_Y : REG_NONE; } else if ((Use & REG_TMP1) != 0) { return (RC == 0 || RC->Tmp1 >= 0)? REG_TMP1 : REG_NONE; + } else if ((Use & REG_PTR1_LO) != 0) { + return (RC == 0 || RC->Ptr1Lo >= 0)? REG_PTR1_LO : REG_NONE; + } else if ((Use & REG_PTR1_HI) != 0) { + return (RC == 0 || RC->Ptr1Hi >= 0)? REG_PTR1_HI : REG_NONE; } else if ((Use & REG_SREG_LO) != 0) { return (RC == 0 || RC->SRegLo >= 0)? REG_SREG_LO : REG_NONE; } else if ((Use & REG_SREG_HI) != 0) { @@ -625,7 +629,7 @@ unsigned GetKnownReg (unsigned Use, const RegContents* RC) } } - + static cmp_t FindCmpCond (const char* Code, unsigned CodeLen) /* Search for a compare condition by the given code using the given length */