diff options
author | Nick Clifton <nickc@redhat.com> | 2015-04-15 07:41:07 +0000 |
---|---|---|
committer | Nick Clifton <nickc@gcc.gnu.org> | 2015-04-15 07:41:07 +0000 |
commit | e4614c187b7180754b6200412d5e3716c1df92a3 (patch) | |
tree | 1dd41b6f817ea637b6089d9f0c0b92cb51f09798 /gcc/doc | |
parent | 984b20545fee1f42c758006b8144159319a8ecf7 (diff) | |
download | gcc-e4614c187b7180754b6200412d5e3716c1df92a3.zip gcc-e4614c187b7180754b6200412d5e3716c1df92a3.tar.gz gcc-e4614c187b7180754b6200412d5e3716c1df92a3.tar.bz2 |
rx.opt (mallow-string-insns): New option.
* config/rx/rx.opt (mallow-string-insns): New option.
* config/rx/rx.c (RX_BUILTIN_RMPA): Disable the use of this
builtin if string instructions are denied.
* config/rx/rx.h (TARGET_CPU_CPP_BUILTINS): Define
__RX_ALLOW_STRING_INSNS__ or __RX_DISALLOW_STRING_INSNS__, as
appropriate.
(ASM_SPEC): Pass -mno-allow-string-insns on to the assembler.
* config/rx/rx.md (movstr): Enable pattern only if string
instructions are allowed.
(rx_movstr, rx_strend, movmemsi, rx_movmem): Likewise.
(cmpstrnsi, cmpstrsi, rx_cmpstrn, rmpa): Likewise.
* config/rx/t-rx (MULTILIB_OPTIONS): Add mno-allow-string-insns.
(MULTILIB_DIRNAMES): Add no-strings.
* doc/invoke.texi: Document -mno-allow-string-insns.
* gcc.target/rx/builtins.c: Disable RMPA test if string
instructions are not allowed.
From-SVN: r222116
Diffstat (limited to 'gcc/doc')
-rw-r--r-- | gcc/doc/invoke.texi | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 520c2c5..18f69906 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -940,6 +940,7 @@ See RS/6000 and PowerPC Options. -mmax-constant-size=@gol -mint-register=@gol -mpid@gol +-mallow-string-insns -mno-allow-string-insns@gol -mno-warn-multiple-fast-interrupts@gol -msave-acc-in-interrupts} @@ -20057,6 +20058,27 @@ fast interrupt handler when it is compiling a file. The default is to issue a warning for each extra fast interrupt handler found, as the RX only supports one such interrupt. +@item -mallow-string-insns +@itemx -mno-allow-string-insns +@opindex mallow-string-insns +@opindex mno-allow-string-insns +Enables or disables the use of the string manipulation instructions +@code{SMOVF}, @code{SCMPU}, @code{SMOVB}, @code{SMOVU}, @code{SUNTIL} +@code{SWHILE} and also the @code{RMPA} instruction. These +instructions may prefetch data, which is not safe to do if accessing +an I/O register. (See section 12.2.7 of the RX62N Group User's Manual +for more information). + +The default is to allow these instructions, but it is not possible for +GCC to reliably detect all circumstances where a string instruction +might be used to access an I/O register, so their use cannot be +disabled automatically. Instead it is reliant upon the programmer to +use the @option{-mno-allow-string-insns} option if their program +accesses I/O space. + +When the instructions are enabled GCC defines the C preprocessor +symbol @code{__RX_ALLOW_STRING_INSNS__}, otherwise it defines the +symbol @code{__RX_DISALLOW_STRING_INSNS__}. @end table @emph{Note:} The generic GCC command-line option @option{-ffixed-@var{reg}} |