You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using zstd on Risc-V machines. I noticed that zstd_trace is disabled on Risc-V. After some investigating, I found this was because the zstd's weak symbol support was conservatively disabled on Risc-V.
However, as far as I know, Risc-V supports weak symbols, and the weak attribute can be used on Risc-V’s GCC.
So, will you consider enabling weak symbol support for Risc-V?
I guess adding a defined (__riscv) in the following code will make it work.
// lib/common/zstd_trace.h/* weak symbol support * For now, enable conservatively: * - Only GNUC * - Only ELF * - Only x86-64, i386 and aarch64 * Also, explicitly disable on platforms known not to work so they aren't * forgotten in the future. */#if !defined(ZSTD_HAVE_WEAK_SYMBOLS) && \
defined(__GNUC__) && defined(__ELF__) && \
(defined(__x86_64__) || defined(_M_X64) || defined(__i386__) || defined(_M_IX86) || defined(__aarch64__)) && \
!defined(__APPLE__) && !defined(_WIN32) && !defined(__MINGW32__) && \
!defined(__CYGWIN__) && !defined(_AIX)
# defineZSTD_HAVE_WEAK_SYMBOLS 1
#else# defineZSTD_HAVE_WEAK_SYMBOLS 0
#endif#ifZSTD_HAVE_WEAK_SYMBOLS# defineZSTD_WEAK_ATTR __attribute__((__weak__))
#else# defineZSTD_WEAK_ATTR#endif
The text was updated successfully, but these errors were encountered:
I am using zstd on Risc-V machines. I noticed that zstd_trace is disabled on Risc-V. After some investigating, I found this was because the zstd's weak symbol support was conservatively disabled on Risc-V.
However, as far as I know, Risc-V supports weak symbols, and the
weak
attribute can be used on Risc-V’s GCC.So, will you consider enabling weak symbol support for Risc-V?
I guess adding a
defined (__riscv)
in the following code will make it work.The text was updated successfully, but these errors were encountered: