[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: "test-lock" stuck on FreeBSD
From: |
Ed Maste |
Subject: |
Re: "test-lock" stuck on FreeBSD |
Date: |
Thu, 4 Dec 2014 09:38:12 -0500 |
On 3 December 2014 at 22:53, Daiki Ueno <address@hidden> wrote:
>
> Actually, I haven't tried it on a bare metal, but on Assaf's freebsd10
> build-ready VM image:
>
> http://www.nongnu.org/pretest/downloads/
Oh, nice - I hadn't encountered that project before. It looks like a
great resource.
I downloaded the image from there and ran it in bhyve (FreeBSD's hypervisor):
% xz -dk freebsd10.build-ready.qcow2.xz
% qemu-img convert -O raw freebsd10.build-ready.qcow2 freebsd10.build-ready.raw
% sh vmrun.sh -m 384 -d freebsd10.build-ready.raw pretest
and then I built and ran the test code:
$ cc -o test-once test-once-pthread.c -lpthread
$ time ./test-once > /dev/null
5.10 real 1.51 user 7.98 sys
$ time ./test-once > /dev/null
4.91 real 1.38 user 7.74 sys
$ time ./test-once > /dev/null
4.93 real 1.51 user 7.67 sys
$ time ./test-once > /dev/null
4.90 real 1.42 user 7.74 sys
...
I've run it in a loop over 100 times and it is consistently 5 to 6
seconds real time, 8 to 10 seconds sys.
Perhaps there's some poor interaction with KVM involved? You mentioned
you have more reports of this issue - do you know the FreeBSD version
and whether it's bare metal or in a VM?
-Ed