Issue 1:
by rounin.urashima:

./hello displays Illegal instruction using hg update default on ARM CPU based CISCO
Linksys NSLU2

Before filing a bug, please check whether it has been fixed since the
latest release. Search the issue tracker and check that you're running the
latest version of Go:

Run "go version" and compare against
http://golang.org/doc/devel/release.html If a newer version of Go exists,
install it and retry what you did to reproduce the problem.

Thanks.

What steps will reproduce the problem?
If possible, include a link to a program on play.golang.org.

rounin@LKG80B859:~$ cat hello.go
package main

func main() {
print("hello, world\n");
}
rounin@LKG80B859:~$ env|grep ARM
GOARM=5

rounin@LKG80B859:~$ go run hello.go
signal 4
rounin@LKG80B859:~$ go build hello.go
rounin@LKG80B859:~$ ./hello
Illegal instruction

What is the expected output?
hello, world

What do you see instead?
Illegal instruction

Which compiler are you using (5g, 6g, 8g, gccgo)?
go build

Which operating system are you using?

uname -a
Linux LKG80B859 2.6.32-5-ixp4xx #1 Sun May 6 12:28:42 UTC 2012 armv5tel GNU/Linux

cat /proc/cpuinfo
Processor : XScale-IXP42x Family rev 1 (v5l)
BogoMIPS : 266.24
Features : swp half thumb fastmult edsp
CPU implementer : 0x69
CPU architecture: 5TE
CPU variant : 0x0
CPU part : 0x41f
CPU revision : 1

Hardware : Linksys NSLU2
Revision : 0000
Serial : 0000000000000000

cat /proc/cpu/alignment
User: 16
System: 0
Skipped: 0
Half: 0
Word: 0
DWord: 0
Multi: 0
User faults: 0 (ignored)

rounin@LKG80B859:~$ cat /etc/issue
Debian GNU/Linux 6.0 \n \l

Which version are you using? (run 'go version')
go version
go version weekly.2012-03-27 +820ffde8c396

Did a:

hg update default

before this it was

2ccfd4b451d3 (release-branch.go1) go1.0.1/release

With version go1.0.1/release system exhibits:

This program can only be run on EABI kernels

Please provide any additional information below.

rounin@LKG80B859:~$ strace -f ./hello
execve("./hello", ["./hello"], [/* 24 vars */]) = 0
rt_sigaction(SIGILL, {0x237fc, [RT_1], 0}, {SIG_DFL, [], 0}, 8) = 0
getpid() = 10347
rt_sigaction(SIGILL, {SIG_DFL, [], 0}, NULL, 8) = 0
--- SIGILL (Illegal instruction) @ 0 (0) ---
+++ killed by SIGILL +++
Illegal instruction

GOARM was set to 5
rounin@LKG80B859:~$ env|grep ARM
GOARM=5

Script started on Fri 18 May 2012 23:07:37 BST
rounin@LKG80B859:~$ env|grep ARM
GOESC[01;31mESC[KARMESC[mESC[K=5
rounin@LKG80B859:~$ cd go/src
rounin@LKG80B859:~/go/src$ ./all.bash
# Building C bootstrap tool.
cmd/dist
^C
rounin@LKG80B859:~/go/src$ time ./all.bash
# Building C bootstrap tool.
cmd/dist

# Building compilers and Go bootstrap tool for host, linux/arm.
lib9
libbio
libmach
.
.
.
.
net/http/httptest
net/http/httputil
net/mail
net/rpc
net/rpc/jsonrpc
net/smtp
old/netchan
os/signal
os/user
testing
testing/iotest
testing/quick

# Testing packages.
sfloat2 0x71924 0x159fb010
Unsupported floating point instruction
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x0 pc=0x7624c]

goroutine 3 [running]:
created by main.(*builder).do
/home/rounin/go/src/cmd/go/build.go:608 +0x53c

goroutine 1 [chan receive]:
main.(*builder).do(0x109a33c0, 0x10e838c0, 0x10963b40)
/home/rounin/go/src/cmd/go/build.go:611 +0x568
main.runTest(0x456fd8, 0x109513d0, 0x3)
/home/rounin/go/src/cmd/go/test.go:367 +0x24b8
main.main()
/home/rounin/go/src/cmd/go/main.go:141 +0x5c8

goroutine 2 [syscall]:
created by runtime.main
/home/rounin/go/src/pkg/runtime/proc.c:221

goroutine 9 [finalizer wait]:
created by runtime.gc
/home/rounin/go/src/pkg/runtime/mgc0.c:922

goroutine 11 [syscall]:
created by addtimer
/home/rounin/go/src/pkg/runtime/ztime_linux_arm.c:69

real 235m2.002s
user 52m9.280s
sys 15m18.940s
rounin@LKG80B859:~/go/src$
rounin@LKG80B859:~/go/src$ ^MESC[Krounin@LKG80B859:~/go/src$ exit
exit

Script done on Sat 19 May 2012 07:50:27 BST

rounin@LKG80B859:~$ gdb ./hello
GNU gdb (GDB) 7.0.1-debian
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>;
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabi".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>;...
Reading symbols from /home/rounin/hello...(no debugging symbols found)...done.
(gdb) run
Starting program: /home/rounin/hello

Program received signal SIGILL, Illegal instruction.
0x0001d744 in runtime.check ()
(gdb) x/i 0x0001d744
0x1d744 <runtime.check+184>: vldr d0, [sp, #36] ; 0x24
(gdb) info registers
r0 0x0 0
r1 0xbe859278 3196424824
r2 0xffffffff 4294967295
r3 0x4 4
r4 0x35 53
r5 0x0 0
r6 0x0 0
r7 0xae 174
r8 0x0 0
r9 0x36314 221972
r10 0x36100 221440
r11 0x35ff0 221168
r12 0xcafebabe 3405691582
sp 0xbe859254 0xbe859254
lr 0x23c14 146452
pc 0x1d744 0x1d744 <runtime.check+184>
fps 0x1001000 16781312
cpsr 0x60000010 1610612752
(gdb) x/10i $pc
0x1d744 <runtime.check+184>: vldr d0, [sp, #36] ; 0x24
0x1d748 <runtime.check+188>: vldr d1, [sp, #36] ; 0x24
0x1d74c <runtime.check+192>: vcmpe.f64 d0, d1
0x1d750 <runtime.check+196>: vmrs APSR_nzcv, fpscr
0x1d754 <runtime.check+200>: ldreq r1, [pc, #264] ; 0x1d864
<runtime.check+472>
0x1d758 <runtime.check+204>: streq r1, [sp, #4]
0x1d75c <runtime.check+208>: bleq 0x1cee0 <runtime.throw>
0x1d760 <runtime.check+212>: vldr d0, [sp, #36] ; 0x24
0x1d764 <runtime.check+216>: vldr d1, [sp, #36] ; 0x24
0x1d768 <runtime.check+220>: vcmpe.f64 d0, d1
(gdb) bt
#0 0x0001d744 in runtime.check ()
#1 0x00023c14 in runtime.cas ()
#2 0x0002326c in _rt0_arm ()
#3 0x0002326c in _rt0_arm ()
#4 0x0002326c in _rt0_arm ()
#5 0x0002326c in _rt0_arm ()
#6 0x0002326c in _rt0_arm ()
#7 0x0002326c in _rt0_arm ()
#8 0x0002326c in _rt0_arm ()
#9 0x0002326c in _rt0_arm ()
#10 0x0002326c in _rt0_arm ()
#11 0x0002326c in _rt0_arm ()
#12 0x0002326c in _rt0_arm ()
#13 0x0002326c in _rt0_arm ()
#14 0x0002326c in _rt0_arm ()
#15 0x0002326c in _rt0_arm ()
#16 0x0002326c in _rt0_arm ()
#17 0x0002326c in _rt0_arm ()
#18 0x0002326c in _rt0_arm ()
#19 0x0002326c in _rt0_arm ()
#20 0x0002326c in _rt0_arm ()
#21 0x0002326c in _rt0_arm ()
#22 0x0002326c in _rt0_arm ()
#23 0x0002326c in _rt0_arm ()
#24 0x0002326c in _rt0_arm ()
#25 0x0002326c in _rt0_arm ()
#26 0x0002326c in _rt0_arm ()
#27 0x0002326c in _rt0_arm ()
#28 0x0002326c in _rt0_arm ()
#29 0x0002326c in _rt0_arm ()
---Type <return> to continue, or q <return> to quit---
Quit
(gdb) x/10i $pc
0x1d744 <runtime.check+184>: vldr d0, [sp, #36] ; 0x24
0x1d748 <runtime.check+188>: vldr d1, [sp, #36] ; 0x24
0x1d74c <runtime.check+192>: vcmpe.f64 d0, d1
0x1d750 <runtime.check+196>: vmrs APSR_nzcv, fpscr
0x1d754 <runtime.check+200>: ldreq r1, [pc, #264] ; 0x1d864
<runtime.check+472>
0x1d758 <runtime.check+204>: streq r1, [sp, #4]
0x1d75c <runtime.check+208>: bleq 0x1cee0 <runtime.throw>
0x1d760 <runtime.check+212>: vldr d0, [sp, #36] ; 0x24
0x1d764 <runtime.check+216>: vldr d1, [sp, #36] ; 0x24
0x1d768 <runtime.check+220>: vcmpe.f64 d0, d1
(gdb) quit
A debugging session is active.

Inferior 1 [process 10356] will be killed.

Quit anyway? (y or n) y

rounin@LKG80B859:~$ cd go
rounin@LKG80B859:~/go$ hg identify
820ffde8c396 tip
rounin@LKG80B859:~$ cd -
rounin@LKG80B859:~$ lt hello*
-rw-r--r-- 1 rounin rounin 64 May 18 19:26 hello.go
-rwxr-xr-x 1 rounin rounin 226212 May 18 21:20 hello.old
-rwxr-xr-x 1 rounin rounin 226212 May 18 22:33 hello.old.1
-rwxr-xr-x 1 rounin rounin 171430 May 19 14:55 hello

rounin@LKG80B859:~$ file hello
hello: ELF 32-bit LSB executable, ARM, version 1 (SYSV), statically linked, not stripped
rounin@LKG80B859:~$ file hello.old
hello.old: ELF 32-bit LSB executable, ARM, version 1 (SYSV), statically linked, not
stripped

rounin@LKG80B859:~$ ./hello.old
This program can only be run on EABI kernels

hello.old executable was created by compiling with the original release of
go1.0.1/release

rounin@LKG80B859:~$ cd go.Fri18May2012_2247
rounin@LKG80B859:~/go.Fri18May2012_2247$ hg identify
2ccfd4b451d3 (release-branch.go1) go1.0.1/release

Please note on this ARM CPU based Cisco Linksys NSLU2 NAS it takes about 235 minutes
to compile after starting ./all.bash

So the debug cycles to debug this going forward will be long - your patience and guidance
will be greatly appreciated.
real 235m2.002s

Issue 2:
Enabling cpu profiling on a go program running on arm produces warnings from the runtime.

alarm(~/internet) % crawl -a 202 -b 114 -c 206 -d 221
2013/08/02 04:00:05 profile: cpu profiling enabled, /tmp/profile167829215/cpu.pprof
runtime: unexpected return pc for runtime.parfordo called from 0xb3e75be8
2013/08/02 04:00:12 202.114.207.254:80: copied 6741 bytes, err <nil>
runtime: unexpected return pc for runtime.MCache_Refill called from 0x227fbc
2013/08/02 04:00:25 202.114.206.221:80: copied 122 bytes, err read tcp4
202.114.206.221:80: i/o timeout
runtime: unexpected return pc for net.(*Dialer).Dial called from 0x0

What is the expected output? What do you see instead?

No warning messages from runtime.

Please use labels and text to provide additional information.

arch linux arm, linux/arm, pandaboard

alarm(~/go) % hg id
8b61a4ec6d1e+ tip