-
Notifications
You must be signed in to change notification settings - Fork 212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Distribution/installation of the GCC toolchain #55
Comments
I am aware of the "official RISC-V" prebuilt toolchains: https://github.com/riscv/riscv-gnu-toolchain/releases The problem with these toolchains (for example: There are other common ABIs, like a "soft-float" ABI that is currently used by the NEORV32 makefiles. But without DetailsIn theory, there is no big deal using a floating-point ABI even if the targeted core does not support floating point operations. BUT the compiler will emit instructions for spilling the floating point registers inside interrupt service routines. The CPU sees these instructions and - of course - will raise an illegal instruction exception, since there is not according In summary, the executable cannot run. 😭 More detailsThe NEORV32 does support native floating-point operations. The |
I was not specifically thinking about those packages, but about the upstream in system package manager. For instance, the following packages are available on MSYS2: mingw64/mingw-w64-x86_64-riscv64-unknown-elf-binutils 2.35-1 (mingw-w64-x86_64-riscv64-unknown-elf-toolchain)
GNU Tools for RISC-V Embedded Processors - Binutils (mingw-w64)
mingw64/mingw-w64-x86_64-riscv64-unknown-elf-gcc 10.1.0-2 (mingw-w64-x86_64-riscv64-unknown-elf-toolchain)
GNU Tools for RISC-V Embedded Processors - GCC (mingw-w64)
mingw64/mingw-w64-x86_64-riscv64-unknown-elf-newlib 3.3.0-2 (mingw-w64-x86_64-riscv64-unknown-elf-toolchain)
GNU Tools for RISC-V Embedded Processors - Newlib (mingw-w64) Those are riscv64. However, I used
I'm no expert in this area, but @Paebbels created Paebbels/GCC-Toolchains very few days ago, in order to provide alternatives to the built-in toolchains in Vivado. He is currently using manual build procedures, but I guess the plan is to provide those as containers, MSYS2 packages and/or standalone zipfiles. Therefore, it would be interesting to join efforts and cover your use case there. |
The GCC-Toolchains repo is currently a playground to build a useable toolchain, because the Xilinx toolchains are broken as .... Anyhow, I now try to build toolchains for ARMv7 targeting A9 and R5 and ARMv8 for A53. I would like to add RISC-V, PowerPC and MIPS as well, when the general CI pipeline works. In addition to baremetal builds (newlib), I would like to support GNU Linux with glibc as well as e.g. FreeRTOS. In a later stage, we can talk about packaging this and also how to replace compilers in vendor tools. |
I am using Ubuntu on Windows as development environment. However, I will try to check out the RISC-V MSYS2 toolchain this weekend.
I am looking forward to this! 👍 😉 |
@stnolting it was compiled with # riscv64-unknown-elf-gcc -v
Using built-in specs.
COLLECT_GCC=C:\msys64\mingw64\bin\riscv64-unknown-elf-gcc.exe
COLLECT_LTO_WRAPPER=c:/msys64/mingw64/bin/../lib/gcc/riscv64-unknown-elf/10.1.0/lto-wrapper.exe
Target: riscv64-unknown-elf
Configured with: ../configure --build=x86_64-w64-mingw32 --host=x86_64-w64-mingw32 --prefix=/mingw64 --target=riscv64-unknown-elf --with-native-system-header-dir=/mingw64/x86_64-w64-mingw32/include --libexecdir=/mingw64/lib --enable-languages=c,c++,ada --enable-plugins --disable-decimal-float --disable-libffi --disable-libgomp --disable-libmudflap --disable-libquadmath --disable-libssp --disable-libstdcxx-pch --disable-nls --disable-shared --disable-threads --disable-tls --disable-libada --with-gnu-as --with-gnu-ld --with-system-zlib --with-newlib --with-headers=/mingw64/riscv64-unknown-elf/include --with-python-dir=share/gcc-riscv64-unknown-elf --with-gmp --with-mpfr --with-mpc --with-isl --with-libelf --enable-gnu-indirect_function --enable-multilib --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --enable-linker-plugin-flags='LDFLAGS=-static-libstdc++\ -static-libgcc\ -pipe\ -Wl,--dynamicbase,--high-entropy-va,--nxcompat,--default-image-base-high\ -Wl,--stack,12582912' LDFLAGS='-pipe -Wl,--dynamicbase,--high-entropy-va,--nxcompat,--default-image-base-high -Wl,--disable-dynamicbase,--image-base=0x400000'
Thread model: single
Supported LTO compression algorithms: zlib zstd
gcc version 10.1.0 (GCC) So, we should update the docs (user guide) to let Windows users know that they can install |
Absolutely! |
Agree. However, don't write that yet 😉
Hence, rather than repeat the explanations here, better refer to the corresponding documentation and to working CI examples in this repo. As soon as im-tomu/fomu-workshop#487 is merged, three of those solutions will be covered. We can then see how to reuse/cross-reference. Overall, explaining how to install and use EDA tooling is not the purpose of this repository. Some guidelines need to be provided, but the less the best. Enough for it to be easy to follow for newcomers. |
Coming from #54
The text was updated successfully, but these errors were encountered: