diff options
author | Michael Frysinger <vapier@gentoo.org> | 2011-03-27 03:47:30 +0000 |
---|---|---|
committer | Michael Frysinger <vapier@gentoo.org> | 2011-03-27 03:47:30 +0000 |
commit | d2d0cc5c32fad894689758a2d8f5a6629a295698 (patch) | |
tree | 990fc5e93ec2fc6b3184da2ee3a0d4378f9ba441 /libgloss | |
parent | 0f6ab41477d8c62e459215606b9caf7fb75280f6 (diff) | |
download | newlib-d2d0cc5c32fad894689758a2d8f5a6629a295698.zip newlib-d2d0cc5c32fad894689758a2d8f5a6629a295698.tar.gz newlib-d2d0cc5c32fad894689758a2d8f5a6629a295698.tar.bz2 |
libgloss: bfin: fix asm constraints for raise/excpt helpers
The RAISE and EXPT insns take a constant, not a register. So make
sure the asm constraints reflect this.
Diffstat (limited to 'libgloss')
-rw-r--r-- | libgloss/ChangeLog | 5 | ||||
-rw-r--r-- | libgloss/bfin/include/builtins.h | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/libgloss/ChangeLog b/libgloss/ChangeLog index dcdacd2..9f562ec 100644 --- a/libgloss/ChangeLog +++ b/libgloss/ChangeLog @@ -1,5 +1,10 @@ 2011-03-26 Mike Frysinger <vapier@gentoo.org> + * bfin/include/builtins.h (__builtin_raise): Change constraint to i. + (__builtin_excpt): Likewise. + +2011-03-26 Mike Frysinger <vapier@gentoo.org> + * bfin/Makefile.in (install-sim): Exit when install fails. (install-board): Likewise. diff --git a/libgloss/bfin/include/builtins.h b/libgloss/bfin/include/builtins.h index 7c9ece5..d33d2e9 100644 --- a/libgloss/bfin/include/builtins.h +++ b/libgloss/bfin/include/builtins.h @@ -34,8 +34,8 @@ extern "C" { #define __builtin_cli() ({ unsigned int __rval; __asm__ __volatile__ ("cli %0;" : "=r"(__rval)); __rval; }) #define __builtin_sti(x) __asm__ __volatile__ ("sti %0;" : : "r"(x)) #define __builtin_idle() __asm__ __volatile__ ("IDLE;") -#define __builtin_raise(x) __asm__ __volatile__ ("raise %0;" : : "r"(x)) -#define __builtin_excpt(x) __asm__ __volatile__ ("excpt %0;" : : "r"(x)) +#define __builtin_raise(x) __asm__ __volatile__ ("raise %0;" : : "n"(x)) +#define __builtin_excpt(x) __asm__ __volatile__ ("excpt %0;" : : "n"(x)) #define __builtin_prefetch(x) __asm__ __volatile__ ("PREFETCH[%0];" : : "p"(x)) #define __builtin_prefetchmodup(x) ({ void *__p = &(x); __asm__ __volatile__ ("PREFETCH[%0++];" : "+p"(__p)); __p; }) #define __builtin_flushinv(x) __asm__ __volatile__ ("FLUSHINV[%0];" : : "p"(x)) |