[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Page Boundary Question



The way I would handle it is to test the sign

          ldy   #0
          lda  (pcl),y    ;address of branch displacement
          bmi  back
          clc
          adc  pcl
          sta   pcl
          lda   pch
          adc #0
          sta  pch
          rts
back  sec
          lda  pcl
          sbc  (pcl),y
          sta   pcl
          lda   pch
         sbc   #0
         sta   pch
         rts


"Bryan Parkoff" <spam> wrote in message
qiadnROgGJHJNm2jXTWcpg@texas.net">news:qiadnROgGJHJNm2jXTWcpg@texas.net...
>     Let me say.
>
>     Carry should be present when 20FF goes into 2100.  It does not mean to
> use Carry Flag.  Carry Flag is never used for operation.  I think that
> secondary Carry Flag is in 9th bit before NV11DIZC.  9th bit is always
> invisible that it is used for operation.
>     For example, low byte FF adds 1 to become 00.  High byte receives 9th
> Carry Bit before 9th Carry Bit is added into high byte 20 that is now 21.
> It shows 2100.  It is how operation tells to add one extra cycle.
>     Low byte subtracts 1 to become FF.  High byte receives 9th Carry Bit
> before 9th Carry Bit is added into high byte 20 that is now 1F.  It shows