From owner-freebsd-stable@FreeBSD.ORG Thu Oct 12 14:47:57 2006 Return-Path: X-Original-To: stable@freebsd.org Delivered-To: freebsd-stable@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6DDC116A4DE for ; Thu, 12 Oct 2006 14:47:57 +0000 (UTC) (envelope-from ohmer@epita.info) Received: from marge.cload.net (marge.cload.net [88.191.31.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4AF9E43D5F for ; Thu, 12 Oct 2006 14:47:51 +0000 (GMT) (envelope-from ohmer@epita.info) Received: (qmail 1393 invoked from network); 12 Oct 2006 14:48:42 -0000 Received: from unknown (HELO moe.cload.net) (192.168.2.16) by 0 with ESMTP; 12 Oct 2006 14:48:42 -0000 From: Matthieu Michaud To: stable@freebsd.org Content-Type: multipart/mixed; boundary="=-zavRfSVl9bCRFgRJrlpP" Date: Thu, 12 Oct 2006 16:47:49 +0200 Message-Id: <1160664469.92207.51.camel@moe.cload.net> Mime-Version: 1.0 X-Mailer: Evolution 2.6.2 FreeBSD GNOME Team Port Cc: Subject: VIA C7 support X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Oct 2006 14:47:57 -0000 --=-zavRfSVl9bCRFgRJrlpP Content-Type: text/plain Content-Transfer-Encoding: 7bit Hi all, I rent a small server based on a VIA C7 on which I installed a 6.2-PRERELEASE as of today (see dmesg and kernconf attached). It runs fairly well but I wonder if it couldn't be faster. According to padlock(4) man page, crypto hardware support is available by adding padlock, crypto and cryptodev kernel options. I compiled it as modules. I haven't noticed difference between 'openssl speed' and 'openssl speed -engine padlock'. I attached results. Is this simple test relevant ? I doubt it, then I tried cryptotest. See attached results here too. They are significantly different and doesn't make sense to me. Finally, I tried to read 16M from /dev/random and /dev/urandom to look at RNG support. It reads at 2M/s on both device. Comparing to a P4 1.7G and P4 2.8G, it's few : they both performs around 14M/s on almost as recent kernel. So the question is : Is it the best that C7 can do ? Is C7 support complete ? Did i forgot something in my setup ? -- Matthieu Michaud --=-zavRfSVl9bCRFgRJrlpP Content-Disposition: attachment; filename=dmesg Content-Type: text/plain; name=dmesg; charset=us-ascii Content-Transfer-Encoding: 7bit Copyright (c) 1992-2006 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. FreeBSD 6.2-PRERELEASE #4: Thu Oct 12 14:47:11 CEST 2006 root@marge.cload.net:/data/obj/data/src/sys/MARGE Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: VIA C7 Esther+RNG+AES+AES-CTR+SHA1+SHA256+RSA (1995.02-MHz 686-class CPU) Origin = "CentaurHauls" Id = 0x6a9 Stepping = 9 Features=0xa7c9bbff Features2=0x181 real memory = 1056899072 (1007 MB) avail memory = 1029435392 (981 MB) ACPI APIC Table: ioapic0 irqs 0-23 on motherboard PadLock: HW support loaded for AES-CBC,SHA1,SHA256. acpi0: on motherboard acpi0: Power Button (fixed) Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000 acpi_timer0: <24-bit timer at 3.579545MHz> port 0x408-0x40b on acpi0 cpu0: on acpi0 acpi_throttle0: on cpu0 acpi_button0: on acpi0 acpi_button1: on acpi0 pcib0: port 0xcf8-0xcff on acpi0 pci0: on pcib0 pcib1: at device 1.0 on pci0 pci1: on pcib1 pci1: at device 0.0 (no driver attached) vge0: port 0xfc00-0xfcff mem 0xfdfff000-0xfdfff0ff irq 18 at device 14.0 on pci0 miibus0: on vge0 ciphy0: on miibus0 ciphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto vge0: Ethernet address: 00:40:63:e5:c6:53 atapci0: port 0xf800-0xf807,0xf400-0xf403,0xf000-0xf007,0xec00-0xec03,0xe800-0xe80f,0xe400-0xe4ff irq 20 at device 15.0 on pci0 ata2: on atapci0 ata3: on atapci0 atapci1: port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0xe000-0xe00f at device 15.1 on pci0 ata0: on atapci1 ata1: on atapci1 isab0: at device 17.0 on pci0 isa0: on isab0 acpi_tz0: on acpi0 atkbdc0: port 0x60,0x64 irq 1 on acpi0 atkbd0: irq 1 on atkbdc0 kbd0 at atkbd0 atkbd0: [GIANT-LOCKED] pmtimer0 on isa0 orm0: at iomem 0xd0000-0xd0fff on isa0 sc0: at flags 0x100 on isa0 sc0: VGA <16 virtual consoles, flags=0x300> vga0: at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0 Timecounter "TSC" frequency 1995019075 Hz quality 800 Timecounters tick every 1.000 msec ad4: 152627MB at ata2-master SATA150 Trying to mount root from ufs:/dev/ad4s2a vge0: link state changed to UP --=-zavRfSVl9bCRFgRJrlpP Content-Disposition: attachment; filename=MARGE Content-Type: text/plain; name=MARGE; charset=us-ascii Content-Transfer-Encoding: 7bit machine i386 cpu I686_CPU ident MARGE options SCHED_4BSD # 4BSD scheduler options PREEMPTION # Enable kernel thread preemption options INET # InterNETworking options INET6 # IPv6 communications protocols options FFS # Berkeley Fast Filesystem options SOFTUPDATES # Enable FFS soft updates support options UFS_ACL # Support for access control lists options UFS_DIRHASH # Improve performance on big directories options COMPAT_43 # Compatible with BSD 4.3 [KEEP THIS!] options COMPAT_FREEBSD4 # Compatible with FreeBSD4 options COMPAT_FREEBSD5 # Compatible with FreeBSD5 options KTRACE # ktrace(1) support options SYSVSHM # SYSV-style shared memory options SYSVMSG # SYSV-style message queues options SYSVSEM # SYSV-style semaphores options _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions options KBD_INSTALL_CDEV # install a CDEV entry in /dev options ADAPTIVE_GIANT # Giant mutex is adaptive. options ATA_STATIC_ID # Static device numbering device apic device eisa device pci device ata device atadisk device atkbdc device atkbd device vga device sc device pmtimer device miibus # MII bus support device vge # VIA VT612x gigabit Ethernet device loop # Network loopback device random # Entropy device device ether # Ethernet support device tun # Packet tunnel. device pty # Pseudo-ttys (telnet etc) device md # Memory "disks" device gif # IPv6 and IPv4 tunneling device bpf # Berkeley packet filter device pf device pflog --=-zavRfSVl9bCRFgRJrlpP Content-Disposition: attachment; filename=openssl-speed Content-Type: text/plain; name=openssl-speed; charset=us-ascii Content-Transfer-Encoding: 7bit OpenSSL 0.9.7e-p1 25 Oct 2004 built on: Thu Oct 12 13:22:53 CEST 2006 options:bn(64,32) md2(int) rc4(idx,int) des(ptr,risc1,16,long) aes(partial) idea(int) blowfish(idx) compiler: cc available timing options: USE_TOD HZ=128 [sysconf value] timing function used: getrusage The 'numbers' are in 1000s of bytes per second processed. type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes md2 926.89k 1965.55k 2732.59k 3027.63k 3126.26k mdc2 2353.08k 2640.18k 2722.75k 2744.25k 2750.47k md4 8640.95k 29370.81k 80202.73k 141111.83k 181785.90k md5 7080.20k 22949.42k 58214.33k 94430.02k 115475.88k hmac(md5) 7622.76k 24195.23k 60177.73k 95688.82k 115697.58k sha1 6007.25k 16277.71k 32972.39k 44381.86k 49483.83k rmd160 5411.26k 14678.04k 29733.34k 40029.11k 44520.63k rc4 70920.18k 78366.56k 80296.01k 80981.97k 81142.91k des cbc 21435.42k 22179.70k 22413.24k 22474.29k 22495.38k des ede3 7696.98k 7800.72k 7832.07k 7839.68k 7841.94k idea cbc 14992.16k 15938.03k 16178.19k 16236.31k 16257.41k rc2 cbc 9675.99k 10144.46k 10247.54k 10273.73k 10279.47k rc5-32/12 cbc 72558.48k 81683.16k 84886.45k 85731.80k 85983.09k blowfish cbc 38505.33k 41063.32k 41722.67k 41925.72k 41984.39k cast cbc 38048.38k 40415.37k 41184.42k 41382.10k 41441.06k aes-128 cbc 15924.19k 16195.34k 16298.80k 16324.95k 16329.34k aes-192 cbc 13827.58k 14034.00k 14107.97k 14131.65k 14139.05k aes-256 cbc 12227.19k 12384.50k 12445.05k 12460.06k 12464.50k sign verify sign/s verify/s rsa 512 bits 0.0014s 0.0002s 704.0 6127.0 rsa 1024 bits 0.0066s 0.0004s 151.4 2443.3 rsa 2048 bits 0.0386s 0.0013s 25.9 783.2 rsa 4096 bits 0.2536s 0.0044s 3.9 225.6 sign verify sign/s verify/s dsa 512 bits 0.0011s 0.0013s 903.0 744.3 dsa 1024 bits 0.0032s 0.0039s 313.4 255.7 dsa 2048 bits 0.0105s 0.0131s 94.9 76.5 --=-zavRfSVl9bCRFgRJrlpP Content-Disposition: attachment; filename=openssl-speed-engine-padlock Content-Type: text/plain; name=openssl-speed-engine-padlock; charset=us-ascii Content-Transfer-Encoding: 7bit OpenSSL 0.9.7e-p1 25 Oct 2004 built on: Thu Oct 12 13:22:53 CEST 2006 options:bn(64,32) md2(int) rc4(idx,int) des(ptr,risc1,16,long) aes(partial) idea(int) blowfish(idx) compiler: cc available timing options: USE_TOD HZ=128 [sysconf value] timing function used: getrusage The 'numbers' are in 1000s of bytes per second processed. type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes md2 926.71k 1965.13k 2732.77k 3027.82k 3126.50k mdc2 2353.13k 2640.43k 2722.76k 2744.01k 2750.81k md4 8653.88k 29367.42k 80209.53k 141100.90k 181569.33k md5 7050.98k 22932.62k 58222.26k 94432.85k 115478.55k hmac(md5) 7597.42k 24148.13k 60080.03k 95658.86k 115684.63k sha1 6029.43k 16336.72k 33102.33k 44506.94k 49503.42k rmd160 5413.33k 14689.45k 29767.49k 40025.51k 44529.03k rc4 70957.19k 78383.96k 80317.73k 80993.01k 81169.05k des cbc 21448.26k 22191.83k 22424.85k 22482.34k 22500.89k des ede3 7697.59k 7800.84k 7832.65k 7840.36k 7842.72k idea cbc 14990.63k 15938.73k 16179.18k 16240.31k 16257.89k rc2 cbc 9675.28k 10145.26k 10248.09k 10274.11k 10281.19k rc5-32/12 cbc 72566.03k 81681.32k 84897.26k 85740.66k 85987.88k blowfish cbc 38509.02k 41065.69k 41726.27k 42030.89k 41986.99k cast cbc 38050.10k 40417.81k 41187.49k 41385.43k 41429.79k aes-128 cbc 15923.62k 16196.76k 16299.92k 16325.19k 16332.93k aes-192 cbc 13834.79k 14036.46k 14114.45k 14133.76k 14139.64k aes-256 cbc 12224.84k 12385.14k 12445.41k 12460.33k 12464.60k sign verify sign/s verify/s rsa 512 bits 0.0014s 0.0002s 704.7 6133.5 rsa 1024 bits 0.0066s 0.0004s 151.4 2443.9 rsa 2048 bits 0.0386s 0.0013s 25.9 786.1 rsa 4096 bits 0.2536s 0.0044s 3.9 225.8 sign verify sign/s verify/s dsa 512 bits 0.0011s 0.0013s 903.0 749.6 dsa 1024 bits 0.0032s 0.0039s 313.4 258.7 dsa 2048 bits 0.0105s 0.0130s 94.9 76.8 --=-zavRfSVl9bCRFgRJrlpP Content-Disposition: attachment; filename=cryptotest-z-4096 Content-Type: text/plain; name=cryptotest-z-4096; charset=us-ascii Content-Transfer-Encoding: 7bit [ohmer@marge /usr/src/tools/tools/crypto]$ ./cryptotest -z 4096 0.035 sec, 8192 aes crypts, 16 bytes, 3707102 byte/sec, 28.3 Mb/sec 0.035 sec, 8192 aes crypts, 32 bytes, 7479998 byte/sec, 57.1 Mb/sec 0.036 sec, 8192 aes crypts, 64 bytes, 14504731 byte/sec, 110.7 Mb/sec 0.038 sec, 8192 aes crypts, 128 bytes, 27789362 byte/sec, 212.0 Mb/sec 0.039 sec, 8192 aes crypts, 256 bytes, 53254241 byte/sec, 406.3 Mb/sec 0.042 sec, 8192 aes crypts, 512 bytes, 100231898 byte/sec, 764.7 Mb/sec 0.047 sec, 8192 aes crypts, 1024 bytes, 177461561 byte/sec, 1353.9 Mb/sec 0.060 sec, 8192 aes crypts, 2048 bytes, 279564354 byte/sec, 2132.9 Mb/sec 0.083 sec, 8192 aes crypts, 4096 bytes, 404109595 byte/sec, 3083.1 Mb/sec 0.184 sec, 8192 aes crypts, 8192 bytes, 365606298 byte/sec, 2789.4 Mb/sec 0.039 sec, 8192 aes192 crypts, 16 bytes, 3398465 byte/sec, 25.9 Mb/sec 0.038 sec, 8192 aes192 crypts, 32 bytes, 6892541 byte/sec, 52.6 Mb/sec 0.039 sec, 8192 aes192 crypts, 64 bytes, 13433637 byte/sec, 102.5 Mb/sec 0.040 sec, 8192 aes192 crypts, 128 bytes, 26245238 byte/sec, 200.2 Mb/sec 0.043 sec, 8192 aes192 crypts, 256 bytes, 49327343 byte/sec, 376.3 Mb/sec 0.044 sec, 8192 aes192 crypts, 512 bytes, 94468434 byte/sec, 720.7 Mb/sec 0.051 sec, 8192 aes192 crypts, 1024 bytes, 165691080 byte/sec, 1264.1 Mb/sec 0.064 sec, 8192 aes192 crypts, 2048 bytes, 260495552 byte/sec, 1987.4 Mb/sec 0.089 sec, 8192 aes192 crypts, 4096 bytes, 377516618 byte/sec, 2880.2 Mb/sec 0.193 sec, 8192 aes192 crypts, 8192 bytes, 347564850 byte/sec, 2651.7 Mb/sec 0.040 sec, 8192 aes256 crypts, 16 bytes, 3287814 byte/sec, 25.1 Mb/sec 0.040 sec, 8192 aes256 crypts, 32 bytes, 6590341 byte/sec, 50.3 Mb/sec 0.041 sec, 8192 aes256 crypts, 64 bytes, 12766650 byte/sec, 97.4 Mb/sec 0.042 sec, 8192 aes256 crypts, 128 bytes, 24829533 byte/sec, 189.4 Mb/sec 0.045 sec, 8192 aes256 crypts, 256 bytes, 47055107 byte/sec, 359.0 Mb/sec 0.046 sec, 8192 aes256 crypts, 512 bytes, 91267821 byte/sec, 696.3 Mb/sec 0.053 sec, 8192 aes256 crypts, 1024 bytes, 157284434 byte/sec, 1200.0 Mb/sec 0.068 sec, 8192 aes256 crypts, 2048 bytes, 248051570 byte/sec, 1892.5 Mb/sec 0.095 sec, 8192 aes256 crypts, 4096 bytes, 352026186 byte/sec, 2685.7 Mb/sec 0.203 sec, 8192 aes256 crypts, 8192 bytes, 330162669 byte/sec, 2518.9 Mb/sec --=-zavRfSVl9bCRFgRJrlpP--