Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
04/16/07 13:09
Modified:
  04/16/07 14:57

Read: times


 
Msg Score: +1
 +1 Good Answer/Helpful
#137322 - One further comment is needed
Responding to: ???'s previous message
Patrick said:
no further comments are needed.

One further comment is needed: The idea tha RET returns to an address that's stored in a pair of registers is pointless and confusing. This idea has already resulted in references to R8 and R9, which don't even exist!

This idea first came up in Mike's discussion of an incorrect program where the RET was executed without first executing an ACALL or LCALL instruction. In every normal case, RET will return to an address that was pushed onto the stack by a corresponding ACALL or LCALL. By the time the RET instruction is executed, the stack pointer will be above any registers that are being used, at an address that is of no consequence as long as the stack doesn't overflow.

So don't start thinking that RET returns to an address stored in the registers. In every normal case, it doesn't.

-- Russ


List of 34 messages in thread
TopicAuthorDate
RxD to LCD problems            01/01/70 00:00      
   Serial ISR            01/01/70 00:00      
   work needed.            01/01/70 00:00      
   you need to control flow            01/01/70 00:00      
      confused            01/01/70 00:00      
         this is what I mean            01/01/70 00:00      
            OK            01/01/70 00:00      
               yes            01/01/70 00:00      
            Non-useful Serial ISR            01/01/70 00:00      
               AND it's stuck            01/01/70 00:00      
                  thanks            01/01/70 00:00      
               I was going for optimization.            01/01/70 00:00      
      It's functioning            01/01/70 00:00      
         now stay consistent            01/01/70 00:00      
            Terminating code?            01/01/70 00:00      
               .            01/01/70 00:00      
                  correct terminology            01/01/70 00:00      
                  Missing the point            01/01/70 00:00      
                     i get it now            01/01/70 00:00      
                        Most, but not all            01/01/70 00:00      
                        why on earth            01/01/70 00:00      
                        if it\'s almost correct, it\'s still wrong :-)            01/01/70 00:00      
                           ok            01/01/70 00:00      
                              Not R6 and R7            01/01/70 00:00      
                                 well it happend again            01/01/70 00:00      
                                    Q.E.D.            01/01/70 00:00      
                                       One further comment is needed            01/01/70 00:00      
                              Hey            01/01/70 00:00      
                        Dangerous recommendation            01/01/70 00:00      
                           good point            01/01/70 00:00      
                              they all do            01/01/70 00:00      
                  it 'trust' the same as 'experiment'?            01/01/70 00:00      
   more issues            01/01/70 00:00      
      Joe, please read this            01/01/70 00:00      

Back to Subject List