File: galois_noasm.go

package info (click to toggle)
golang-github-klauspost-reedsolomon 1.2%2Bgit20161028.14.d0a56f7-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 668 kB
  • ctags: 255
  • sloc: asm: 134; makefile: 2
file content (19 lines) | stat: -rw-r--r-- 348 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
//+build !amd64 noasm appengine

// Copyright 2015, Klaus Post, see LICENSE for details.

package reedsolomon

func galMulSlice(c byte, in, out []byte) {
	mt := mulTable[c]
	for n, input := range in {
		out[n] = mt[input]
	}
}

func galMulSliceXor(c byte, in, out []byte) {
	mt := mulTable[c]
	for n, input := range in {
		out[n] ^= mt[input]
	}
}