pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: rust - volunteers sought...



Following up on the aarch64 problem with rust:

> aarch64: this is perhaps more worrying, since this one "is
> supposed to work", is "a current platform" and isn't so resource-
> constrained as armv6 or armv7.  This one reports a stack
> overflow in our case:
>
> thread 'rustc' has overflowed its stack
> fatal runtime error: stack overflow
>
> after around 33 hours wallclock time building on my virtual 4-CPU
> arm64 qemu instance (with MAKE_JOBS?=3), building with the
> bundled LLVM, during the "stage 2" build.
>
> This is reported upstream as
> https://github.com/rust-lang/rust/issues/123551
> but so far it appears nobody else is seeing a similar failure.

What I've done is that I've done a succession of bumping the
maximum stack size in the kernel, from 2x, via 4x, 8x and now to
16x -- from the cvs diff of the GENERIC64 kernel config:

+# Bump max stack size by 16x:
+# default is 1L<<26, ref aarch64/include/vmparam.h
+options                MAXSSIZ="(1L<<30)"
+

and tcsh now shows:

arm64: {15} tcsh
arm64: {1} limit | grep stack
stacksize    8192 kbytes
arm64: {2} unlimit stacksize
arm64: {3} limit | grep stack
stacksize    458752 kbytes
arm64: {4}

However, this to no avail, re-starting the previously failed rust
build of 1.77.2 (from wip/rust177) still crashes with

     Running `/usr/pkgsrc/wip/rust177/work/rustc-1.77.2-src/build/bootstrap/debug/rustc /usr/pkgsrc/wip/rust177/work/rustc-1.77.2-src/build/bootstrap/debug/rust

thread 'rustc' has overflowed its stack
fatal runtime error: stack overflow

rustc exited with signal: 6 (SIGABRT) (core dumped)
Did not run successfully: signal: 6 (SIGABRT) (core dumped)
LD_LIBRARY_PATH="/usr/pkgsrc/wip/rust177/work/rustc-1.77.2-src/build/aarch64-unknown-netbsd/stage1/lib:/usr/pkgsrc/wip/rust177/work/rustc-1.77.2-src/build/aarch
-------------
error: could not compile `rustc_query_system` (lib)

This makes me wonder if the rust compiler detection of stack
overflow is faulty, and that this isn't in fact the problem.
I find it incredible that it actually overflows a 458MB stack.

The package Makefile already has

UNLIMIT_RESOURCES+=     cputime stacksize datasize virtualsize

However, I don't consider myself sufficiently competent to drive
gdb to decide this hunch, and would appreciate some assistance on
this point.

Regards,

- Håvard


Home | Main Index | Thread Index | Old Index