Re: svn commit: r317144 - head/contrib/zstd/lib/common

2017-04-19 Thread John Baldwin
On Wednesday, April 19, 2017 03:24:34 PM Ruslan Bukin wrote:
> Author: br
> Date: Wed Apr 19 15:24:33 2017
> New Revision: 317144
> URL: https://svnweb.freebsd.org/changeset/base/317144
> 
> Log:
>   Don't use __builtin_bswap for RISC-V due to undefined reference
>   in compiler.
>   
>   This unbreaks RISC-V world build.
>   
>   Sponsored by:   DARPA, AFRL

We should probably add an implementation of __bswapdi2() for riscv to
libcompiler_rt instead?

-- 
John Baldwin
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r317144 - head/contrib/zstd/lib/common

2017-04-19 Thread Ruslan Bukin
Author: br
Date: Wed Apr 19 15:24:33 2017
New Revision: 317144
URL: https://svnweb.freebsd.org/changeset/base/317144

Log:
  Don't use __builtin_bswap for RISC-V due to undefined reference
  in compiler.
  
  This unbreaks RISC-V world build.
  
  Sponsored by: DARPA, AFRL

Modified:
  head/contrib/zstd/lib/common/xxhash.c

Modified: head/contrib/zstd/lib/common/xxhash.c
==
--- head/contrib/zstd/lib/common/xxhash.c   Wed Apr 19 15:04:52 2017
(r317143)
+++ head/contrib/zstd/lib/common/xxhash.c   Wed Apr 19 15:24:33 2017
(r317144)
@@ -206,7 +206,7 @@ static U64 XXH_read64(const void* memPtr
 #if defined(_MSC_VER) /* Visual Studio */
 #  define XXH_swap32 _byteswap_ulong
 #  define XXH_swap64 _byteswap_uint64
-#elif GCC_VERSION >= 403
+#elif (GCC_VERSION >= 403 && !defined(__riscv__))
 #  define XXH_swap32 __builtin_bswap32
 #  define XXH_swap64 __builtin_bswap64
 #else
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"