SMP users needed to test patch (make sysent) (result)
Saifi Khan
saifi.khan at datasynergy.org
Thu Nov 5 09:25:08 PST 2009
On Thu, 5 Nov 2009, Saifi Khan wrote:
> On Thu, 5 Nov 2009, Stathis Kamperis wrote:
>
> > 2009/11/4 Stathis Kamperis <ekamperi at gmail.com>:
> > > Hello everyone!
> > >
> > > I'd like to mark mq*() syscall as MPSAFE, but before that I need
> > > someone to test them in an SMP capable machine running SMP kernel. I
> > > only have UP machines around.
> > >
> > > So, if anyone is able and kind enough, here are some directions on how
> > > to do it. I assume s\he is running HEAD.
> > >
> > > cd /usr/src
> > > fetch http://leaf.dragonflybsd.org/~beket/mq-mpsafe.diff
> > > git apply mq-mpsafe.diff
> > > make buildkernel
> > > make installkernel
> > > reboot
> > > git clone git://gitweb.dragonflybsd.org/~beket/pcca-tests.git
> > > cd pcca-tests/mqueue.h
> > > make && make -k run
> > > cd etc
> > > make
> > > sysctl -w kern.mqueue.mq_prio_max=200
> > > ./t_mq_parallel_threads
> > > ./t_mq_parallel_fork
> >
> > Unfortunately, I forgot to mention one crucial step. After the patch
> > application one should type 'make sysent' inside sys/kern, so that the
> > syscall-related files be regenerated, namely the init_sysent.c. Or
> > even better, *I* should have added the init_sysent.c changes in my
> > patch. Since buildkernel doesn't regenerate these files automatically,
> > I'm afraid that the tests ran with giant lock held upon syscall
> > invocation.
> >
>
> Stathis, no issues at all !
>
Ran the tests once again and here is the log.
$make -k run
t_mq_ambig: passed
t_mq_close: passed
t_mq_notify_simple: passed
t_mq_open: passed
t_mq_open_close: passed
t_mq_open_umask: passed
t_mq_parent_child: passed
t_mq_parent_child_multmsg: passed
t_mq_prio: passed
t_mq_select: passed
t_mq_send: Assertion failed: (rv == -1 && errno == EINVAL), function main, file t_mq_send.c, line 56.
*** Signal 6 (ignored)
t_mq_setattr: passed
t_mq_timedsend: passed
t_mq_timedreceive_timeout: passed
t_mq_timedsend_timeout: passed
# sysctl -w kern.mqueue.mq_prio_max=200
kern.mqueue.mq_prio_max: 200 -> 200
$./t_mq_parallel_threads
passed
$./t_mq_parallel_fork
passed
$
Just out of curiousity,
-----------------------
# sysctl -w kern.mqueue.mq_prio_max=32
kern.mqueue.mq_prio_max: 200 -> 32
$./t_mq_parallel_threads
Assertion failed: (rv != -1), function thread1, file t_mq_parallel_threads.c, line 121.
Abort trap (core dumped)
Core was generated by `t_mq_parallel_th'.
Program terminated with signal 6, Aborted.
#0 0x00000008008b9ac8 in lwp_kill () from /usr/lib/libc.so.7
(gdb) bt
#0 0x00000008008b9ac8 in lwp_kill () from /usr/lib/libc.so.7
#1 0x000000080074f9d5 in _thr_send_sig () from /usr/lib/libpthread.so.0
#2 0x0000000800749d59 in raise () from /usr/lib/libpthread.so.0
#3 0x0000000800934ad1 in abort () from /usr/lib/libc.so.7
#4 0x0000000800926908 in __assert () from /usr/lib/libc.so.7
#5 0x0000000000401156 in thread1 (arg=0x0) at t_mq_parallel_threads.c:121
#6 0x000000080074be86 in ?? () from /usr/lib/libpthread.so.0
#7 0x0000000000000000 in ?? ()
(gdb)
$./t_mq_parallel_fork
Assertion failed: (rv != -1), function main, file t_mq_parallel_fork.c, line 114.
Abort trap (core dumped)
$
Core was generated by `t_mq_parallel_fo'.
Program terminated with signal 6, Aborted.
#0 0x00000008008bb010 in kill () from /usr/lib/libc.so.7
(gdb) bt
#0 0x00000008008bb010 in kill () from /usr/lib/libc.so.7
#1 0x0000000800749d47 in raise () from /usr/lib/libpthread.so.0
#2 0x0000000800934ad1 in abort () from /usr/lib/libc.so.7
#3 0x0000000800926908 in __assert () from /usr/lib/libc.so.7
#4 0x0000000000400ec1 in main () at t_mq_parallel_fork.c:114
(gdb)
Let me know.
thanks
Saifi.
More information about the Users
mailing list