]> Cypherpunks repositories - gostls13.git/commit
runtime: don't use REP;MOVSB if CPUID doesn't say it is fast
authorKeith Randall <khr@golang.org>
Wed, 30 Mar 2016 04:25:33 +0000 (21:25 -0700)
committerKeith Randall <khr@golang.org>
Thu, 31 Mar 2016 02:54:10 +0000 (02:54 +0000)
commit4b209dbf0bf3e5fd4cffda1e11f11bf45ddf212d
treea7af96647c02144a3e82b576eb72d1704bf2f6ff
parent1a9373bc570cf408cecdfab5d531e8041f354a54
runtime: don't use REP;MOVSB if CPUID doesn't say it is fast

Only use REP;MOVSB if:
 1) The CPUID flag says it is fast, and
 2) The pointers are unaligned
Otherwise, use REP;MOVSQ.

Update #14630

Change-Id: I946b28b87880c08e5eed1ce2945016466c89db66
Reviewed-on: https://go-review.googlesource.com/21300
Reviewed-by: Nigel Tao <nigeltao@golang.org>
src/runtime/asm_386.s
src/runtime/asm_amd64.s
src/runtime/memmove_386.s
src/runtime/memmove_amd64.s
src/runtime/runtime2.go