// Copyright 2013 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// This file was split out from Go's crypto/cipher/xor.go

// +build 386 amd64 ppc64 ppc64le s390x appengine

package sasl

import (
	
)

const wordSize = int(unsafe.Sizeof(uintptr(0)))

// xorBytes xors in bulk. It only works on architectures that support unaligned
// read/writes.
func (, ,  []byte) int {
	 := len()
	if len() <  {
		 = len()
	}

	 :=  / wordSize
	if  > 0 {
		 := *(*[]uintptr)(unsafe.Pointer(&))
		 := *(*[]uintptr)(unsafe.Pointer(&))
		 := *(*[]uintptr)(unsafe.Pointer(&))
		for  := 0;  < ; ++ {
			[] = [] ^ []
		}
	}

	for  := ( - %wordSize);  < ; ++ {
		[] = [] ^ []
	}

	return 
}

// xorWords XORs multiples of 4 or 8 bytes (depending on architecture.) The
// arguments are assumed to be of equal length.
func (, ,  []byte) {
	 := *(*[]uintptr)(unsafe.Pointer(&))
	 := *(*[]uintptr)(unsafe.Pointer(&))
	 := *(*[]uintptr)(unsafe.Pointer(&))
	 := len() / wordSize
	for  := 0;  < ; ++ {
		[] = [] ^ []
	}
}