]> sourceware.org Git - cgen.git/commitdiff
Improve operand docs on `foo' vs `o-foo'.
authorDoug Evans <xdje42@gmail.com>
Wed, 19 Aug 2009 17:17:24 +0000 (17:17 +0000)
committerDoug Evans <xdje42@gmail.com>
Wed, 19 Aug 2009 17:17:24 +0000 (17:17 +0000)
ChangeLog
doc/rtl.texi

index ba86478d440bc420cb2c632b1598e34cad99c1a4..4b041dcf192d54ca76ce673f73f8912dfa044431 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,6 +5,7 @@
 
        * doc/rtl.texi (Instructions): Improve docs of when ${...} is needed
        in assembler syntax.
+       (Operands): Similarly.
 
 2009-08-18  Doug Evans  <dje@sebabeach.org>
 
index 86a98cc4ade3e236f95c11c17297b5e1c82f057a..b876dc97eb8666d57fd6f1f3871c733f0bf1d20a 100644 (file)
@@ -1614,9 +1614,6 @@ The syntax for defining an operand is:
 The required elements are: @code{name}, @code{type}, @code{mode},
 and if @code{type} is not a scaler @code{index}.
 
-There is no convention for prefixing operands,
-and generally for readability's sake operands don't have a prefix.
-
 @subsection name
 
 This is the name of the operand as a Scheme symbol.
@@ -1630,6 +1627,12 @@ with @samp{f-} and hardware elements begin with @samp{h-}).  A prefix
 like @samp{o-} would avoid collisions with other semantic elements, but
 operands are used often enough that any prefix is a hassle.
 
+Note that if you @emph{do} decide to prefix operand names, e.g. use
+a style like @samp{o-foo}, then you will need to remember to use the
+@samp{$@{o-foo@}} form in the assembler syntax and not the @samp{$o-foo}
+form because the latter only takes alphanumeric characters.
+@xref{assembler-syntax, syntax}.
+
 @subsection attrs
 
 A list of attributes. In addition to attributes defined for the operand,
@@ -1968,6 +1971,7 @@ real insn.
 For macro-instructions, don't use during disassembly.
 @end table
 
+@anchor{assembler-syntax}
 @subsection syntax
 
 This is a character string consisting of raw characters and operands.
This page took 0.045533 seconds and 5 git commands to generate.