Debian Codegraph @

internal/encoder/string_scan_other.go

raw
1 //go:build !amd64 && !arm64
2
3 package encoder
4
5 import (
6 "unsafe"
7 )
8
9 // maxOnePassLength is the length of the longest string which AppendString looks at and copies in one pass, of
10 // up to four words: a longer one is looked at by words, and copied after.
11 const maxOnePassLength = 31
12
13 // scanBytesSIMD is not available: the bytes are scanned one by one.
14 func scanBytesSIMD(_ unsafe.Pointer, _ int, _ *nibbleTables) (bool, bool) {
15 return false, false
16 }
17
18 // hasEscapeLoop is false: the loop of the escapes by SIMD is of amd64 only ( see string_scan_amd64.go ).
19 const hasEscapeLoop = false
20
21 // appendEscapedSIMD appends nothing: it is never called on this architecture.
22 func appendEscapedSIMD(buf []byte, _ string, _ *nibbleTables, _ bool) ([]byte, int) {
23 return buf, 0
24 }