-
Notifications
You must be signed in to change notification settings - Fork 17.6k
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
runtime: segfaults in cross compiled binaries for solaris 11.3 #61950
Comments
This seems like a failure early in the runtime. Do you have Also, do you have a way to reproduce? Thanks. CC @golang/solaris |
|
For the record, this worked for me.
Can you run the |
Program received signal SIGSEGV, Segmentation fault. |
@karlik8899 I appreciate your engagement and cooperation, but I think to really make progress on this one we need to be able to reproduce it. Just sending instructions and output back and forth is going to be fairly slow. Though, in triage, we're noticing that this seems to be a segfault inside the Does this only happen if you cross-compile? Have you tried building the program on your Solaris machine? Thanks. |
I downloaded go1.21.0.solaris-amd64.tar.gz and ran go gdb go/bin/go Program received signal SIGSEGV, Segmentation fault. I couldn't find an older version of golang for Solaris. |
I don't know if it is related, but I'm facing a similar problem with go version 1.21.0. I'm using Debian 11.7 on x86_64. When I cross compile for windows amd64 and/or linux arm (old raspberry PI), running even a basic 'helloWorld' program on target platform panics with "Illegal instruction". With go version 1.20.7 there is no problem. If you think can be related with Solaris issue let me know if you need more information. Ciao |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?linux centos 8
go env
OutputWhat did you do?
func main() {
fmt.Println("Abcd")
}
env GOOS=solaris GOARCH=amd64 CGO_ENABLED=0 go build -o test-sol-1.21.0
What did you expect to see?
Abcd
What did you see instead?
Segmentation Fault (core dumped)
sotruss ~/test-sol-1.21.0
test-sol-1.21.0 -> libc.so:*sysconf(0xf, 0xffff80ffbffff6a0, 0x42ce0f)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x40000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x20000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x100000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x800000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x4000000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x20000000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x20000000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0xc000000000, 0x4000000, 0x0)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x2000000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x114c10, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xc000000000, 0x400000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xffff80ffbf625000, 0x20000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xffff80ffbe97f000, 0x1000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xffff80ffbde06000, 0x1000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xffff80ffbb830000, 0x1000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xffff80ffa9780000, 0x1000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0xffff80ff89580000, 0x1000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x100000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x10000, 0x3)
test-sol-1.21.0 -> libc.so:*mmap(0x0, 0x10000, 0x3)
test-sol-1.21.0 -> libc.so:*open(0x52d4b0, 0x0, 0x0)
/usr/bin/sotruss: line 78: 277: Memory fault(coredump)
ldd ~/test-sol-1.21.0
libsendfile.so => /lib/64/libsendfile.so
libsocket.so => /lib/64/libsocket.so
libc.so => /lib/64/libc.so
libnsl.so.1 => /lib/64/libnsl.so.1
libmp.so.2 => /lib/64/libmp.so.2
libucrypto.so.1 => /lib/64/libucrypto.so.1
libelf.so.1 => /lib/64/libelf.so.1
libcryptoutil.so.1 => /lib/64/libcryptoutil.so.1
libz.so.1 => /lib/64/libz.so.1
The text was updated successfully, but these errors were encountered: