On 01/10/2018 03:25 PM, Ian Lance Taylor wrote:
Thanks. I finally took a look at this. I don't know much about SH, but I don't think we want to add each SH variant as a separate GOARCH value. As you can see from the list you modified in ibgo/go/go/build/syslist.go, the difference between GOARCH values is essentially the calling convention. There are many different kinds of x86 processors, but since the only calling convention difference is between 32-bit and 64-bit, the list has only 386 and amd64. Similarly it seems to me we should have only sh and shbe in the list for SH processors.
My reasoning is that gcc itself differentiates between those different SH targets, i.e. there is a sh3, a sh4 target and the big-endian variants of these targets. There aren't different x86_64 targets in gcc though. Furthermore, as you can see, sh3 and sh4 also have different cacheline sizes, for example:
https://go-review.googlesource.com/c/gofrontend/+/84555/1/libgo/configure.ac
In total, we have four different SH targets. Adrian -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer - glaub...@debian.org `. `' Freie Universitaet Berlin - glaub...@physik.fu-berlin.de `- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913