Mysql - Linuxthreads : Still needed?
Paul Armstrong
freebsdhackers at otoh.org
Sat Nov 13 00:08:10 PST 2004
On Wed, Nov 10, 2004 at 11:01:31AM +0100, Michael Riexinger wrote:
> > "jesk" <jesk at killall.org> wrote:
> > > fbsd outperformed linux in the end of my tests. ;)
> > > dont forget to disable HTT, this will increase the performance of
> > > threading.
> >
> > In my tests also. This is good. IMHO it's a great relief to get rid
> > of linuxthreds.
> But when he outperformed linux, he used linuxthreads.. With pthreads you
> still can't outperform linux :(
True.
I just did a test to see how different it is currently. Not the best
hardware (Celeron 1800MHz, 128MB RAM, IDE Disks) but hopefully it
gives people a baseline to work with. The test was done on 5.3-RELEASE with
SCHED_4BSD (I can post the rest of the kernel config if anyone wants)
select-key-BSD:
Query Barrel Report for client smacker1
connect: max=15ms min=12ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 4 0 1559.46
Query Barrel Report for client smacker1
connect: max=15ms min=12ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 4 0 1758.16
Query Barrel Report for client smacker1
connect: max=13ms min=10ms avg= 11ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 3 0 1722.87
Query Barrel Report for client smacker1
connect: max=20ms min=12ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 8 0 1676.66
Query Barrel Report for client smacker1
connect: max=18ms min=13ms avg= 14ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 5 0 1692.29
Query Barrel Report for client smacker1
connect: max=14ms min=12ms avg= 12ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 3 0 1696.06
select-key-LINUX:
Query Barrel Report for client smacker1
connect: max=16ms min=9ms avg= 11ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 7 0 1831.38
Query Barrel Report for client smacker1
connect: max=20ms min=10ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 4 0 1828.62
Query Barrel Report for client smacker1
connect: max=41ms min=9ms avg= 28ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 5 2 1835.86
Query Barrel Report for client smacker1
connect: max=25ms min=8ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 6 1 1832.44
Query Barrel Report for client smacker1
connect: max=21ms min=10ms avg= 14ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 5 0 1830.18
Query Barrel Report for client smacker1
connect: max=22ms min=9ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 20000 7 0 1836.76
update-select-BSD:
Query Barrel Report for client smacker
connect: max=21ms min=11ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 8 0 743.17
update_index 10000 3 0 743.17
Query Barrel Report for client smacker
connect: max=12ms min=5ms avg= 8ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 8 0 749.86
update_index 10000 4 0 749.86
Query Barrel Report for client smacker
connect: max=15ms min=12ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 6 0 747.45
update_index 10000 19 0 747.45
Query Barrel Report for client smacker
connect: max=13ms min=11ms avg= 12ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 4 0 752.27
update_index 10000 5 0 752.27
Query Barrel Report for client smacker
connect: max=21ms min=11ms avg= 12ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 6 0 731.93
update_index 10000 3 0 731.93
Query Barrel Report for client smacker
connect: max=18ms min=12ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 6 0 744.35
update_index 10000 4 0 744.35
update-select-LINUX:
Query Barrel Report for client smacker
connect: max=21ms min=9ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 59 0 758.63
update_index 10000 9 0 758.63
Query Barrel Report for client smacker
connect: max=11ms min=8ms avg= 10ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 8 0 754.47
update_index 10000 5 0 754.47
Query Barrel Report for client smacker
connect: max=12ms min=8ms avg= 10ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 7 0 741.90
update_index 10000 6 0 741.90
Query Barrel Report for client smacker
connect: max=16ms min=9ms avg= 12ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 4 0 749.66
update_index 10000 4 0 749.66
Query Barrel Report for client smacker
connect: max=15ms min=8ms avg= 11ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 5 0 743.45
update_index 10000 7 0 743.45
Query Barrel Report for client smacker
connect: max=19ms min=8ms avg= 13ms from 10 clients
Query_type num_queries max_time min_time q_per_s
select_index 10000 7 0 749.40
update_index 10000 5 0 749.40
The script:
#!/bin/sh --
PATH="${PATH}:/usr/local/smack/bin"
export PATH
/usr/local/etc/rc.d/mysql-server.sh stop
pkg_delete mysql-server-4.1.7
pkg_delete mysql-client-4.1.7
# BSD
cd /var/tmp/BSD-threads
pkg_add mysql-server-4.1.7.tgz
/usr/local/etc/rc.d/mysql-server.sh start
sleep 5
cd /usr/local/smack
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-BSD
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-BSD
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-BSD
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-BSD
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-BSD
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-BSD
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-BSD
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-BSD
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-BSD
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-BSD
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-BSD
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-BSD
/usr/local/etc/rc.d/mysql-server.sh stop
pkg_delete mysql-server-4.1.7
pkg_delete mysql-client-4.1.7
# LINUX
cd /var/tmp/LINUX-threads
pkg_add mysql-server-4.1.7.tgz
/usr/local/etc/rc.d/mysql-server.sh start
sleep 5
cd /usr/local/smack
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-LINUX
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-LINUX
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-LINUX
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-LINUX
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-LINUX
super-smack -d mysql select-key.smack 10 1000 >> /var/tmp/select-key-LINUX
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-LINUX
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-LINUX
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-LINUX
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-LINUX
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-LINUX
super-smack -d mysql update-select.smack 10 1000 >> /var/tmp/update-select-LINUX
More information about the freebsd-hackers
mailing list