Commit 23c41a1e authored by Graham Miller's avatar Graham Miller Committed by Rob Pike

Small addition to previous optimization of memequal as discussed here:…

Small addition to previous optimization of memequal as discussed here: http://groups.google.com/group/golang-nuts/browse_thread/thread/f591ba36d83723c0/9aba02d344045f38

R=golang-dev, r, r2
CC=golang-dev
https://golang.org/cl/2880041
parent 3a50d721
...@@ -320,6 +320,8 @@ memequal(uint32 s, void *a, void *b) ...@@ -320,6 +320,8 @@ memequal(uint32 s, void *a, void *b)
{ {
byte *ba, *bb, *aend; byte *ba, *bb, *aend;
if(a == b)
return 1;
ba = a; ba = a;
bb = b; bb = b;
aend = ba+s; aend = ba+s;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment