]> Cypherpunks repositories - gostls13.git/commit
strings: fix Contains on amd64
authorKeith Randall <khr@golang.org>
Sun, 15 May 2016 00:33:23 +0000 (17:33 -0700)
committerKeith Randall <khr@golang.org>
Sun, 15 May 2016 05:21:03 +0000 (05:21 +0000)
commit0bc14f57ec7e5518af711a64103ca2ac72f19a6e
treeb5ed42d6eb1f8fb65a80372fca203c9ff920970d
parentaba7b3e91cea1c95a1803357bcf219b0591d3c12
strings: fix Contains on amd64

The 17-31 byte code is broken.  Disabled it.

Added a bunch of tests to at least cover the cases
in indexShortStr.  I'll channel Brad and wonder why
this CL ever got in without any tests.

Fixes #15679

Change-Id: I84a7b283a74107db865b9586c955dcf5f2d60161
Reviewed-on: https://go-review.googlesource.com/23106
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/runtime/asm_amd64.s
src/strings/strings_amd64.go
src/strings/strings_test.go