From owner-freebsd-questions@freebsd.org Mon Nov 23 17:48:37 2015 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 907A2A32D4B for ; Mon, 23 Nov 2015 17:48:37 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: from mail-wm0-x22a.google.com (mail-wm0-x22a.google.com [IPv6:2a00:1450:400c:c09::22a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2BAF318CE for ; Mon, 23 Nov 2015 17:48:37 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: by wmww144 with SMTP id w144so115257823wmw.0 for ; Mon, 23 Nov 2015 09:48:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=date:from:to:subject:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; bh=hMYZ/avwv3kpmOJ7DymmUKzmw1zvg7VdmN41sPIIZyo=; b=tIwVhIUR08h6zNjLttzDVOrVjKwCl8nZghkf82drlRl0sx3hAwf1ZynDasUbDIfs8I OZTNQQdT2ab62dXQtcpYShw+JIkOPpa5aodHcCYqxtfwQPSDN6/w8ae0JWEa6ZQoWpRY QSxLLNvStzck4Mj4Ev8rl8IyOzNOJvBKWbVuaUc0NxrzEG1dWZWRpLugLQsevJtnUWj5 IoAo2dNDNPBfJLjQ01Md49AipRBfoby0He02H9WqmY85hSjao2WoJBzR0tMF5xACM+is Nj6OkMCAUU67gbsdNSOR386HhpiUg+Kee2H9wuTvdN3ewaHkfAIFcTJTdqesjfjGeyZc gZvQ== X-Received: by 10.28.222.4 with SMTP id v4mr18793646wmg.67.1448300915580; Mon, 23 Nov 2015 09:48:35 -0800 (PST) Received: from gumby.homeunix.com ([94.8.70.38]) by smtp.gmail.com with ESMTPSA id an7sm14323784wjc.44.2015.11.23.09.48.34 for (version=TLSv1/SSLv3 cipher=OTHER); Mon, 23 Nov 2015 09:48:35 -0800 (PST) Date: Mon, 23 Nov 2015 17:48:33 +0000 From: RW To: freebsd-questions@freebsd.org Subject: Re: cryptodev HW (aesni) vs software Message-ID: <20151123174833.0e36619c@gumby.homeunix.com> In-Reply-To: <20151123145326.63d3203b@nonamehost.local> References: <20151120200325.2baade9c@nonamehost.local> <20151120192920.119bbf91@gumby.homeunix.com> <20151122130329.6ea9b9c6@nonamehost.local> <86lh9qhtuw.fsf@WorkBox.Home> <20151123145326.63d3203b@nonamehost.local> X-Mailer: Claws Mail 3.13.0 (GTK+ 2.24.28; amd64-portbld-freebsd10.2) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Nov 2015 17:48:37 -0000 On Mon, 23 Nov 2015 14:53:26 +0200 Ivan Klymenko wrote: > On Sun, 22 Nov 2015 10:38:47 -0600 > Brandon J. Wandersee wrote: > > > Ivan Klymenko writes: > > > > > I hope the problem has now become more visible? > > > > No. State what you believe the "problem" to be. We need to know how > > what actually happened is different from what you expected to > > happen. > > Problem 1 > At two loaded modules cryptodev and aesni to encrypt selected slower cryptodev is known to be slower than userland acceleration. > Problem 2 > Without any loaded modules cryptodev and aesni encryption occurs at > the same rate as in the loaded module aesni - which suggests that > hardware encryption is absolutely not working. If I'm understanding you correctly, it's also consistent with both cases using userland acceleration. The aesni kernel module provides AES-NI support for crypto/cryptodev in the kernel, not in userland. > Problem 3 > In the best case FreeBSD inferior Linux in encryption by as much as > 23% at exactly the same hardware I think hardware would be more than 23% faster than software.