Small optimizations, down to 1.29s for 50K RRs

This commit is contained in:
Miek Gieben 2011-07-22 23:57:56 +02:00
parent a1a0034733
commit 3eae3d90e7
2 changed files with 160 additions and 158 deletions

313
zparse.go

File diff suppressed because it is too large Load Diff

View File

@ -11,6 +11,9 @@ import (
"strconv"
)
//const _IOBUF = 65365 // See comments in gdnsd
const _IOBUF = 3e7 // TODO fix sliding window stuff in Ragel
// A Parser represents a DNS master zone file parser for a
// particular input stream.
type Parser struct {
@ -35,8 +38,6 @@ func NewParser(r io.Reader) *Parser {
return p
}
//const _IOBUF = 65365 // See comments in gdnsd
const _IOBUF = 3e7
// Return the rdata fields as a string slice.
// All starting whitespace is deleted.