From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111c93,6faf6b79bcc4957c X-Google-Attributes: gid111c93,public From: "Martin Sinot" Subject: Re: newbie assembly question: lda versus addq Date: 1999/11/15 Message-ID: <80p4tj$qa9$1@news.telekabel.nl>#1/1 X-Deja-AN: 548838099 References: <80l2s1$cfs$1@nnrp1.deja.com> X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 X-Trace: news.telekabel.nl 942675699 26953 212.142.20.102 (15 Nov 1999 14:21:39 GMT) Organization: SPaSE BV X-MSMail-Priority: Normal NNTP-Posting-Date: 15 Nov 1999 14:21:39 GMT Newsgroups: comp.os.linux.alpha wrote in message news:80l2s1$cfs$1@nnrp1.deja.com... > Hi all, > Is there any way in which "addq X, literal, Y" is superior to "lda > Y,literal(X)"? That I can tell addq only supports an 8 bit literal, > while lda supports 16 bit literals. Why would I ever want to use the > addq version? > > PS: Thanks Jon, Mark, and Peter for your responses on assembly > documentation. Those docs have helped quite a bit. > > > Sent via Deja.com http://www.deja.com/ > Before you buy. As far as I can see, the only reason you would want to use addq is if you want to be able to generate an exception. Other than that, I see no difference in performance between the two. And then lda has the advantage of being able to add a signed 16-bit integer, while addq can only add an unsigned 8-bit integer. You might still want to use addq for readability reasons, though. Martin Sinot martin@spase.nl