This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v2] libgo: Add support for sh


On Sun, Dec 17, 2017 at 4:38 AM, John Paul Adrian Glaubitz
<glaubitz@physik.fu-berlin.de> wrote:
>
> This is the second version of my patch to add support for SuperH
> in libgo. The changes over my first patch in [1] are:
>
>  * account for little- and big-endian targets
>  * account for sh3- and sh4-specific parameters
>
> I have not added support for SH-1 and SH-2 targets for now as
> most Linux distributions with SH support usually target sh3 and
> sh4 only.
>
> I have already signed the Google CLA in the past when I contributed
> a small patch to Kubernetes.

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.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]