diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2004-11-19 12:25:15 +0100 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2004-11-19 12:25:15 +0100 |
commit | edbe49d1f936a259ff4f6b6fe7dbb5a52b6e947f (patch) | |
tree | e6cb7234b46b272caa6b3438ab12f667a19c6fb4 | |
parent | 87b62748db18a61884ae1d37e8bbdf098400ddd8 (diff) | |
download | gcc-edbe49d1f936a259ff4f6b6fe7dbb5a52b6e947f.zip gcc-edbe49d1f936a259ff4f6b6fe7dbb5a52b6e947f.tar.gz gcc-edbe49d1f936a259ff4f6b6fe7dbb5a52b6e947f.tar.bz2 |
init.c (__gnat_map_signal): map SIGSEGV to Storage_Error for AE653 vthreads.
* init.c (__gnat_map_signal): map SIGSEGV to Storage_Error for AE653
vthreads.
(init_float): Eliminate initialization of floating point status for
AE653. The instructions have no effect for vThreads.
From-SVN: r90911
-rw-r--r-- | gcc/ada/init.c | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/gcc/ada/init.c b/gcc/ada/init.c index 30a2098..86152f9 100644 --- a/gcc/ada/init.c +++ b/gcc/ada/init.c @@ -1704,19 +1704,25 @@ __gnat_map_signal (int sig) exception = &constraint_error; msg = "SIGILL"; break; +#ifdef VTHREADS case SIGSEGV: - exception = &program_error; - msg = "SIGSEGV"; + exception = &storage_error; + msg = "SIGSEGV: possible stack overflow"; break; case SIGBUS: -#ifdef VTHREADS exception = &storage_error; msg = "SIGBUS: possible stack overflow"; + break; #else + case SIGSEGV: + exception = &program_error; + msg = "SIGSEGV"; + break; + case SIGBUS: exception = &program_error; msg = "SIGBUS"; -#endif break; +#endif default: exception = &program_error; msg = "unhandled signal"; @@ -1777,8 +1783,10 @@ void __gnat_init_float (void) { /* Disable overflow/underflow exceptions on the PPC processor, this is needed - to get correct Ada semantic. */ -#if defined (_ARCH_PPC) && !defined (_SOFT_FLOAT) + to get correct Ada semantics. Note that for AE653 vThreads, the HW + overflow settings are an OS configuration issue. The instructions + below have no effect */ +#if defined (_ARCH_PPC) && !defined (_SOFT_FLOAT) && !defined (VTHREADS) asm ("mtfsb0 25"); asm ("mtfsb0 26"); #endif |