!xmLtiCaAJxfhURjrXl:matrix.org

NixOS RISC-V

240 Members
NixOS on RISC-V https://wiki.nixos.org/wiki/RISC-V https://pad.lassul.us/NixOS-riscv64-linux 73 Servers

Load older messages


SenderMessageTime
19 Mar 2026
@alex:tunstall.xyzAlexYes, I ran into that issue myself a few weeks ago while doing binfmt emulation of aarch64.20:18:01
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)I guess it should be pretty easy to fix by just calling uname and using the appropriate arch for setting up seccomp?20:23:35
@alex:tunstall.xyzAlex

colemickens good news:

alex@alex-pc3 ~/r/O/n/ghc-cross-2 (ghc-cross-hadrian)> /nix/store/7kjpbn6fv6gqi9fx65ann5bqdsm3s9fi-riscv64-unknown-linux-gnu-ghc-9.10.3/bin/riscv64-unknown-linux-gnu-ghc --info | grep platform
 ,("target platform string","riscv64-unknown-linux")
 ,("Build platform","x86_64-unknown-linux")
 ,("Host platform","x86_64-unknown-linux")
 ,("Target platform","riscv64-unknown-linux")

I'm still double checking that the cross-compiler works, but I expect to PR the fix to Nixpkgs soon enough.

21:35:58
@alex:tunstall.xyzAlex

This alone is not enough to cross-compile cachix:

---> Starting interpreter on port 6072
Listening on port 6072
iserv-proxy-interpreter: tmp/nix/store/7kjpbn6fv6gqi9fx65ann5bqdsm3s9fi-riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-linux-ghc-9.10.3/ghc-prim-0.12.0-561f/libHSghc-prim-0.12.0-561f.a: RTS linker not implemented on riscv
iserv-proxy-interpreter: loadArchive "tmp/nix/store/7kjpbn6fv6gqi9fx65ann5bqdsm3s9fi-riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-linux-ghc-9.10.3/ghc-prim-0.12.0-561f/libHSghc-prim-0.12.0-561f.a": failed

iserv-proxy: <socket: 17>: hGetBufSome: resource vanished (Connection reset by peer)
HasCallStack backtrace:
  collectBacktraces, called at libraries/ghc-internal/src/GHC/Internal/Exception.hs:169:13 in ghc-internal:GHC.Internal.Exception
  toExceptionWithBacktrace, called at libraries/ghc-internal/src/GHC/Internal/IO.hs:260:11 in ghc-internal:GHC.Internal.IO
  throwIO, called at libraries/ghc-internal/src/GHC/Internal/IO/Exception.hs:315:19 in ghc-internal:GHC.Internal.IO.Exception
  ioException, called at libraries/ghc-internal/src/GHC/Internal/IO/Exception.hs:319:20 in ghc-internal:GHC.Internal.IO.Exception


/nix/store/vw5aaxwm2fppx1xarn7k41db5yr3rvww-iserv-wrapper-both/bin/iserv-wrapper: line 1: kill: (499) - No such process
<no location info>: error: External interpreter terminated (1)
21:43:39
@alex:tunstall.xyzAlex colemickens https://github.com/NixOS/nixpkgs/pull/501439 22:00:19
20 Mar 2026
@silvio:booq.org@silvio:booq.org left the room.09:01:21
24 Mar 2026
@theo-paris:matrix.org@theo-paris:matrix.org left the room.04:05:49
28 Mar 2026
@colemickens:matrix.orgcolemickensI'm sort of a riscv noob, especially with regards to the ... revisions? Is TH1520 too old to use to build in nixpkgs?22:54:04
29 Mar 2026
@alex:tunstall.xyzAlexThat seems to be RV64GC (with an old(?) version of RVV?) so unless you're deliberately targeting a higher profile like RVA23, it should be OK.01:58:44
@dramforever:matrix.orgdramforeverth1520 should be fine03:41:26
@faukah:faukah.comfaukah left the room.18:11:58
@colemickens:matrix.orgcolemickensI have no idea what I was doing last night. I rebooted my builders and went back to a newer nixos-unstable and now thing seem to be building mostly fine. Really bizarre, but I was up late, maybe I was more tired than I thought.18:44:16
@alex:tunstall.xyzAlex

I've been stuck for a few days on a problem with linking clangd-fuzzer getting OoM killed right at the end of buildPhase 18 hours into the clang build. Even -j1 isn't enough.
I tried useMoldLinker, but that's broken right now (due to something not putting NIX_CFLAGS_LINK under env?).
Then I tried updating the system again, but now useMoldLinker causes eval to overflow the stack.

Has anyone found a reasonable solution to building clang (LLVM 20 and 21) without needing ludicrous amounts of memory?
If push comes to shove I could perhaps suffer a larger swap file...

18:51:51
@alex:tunstall.xyzAlex

For reference:

[nixos@nixos:~/system]$ free -h
               total        used        free      shared  buff/cache   available
Mem:           7.7Gi       6.0Gi       105Mi          0B       1.6Gi       1.5Gi
Swap:           15Gi       152Mi        15Gi

(There is high memory usage right now because it's in the middle of retrying clang.)

18:53:30
30 Mar 2026
@jammie:matrix.orgJamieMageeI found an issue with nixpkgs configuration of gdb, which doesn't match upstream configuration. Specifically, gdb doesn't support in-process agent on risc-v: https://github.com/NixOS/nixpkgs/pull/50487203:41:58
@misuzu:matrix.orgmisuzuTry --cores 107:14:37
@alex:tunstall.xyzAlex

I had a build almost ending already, and this is what the RSS looked like just within 10s of the OoM kill:

436704 bin/c-index-test
4203668 bin/clang-tidy
2798596 bin/clangd-fuzzer

So yeah I think --cores 1 is worth a try, though it'll probably take over 2 days to build a single clang version (and I need 2). 🫠

10:16:04
@alex:tunstall.xyzAlexI have figured out a way to get LLVM linked with mold to evaluate (I think?) so I think I'll try that first.10:17:01
@misuzu:matrix.orgmisuzuhttps://riseproject.dev/2026/03/24/announcing-the-rise-risc-v-runners-free-native-risc-v-ci-on-github/16:21:14
@rosscomputerguy:matrix.orgTristan RossWhen I was doing stuff with the VF2, I had to compile LLVM on 1 core. That took like 3 days to build.16:42:12
18 Aug 2023
@shados:nixos.devShados joined the room.05:42:58
@misuzu:matrix.orgmisuzu
% cat /proc/mtd                            
dev:    size   erasesize  name
mtd0: 00080000 00001000 "spl"
mtd1: 00010000 00001000 "uboot-env"
mtd2: 00400000 00001000 "uboot"
mtd3: 00a00000 00001000 "reserved-data"

Looks like the visionfive2_fw_payload.img should be flashed to /dev/mtd2 instead of /dev/mtd1

08:29:39
20 Aug 2023
@erremilia:matrix.orgerremilia joined the room.17:53:34
@claesatwork:matrix.orgClaes joined the room.19:27:07
24 Aug 2023
@erremilia:matrix.orgerremilia1000004363.jpg
Download 1000004363.jpg
19:36:55
@erremilia:matrix.orgerremiliaThis should be fun to play with19:37:02
@hive:the-apothecary.clubtauphioooh nice19:38:17
@hive:the-apothecary.clubtauphisame chip as starfive v2 iirc so it should be somewhat easy to use19:38:37
@erremilia:matrix.orgerremiliaSounds good! Me and my SO mostly got it to play with and just see some Risc-V stuff but it'd be awesome if it turns out to be useful.19:39:52
@raitobezarius:matrix.orgraitobezariuslet us know how it goes19:40:12

Show newer messages


Back to Room ListRoom Version: 10