binutils-gdb/gas/doc/c-lm32.texi
Thomas Preud'homme a05a5b64cf Fix use of "command line X" in binutils doc
Binutils documentation uses a mix of spelling for the compound word
"command-line X". According to [1]:

"Sometimes compound words are written separately (nail polish),
sometimes with a hyphen (short-sighted) and sometimes as one word
(eyelashes). Often new compounds are written as two separate words and,
as they become more familiar, they are either connected with a hyphen
(-) or made into one word."

I think command-line X is common enough in our industry that the two
workds command and line should be connected. Since command-line is more
common than commandline, I propose to update binutils documentation to
consistently use "command-line" when this is used as an adjective to a
noun (eg. command-line argument, command-line switch, command-line
option and command-line flag). I've left occurences of "the command
line" as is. I've also left gdb, sim and readline alone and have only
touched public documentation (texi and NEWS files).

[1]
http://dictionary.cambridge.org/grammar/british-grammar/word-formation/compounds

2018-07-02  Thomas Preud'homme  <thomas.preudhomme@arm.com>

bfd/
	* doc/bfdint.texi: Use command-line consistently when used in a
	compount word.
	* doc/bfdsumm.texi: Likewise.

binutils/
	* NEWS: Use command-line consistently when used in a compount word.
	* doc/binutils.texi: Likewise and fix trailing whitespace on same
	line.

gas/
	* NEWS: Use command-line consistently when used in a compount word.
	* doc/as.texi: Likewise.
	* doc/c-aarch64.texi: Likewise.
	* doc/c-alpha.texi: Likewise.
	* doc/c-arc.texi: Likewise.
	* doc/c-arm.texi: Likewise.
	* doc/c-avr.texi: Likewise.
	* doc/c-bfin.texi: Likewise.
	* doc/c-cris.texi: Likewise.
	* doc/c-epiphany.texi: Likewise.
	* doc/c-i386.texi: Likewise.
	* doc/c-ia64.texi: Likewise.
	* doc/c-lm32.texi: Likewise.
	* doc/c-m32r.texi: Likewise.
	* doc/c-m68k.texi: Likewise.
	* doc/c-mips.texi: Likewise.
	* doc/c-mmix.texi: Likewise.
	* doc/c-msp430.texi: Likewise.
	* doc/c-mt.texi: Likewise.
	* doc/c-nios2.texi: Likewise.
	* doc/c-ppc.texi: Likewise.
	* doc/c-pru.texi: Likewise.
	* doc/c-rl78.texi: Likewise.
	* doc/c-rx.texi: Likewise.
	* doc/c-tic6x.texi: Likewise.
	* doc/c-v850.texi: Likewise.
	* doc/c-vax.texi: Likewise.
	* doc/c-visium.texi: Likewise.
	* doc/c-xstormy16.texi: Likewise.
	* doc/c-xtensa.texi: Likewise.
	* doc/c-z80.texi: Likewise.
	* doc/c-z8k.texi: Likewise.
	* doc/internals.texi: Likewise.

gprof/
	* gprof.texi: Use command-line consistently when used in a compount
	word.

ld/
	* NEWS: Use command-line consistently when used in a compount word.
	* ld.texinfo: Likewise.
	* ldint.texinfo: Likewise.
2018-07-02 11:18:24 +01:00

233 lines
5.1 KiB
Plaintext

@c Copyright (C) 2008-2018 Free Software Foundation, Inc.
@c This is part of the GAS manual.
@c For copying conditions, see the file as.texinfo.
@ifset GENERIC
@page
@node LM32-Dependent
@chapter LM32 Dependent Features
@end ifset
@ifclear GENERIC
@node Machine Dependencies
@chapter LM32 Dependent Features
@end ifclear
@cindex LM32 support
@menu
* LM32 Options:: Options
* LM32 Syntax:: Syntax
* LM32 Opcodes:: Opcodes
@end menu
@node LM32 Options
@section Options
@cindex LM32 options (none)
@cindex options for LM32 (none)
@table @code
@cindex @code{-mmultiply-enabled} command-line option, LM32
@item -mmultiply-enabled
Enable multiply instructions.
@cindex @code{-mdivide-enabled} command-line option, LM32
@item -mdivide-enabled
Enable divide instructions.
@cindex @code{-mbarrel-shift-enabled} command-line option, LM32
@item -mbarrel-shift-enabled
Enable barrel-shift instructions.
@cindex @code{-msign-extend-enabled} command-line option, LM32
@item -msign-extend-enabled
Enable sign extend instructions.
@cindex @code{-muser-enabled} command-line option, LM32
@item -muser-enabled
Enable user defined instructions.
@cindex @code{-micache-enabled} command-line option, LM32
@item -micache-enabled
Enable instruction cache related CSRs.
@cindex @code{-mdcache-enabled} command-line option, LM32
@item -mdcache-enabled
Enable data cache related CSRs.
@cindex @code{-mbreak-enabled} command-line option, LM32
@item -mbreak-enabled
Enable break instructions.
@cindex @code{-mall-enabled} command-line option, LM32
@item -mall-enabled
Enable all instructions and CSRs.
@end table
@node LM32 Syntax
@section Syntax
@menu
* LM32-Regs:: Register Names
* LM32-Modifiers:: Relocatable Expression Modifiers
* LM32-Chars:: Special Characters
@end menu
@node LM32-Regs
@subsection Register Names
@cindex LM32 register names
@cindex register names, LM32
LM32 has 32 x 32-bit general purpose registers @samp{r0},
@samp{r1}, ... @samp{r31}.
The following aliases are defined: @samp{gp} - @samp{r26},
@samp{fp} - @samp{r27}, @samp{sp} - @samp{r28},
@samp{ra} - @samp{r29}, @samp{ea} - @samp{r30},
@samp{ba} - @samp{r31}.
LM32 has the following Control and Status Registers (CSRs).
@table @code
@item IE
Interrupt enable.
@item IM
Interrupt mask.
@item IP
Interrupt pending.
@item ICC
Instruction cache control.
@item DCC
Data cache control.
@item CC
Cycle counter.
@item CFG
Configuration.
@item EBA
Exception base address.
@item DC
Debug control.
@item DEBA
Debug exception base address.
@item JTX
JTAG transmit.
@item JRX
JTAG receive.
@item BP0
Breakpoint 0.
@item BP1
Breakpoint 1.
@item BP2
Breakpoint 2.
@item BP3
Breakpoint 3.
@item WP0
Watchpoint 0.
@item WP1
Watchpoint 1.
@item WP2
Watchpoint 2.
@item WP3
Watchpoint 3.
@end table
@node LM32-Modifiers
@subsection Relocatable Expression Modifiers
@cindex LM32 modifiers
@cindex syntax, LM32
The assembler supports several modifiers when using relocatable addresses
in LM32 instruction operands. The general syntax is the following:
@smallexample
modifier(relocatable-expression)
@end smallexample
@table @code
@cindex symbol modifiers
@item lo
This modifier allows you to use bits 0 through 15 of
an address expression as 16 bit relocatable expression.
@item hi
This modifier allows you to use bits 16 through 23 of an address expression
as 16 bit relocatable expression.
For example
@smallexample
ori r4, r4, lo(sym+10)
orhi r4, r4, hi(sym+10)
@end smallexample
@item gp
This modified creates a 16-bit relocatable expression that is
the offset of the symbol from the global pointer.
@smallexample
mva r4, gp(sym)
@end smallexample
@item got
This modifier places a symbol in the GOT and creates a 16-bit
relocatable expression that is the offset into the GOT of this
symbol.
@smallexample
lw r4, (gp+got(sym))
@end smallexample
@item gotofflo16
This modifier allows you to use the bits 0 through 15 of an
address which is an offset from the GOT.
@item gotoffhi16
This modifier allows you to use the bits 16 through 31 of an
address which is an offset from the GOT.
@smallexample
orhi r4, r4, gotoffhi16(lsym)
addi r4, r4, gotofflo16(lsym)
@end smallexample
@end table
@node LM32-Chars
@subsection Special Characters
@cindex line comment character, LM32
@cindex LM32 line comment character
The presence of a @samp{#} on a line indicates the start of a comment
that extends to the end of the current line. Note that if a line
starts with a @samp{#} character then it can also be a logical line
number directive (@pxref{Comments}) or a preprocessor
control command (@pxref{Preprocessing}).
@cindex line separator, LM32
@cindex statement separator, LM32
@cindex LM32 line separator
A semicolon (@samp{;}) can be used to separate multiple statements on
the same line.
@node LM32 Opcodes
@section Opcodes
@cindex LM32 opcode summary
@cindex opcode summary, LM32
@cindex mnemonics, LM32
@cindex instruction summary, LM32
For detailed information on the LM32 machine instruction set, see
@url{http://www.latticesemi.com/products/intellectualproperty/ipcores/mico32/}.
@code{@value{AS}} implements all the standard LM32 opcodes.