Date: Sun, 27 Feb 2011 14:04:00 +1100 (EST) From: Bruce Evans <brde@optusnet.com.au> To: Dimitry Andric <dim@FreeBSD.org> Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r219079 - in head/sys/boot/i386: gptboot gptzfsboot zfsboot Message-ID: <20110227133227.S1974@besplex.bde.org> In-Reply-To: <201102270206.p1R269VO021432@svn.freebsd.org> References: <201102270206.p1R269VO021432@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 27 Feb 2011, Dimitry Andric wrote: > Log: > Clang's integrated assembler can now handle sys/boot/i386/boot2/sio.S. > It used to choke on the notation "inb (%dx),%al" for "inb %dx,%al"; GNU > as accepts both forms. Which notation is more 'correct' is an open > question. :) Nah, the former is just a syntax error since %dx is not dereferenced :-). It is a syntax error at the design level that parentheses are used for indirection. In better assembler syntaxes like Intel/Microsoft's one for x86 and Motorola's one for 6809, brackets are used for indirections so parentheses are not context-dependent. Then extra parentheses around expressions can have no effect. But dx isn't an expression, so (dx) should still be a syntax error. I think it is in I/M syntax but I can't test that easily. It is a syntax error in my x86/6809 assembler. My assembler doesn't check, but emits a diagnostic for this :-). (My assembler wants brackets for indirection, but it has an option to to implement some bugs including use of parentheses for indirection.) Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110227133227.S1974>