Commit ec849b19 authored by Davi Arnaut's avatar Davi Arnaut

Bug#42524: Function pthread_setschedprio() is defined but seems broken on i5/OS PASE

The problem is that MySQL use of pthread_setschedprio is not
supported by i5/OS and the default system behavior for unsupported
calls is to emit a SIGILL signal which causes the server to
abort.

The solution is to treat the pthread_setschedprio as inexistent
when compiling binaries for i5/OS. This also does not invalidate
the fix for bug 38477 as the only supported dispatch class is
SCHED_OTHER (which is passed to pthread_setschedparam).

configure.in:
  Skip pthread_setschedprio check on i5/OS.
parent e27f6536
......@@ -2048,7 +2048,7 @@ AC_CHECK_FUNCS(alarm bcmp bfill bmove bsearch bzero \
mkstemp mlockall perror poll pread pthread_attr_create mmap mmap64 getpagesize \
pthread_attr_getstacksize pthread_attr_setprio pthread_attr_setschedparam \
pthread_attr_setstacksize pthread_condattr_create pthread_getsequence_np \
pthread_key_delete pthread_rwlock_rdlock pthread_setprio pthread_setschedprio \
pthread_key_delete pthread_rwlock_rdlock pthread_setprio \
pthread_setprio_np pthread_setschedparam pthread_sigmask readlink \
realpath rename rint rwlock_init setupterm \
shmget shmat shmdt shmctl sigaction sigemptyset sigaddset \
......@@ -2071,6 +2071,15 @@ case "$target" in
;;
esac
case "$mysql_cv_sys_os" in
OS400) # i5/OS (OS/400) emits a SIGILL (Function not implemented) when
# unsupported priority values are passed to pthread_setschedprio.
# Since the only supported value is 1, treat it as inexistent.
;;
*) AC_CHECK_FUNCS(pthread_setschedprio)
;;
esac
# Check that isinf() is available in math.h and can be used in both C and C++
# code
AC_MSG_CHECKING(for isinf in <math.h>)
......
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