mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-09 17:00:13 +01:00
util/blake3: Patch with hidden visibility for asm symbols.
For Unix platforms, the symbol visibility needs to be hidden to avoid exposing them in driver shared objects. Acked-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22387>
This commit is contained in:
parent
77826e8352
commit
0e30076d83
6 changed files with 37 additions and 1 deletions
|
|
@ -11,4 +11,6 @@ Changes:
|
|||
|
||||
- Add non-typedef struct name to blake3_hasher.
|
||||
|
||||
- Add "static" to blake3_hash4_neon, to comply with -Werror=missing-prototypes.
|
||||
- Add "static" to blake3_hash4_neon, to comply with -Werror=missing-prototypes.
|
||||
|
||||
- Add mesa_blake3_visibility.h and set symbol visibility to hidden for assembly sources.
|
||||
|
|
@ -1,3 +1,5 @@
|
|||
#include "mesa_blake3_visibility.h"
|
||||
|
||||
#if defined(__ELF__) && defined(__linux__)
|
||||
.section .note.GNU-stack,"",%progbits
|
||||
#endif
|
||||
|
|
@ -13,6 +15,9 @@
|
|||
#endif
|
||||
|
||||
.intel_syntax noprefix
|
||||
|
||||
HIDDEN _blake3_hash_many_avx2
|
||||
HIDDEN blake3_hash_many_avx2
|
||||
.global _blake3_hash_many_avx2
|
||||
.global blake3_hash_many_avx2
|
||||
#ifdef __APPLE__
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
#include "mesa_blake3_visibility.h"
|
||||
|
||||
#if defined(__ELF__) && defined(__linux__)
|
||||
.section .note.GNU-stack,"",%progbits
|
||||
#endif
|
||||
|
|
@ -13,6 +15,12 @@
|
|||
#endif
|
||||
|
||||
.intel_syntax noprefix
|
||||
HIDDEN _blake3_hash_many_avx512
|
||||
HIDDEN blake3_hash_many_avx512
|
||||
HIDDEN blake3_compress_in_place_avx512
|
||||
HIDDEN _blake3_compress_in_place_avx512
|
||||
HIDDEN blake3_compress_xof_avx512
|
||||
HIDDEN _blake3_compress_xof_avx512
|
||||
.global _blake3_hash_many_avx512
|
||||
.global blake3_hash_many_avx512
|
||||
.global blake3_compress_in_place_avx512
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
#include "mesa_blake3_visibility.h"
|
||||
|
||||
#if defined(__ELF__) && defined(__linux__)
|
||||
.section .note.GNU-stack,"",%progbits
|
||||
#endif
|
||||
|
|
@ -13,6 +15,12 @@
|
|||
#endif
|
||||
|
||||
.intel_syntax noprefix
|
||||
HIDDEN blake3_hash_many_sse2
|
||||
HIDDEN _blake3_hash_many_sse2
|
||||
HIDDEN blake3_compress_in_place_sse2
|
||||
HIDDEN _blake3_compress_in_place_sse2
|
||||
HIDDEN blake3_compress_xof_sse2
|
||||
HIDDEN _blake3_compress_xof_sse2
|
||||
.global blake3_hash_many_sse2
|
||||
.global _blake3_hash_many_sse2
|
||||
.global blake3_compress_in_place_sse2
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
#include "mesa_blake3_visibility.h"
|
||||
|
||||
#if defined(__ELF__) && defined(__linux__)
|
||||
.section .note.GNU-stack,"",%progbits
|
||||
#endif
|
||||
|
|
@ -13,6 +15,12 @@
|
|||
#endif
|
||||
|
||||
.intel_syntax noprefix
|
||||
HIDDEN blake3_hash_many_sse41
|
||||
HIDDEN _blake3_hash_many_sse41
|
||||
HIDDEN blake3_compress_in_place_sse41
|
||||
HIDDEN _blake3_compress_in_place_sse41
|
||||
HIDDEN blake3_compress_xof_sse41
|
||||
HIDDEN _blake3_compress_xof_sse41
|
||||
.global blake3_hash_many_sse41
|
||||
.global _blake3_hash_many_sse41
|
||||
.global blake3_compress_in_place_sse41
|
||||
|
|
|
|||
5
src/util/blake3/mesa_blake3_visibility.h
Normal file
5
src/util/blake3/mesa_blake3_visibility.h
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
#ifdef __APPLE__
|
||||
#define HIDDEN .private_extern
|
||||
#else
|
||||
#define HIDDEN .hidden
|
||||
#endif
|
||||
Loading…
Add table
Reference in a new issue