The software that ships with the HiFive Unleashed is built from github.com/sifive/freedom-u-sdk from the legacy v1_0 branch. This is old software, pre-upstream glibc, kernel, buildroot, old binutils and gcc versions. Etc. You can get a cross toolchain if you check this out and build it. You will need to use this toolchain if you want to compile code that runs on the system as shipped. However, what you have is not a very useful system, as it is a minimal buildroot environment built from mostly pre-upstream sources. You can make it more useful by putting a real distro in the second sdcard partition and chrooting to it. If you use this toolchain, programs compiled with it won’t run on Fedora/Debian/OpenSuse/OpenEmbedded or any useful OS installed on the system. Well, they might if you static link and it is simple enough. But basically what you have now is not really a very useful system, and you should replace it with something useful if you want to do useful work on it. Once you get a useful system on the board you should use the compiler that come with that system and build natively. Note that the current github.com/sifive/freedom-u-sdk master branch can be used to get a much better system running on the board, using mostly upstream sources, and offers a debian rootfs, but it is rather different than what you have now, and you should not expect user binaries that run on the legacy v1_0 system to work on the current system. This also gets you a cross compiler you can use.
If you still want a cross compiler, and are using Debian/Fedora/etc, then I would suggest getting your system of choice running on the board, and then extract a sysroot from it (/usr/include, /usr/lib, /lib, etc) and use the sysroot to build a cross compiler. Different systems may have different glibc versions, and different glibc configurations, so this works best if you build a cross compiler using the target glibc via a sysroot.