Commit edbe49d1 by Arnaud Charlet

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
parent 87b62748
...@@ -1704,19 +1704,25 @@ __gnat_map_signal (int sig) ...@@ -1704,19 +1704,25 @@ __gnat_map_signal (int sig)
exception = &constraint_error; exception = &constraint_error;
msg = "SIGILL"; msg = "SIGILL";
break; break;
#ifdef VTHREADS
case SIGSEGV: case SIGSEGV:
exception = &program_error; exception = &storage_error;
msg = "SIGSEGV"; msg = "SIGSEGV: possible stack overflow";
break; break;
case SIGBUS: case SIGBUS:
#ifdef VTHREADS
exception = &storage_error; exception = &storage_error;
msg = "SIGBUS: possible stack overflow"; msg = "SIGBUS: possible stack overflow";
break;
#else #else
case SIGSEGV:
exception = &program_error;
msg = "SIGSEGV";
break;
case SIGBUS:
exception = &program_error; exception = &program_error;
msg = "SIGBUS"; msg = "SIGBUS";
#endif
break; break;
#endif
default: default:
exception = &program_error; exception = &program_error;
msg = "unhandled signal"; msg = "unhandled signal";
...@@ -1777,8 +1783,10 @@ void ...@@ -1777,8 +1783,10 @@ void
__gnat_init_float (void) __gnat_init_float (void)
{ {
/* Disable overflow/underflow exceptions on the PPC processor, this is needed /* Disable overflow/underflow exceptions on the PPC processor, this is needed
to get correct Ada semantic. */ to get correct Ada semantics. Note that for AE653 vThreads, the HW
#if defined (_ARCH_PPC) && !defined (_SOFT_FLOAT) 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 25");
asm ("mtfsb0 26"); asm ("mtfsb0 26");
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment