|
| 1 | +From adc7e06fb412a2a1ee52f8cb788caf436335b9f3 Mon Sep 17 00:00:00 2001 |
| 2 | +From: Florian Weimer <fweimer@redhat.com> |
| 3 | +Date: Wed, 14 Jun 2017 08:11:22 +0200 |
| 4 | +Subject: [PATCH] i686: Add missing IS_IN (libc) guards to vectorized strcspn |
| 5 | + |
| 6 | +Since commit d957c4d3fa48d685ff2726c605c988127ef99395 (i386: Compile |
| 7 | +rtld-*.os with -mno-sse -mno-mmx -mfpmath=387), vector intrinsics can |
| 8 | +no longer be used in ld.so, even if the compiled code never makes it |
| 9 | +into the final ld.so link. This commit adds the missing IS_IN (libc) |
| 10 | +guard to the SSE 4.2 strcspn implementation, so that it can be used from |
| 11 | +ld.so in the future. |
| 12 | + |
| 13 | +(cherry picked from commit 69052a3a95da37169a08f9e59b2cc1808312753c) |
| 14 | +--- |
| 15 | + ChangeLog | 5 +++++ |
| 16 | + sysdeps/i386/i686/multiarch/strcspn-c.c | 6 ++++-- |
| 17 | + sysdeps/i386/i686/multiarch/varshift.c | 4 +++- |
| 18 | + 3 files changed, 12 insertions(+), 3 deletions(-) |
| 19 | + |
| 20 | +diff --git a/sysdeps/i386/i686/multiarch/strcspn-c.c b/sysdeps/i386/i686/multiarch/strcspn-c.c |
| 21 | +index 6d61e19..ec230fb 100644 |
| 22 | +--- a/sysdeps/i386/i686/multiarch/strcspn-c.c |
| 23 | ++++ b/sysdeps/i386/i686/multiarch/strcspn-c.c |
| 24 | +@@ -1,2 +1,4 @@ |
| 25 | +-#define __strcspn_sse2 __strcspn_ia32 |
| 26 | +-#include <sysdeps/x86_64/multiarch/strcspn-c.c> |
| 27 | ++#if IS_IN (libc) |
| 28 | ++# define __strcspn_sse2 __strcspn_ia32 |
| 29 | ++# include <sysdeps/x86_64/multiarch/strcspn-c.c> |
| 30 | ++#endif |
| 31 | +diff --git a/sysdeps/i386/i686/multiarch/varshift.c b/sysdeps/i386/i686/multiarch/varshift.c |
| 32 | +index 7760b96..6742a35 100644 |
| 33 | +--- a/sysdeps/i386/i686/multiarch/varshift.c |
| 34 | ++++ b/sysdeps/i386/i686/multiarch/varshift.c |
| 35 | +@@ -1 +1,3 @@ |
| 36 | +-#include <sysdeps/x86_64/multiarch/varshift.c> |
| 37 | ++#if IS_IN (libc) |
| 38 | ++# include <sysdeps/x86_64/multiarch/varshift.c> |
| 39 | ++#endif |
| 40 | +-- |
| 41 | +2.9.3 |
| 42 | + |
0 commit comments