mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-05 12:38:09 -07:00
dev-libs/libgcrypt: Add fix for SSSE3 problems on Nehalem
Package-Manager: Portage-2.3.3, Repoman-2.3.1
This commit is contained in:
41
dev-libs/libgcrypt/files/libgcrypt-1.7.5-fix-nehalem.patch
Normal file
41
dev-libs/libgcrypt/files/libgcrypt-1.7.5-fix-nehalem.patch
Normal file
@@ -0,0 +1,41 @@
|
||||
From aada604594fd42224d366d3cb98f67fd3b989cd6 Mon Sep 17 00:00:00 2001
|
||||
From: Jussi Kivilinna <jussi.kivilinna@iki.fi>
|
||||
Date: Wed, 4 Jan 2017 12:02:36 +0200
|
||||
Subject: [PATCH 1/1] rijndael-ssse3: fix counter operand from read-only to
|
||||
read/write
|
||||
|
||||
* cipher/rijndael-ssse3-amd64.c (_gcry_aes_ssse3_ctr_enc): Change
|
||||
'ctrlow' operand from read-only to read-write.
|
||||
--
|
||||
|
||||
With read-only operand, compiler is allowed to pass temporary
|
||||
register to assembly block and throw away any calculation that
|
||||
have been done on that register. On the other hand, compiler is
|
||||
also allowed to keep operand value permanently in one register
|
||||
as value is treated as read-only, and effectly operates as
|
||||
expected. Selection between these two depends on compiler
|
||||
version and used flags.
|
||||
|
||||
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
|
||||
---
|
||||
cipher/rijndael-ssse3-amd64.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/cipher/rijndael-ssse3-amd64.c b/cipher/rijndael-ssse3-amd64.c
|
||||
index a8e89d4..2adb73f 100644
|
||||
--- a/cipher/rijndael-ssse3-amd64.c
|
||||
+++ b/cipher/rijndael-ssse3-amd64.c
|
||||
@@ -387,8 +387,8 @@ _gcry_aes_ssse3_ctr_enc (RIJNDAEL_context *ctx, unsigned char *outbuf,
|
||||
".Lno_carry%=:\n\t"
|
||||
|
||||
"pshufb %%xmm6, %%xmm7\n\t"
|
||||
- :
|
||||
- : [ctr] "r" (ctr), [ctrlow] "r" (ctrlow)
|
||||
+ : [ctrlow] "+r" (ctrlow)
|
||||
+ : [ctr] "r" (ctr)
|
||||
: "cc", "memory");
|
||||
|
||||
do_vpaes_ssse3_enc (ctx, nrounds, aes_const_ptr);
|
||||
--
|
||||
2.8.0.rc3
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 1999-2016 Gentoo Foundation
|
||||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
@@ -30,6 +30,7 @@ DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-1.6.1-uscore.patch
|
||||
"${FILESDIR}"/${PN}-multilib-syspath.patch
|
||||
"${FILESDIR}"/${P}-fix-nehalem.patch
|
||||
)
|
||||
|
||||
MULTILIB_CHOST_TOOLS=(
|
||||
Reference in New Issue
Block a user