]> Cypherpunks repositories - gostls13.git/commit
bytes, strings: fix comparison of long byte slices on s390x
authorbill_ofarrell <billo@ca.ibm.com>
Thu, 28 Jun 2018 22:39:37 +0000 (18:39 -0400)
committerBrad Fitzpatrick <bradfitz@golang.org>
Fri, 29 Jun 2018 20:48:07 +0000 (20:48 +0000)
commita5f8128e39d081c972e7bf3182122bac79bb6f8c
treeb40d8ece5b6cc51274683cbe95607254340e0e4c
parentd4d8237a5bfee5965382ee43da9e70417e9516af
bytes, strings: fix comparison of long byte slices on s390x

The existing implementation of bytes.Compare on s390x doesn't work properly for slices longer
than 256 elements. This change fixes that. Added tests for long strings and slices of bytes.

Fixes #26114

Change-Id: If6d8b68ee6dbcf99a24f867a1d3438b1f208954f
Reviewed-on: https://go-review.googlesource.com/121495
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/bytes/compare_test.go
src/internal/bytealg/compare_s390x.s
src/strings/compare_test.go