mirror of
https://github.com/mudler/luet.git
synced 2025-09-05 17:20:29 +00:00
Use goreleaser to build and release (#244)
Instead of using gox on one side and an action to release, we can merge them together with goreleaser which will build for extra targets (arm, mips if needed in the future) and it also takes care of creating checksums, a source archive, and a changelog and creating a release with all the artifacts. All binaries should respect the old naming convention, so any scripts out there should still work. Signed-off-by: Itxaka <igarcia@suse.com>
This commit is contained in:
23
vendor/github.com/klauspost/compress/zstd/fse_decoder.go
generated
vendored
23
vendor/github.com/klauspost/compress/zstd/fse_decoder.go
generated
vendored
@@ -19,7 +19,7 @@ const (
|
||||
* Increasing memory usage improves compression ratio
|
||||
* Reduced memory usage can improve speed, due to cache effect
|
||||
* Recommended max value is 14, for 16KB, which nicely fits into Intel x86 L1 cache */
|
||||
maxMemoryUsage = 11
|
||||
maxMemoryUsage = tablelogAbsoluteMax + 2
|
||||
|
||||
maxTableLog = maxMemoryUsage - 2
|
||||
maxTablesize = 1 << maxTableLog
|
||||
@@ -55,7 +55,7 @@ func (s *fseDecoder) readNCount(b *byteReader, maxSymbol uint16) error {
|
||||
if b.remain() < 4 {
|
||||
return errors.New("input too small")
|
||||
}
|
||||
bitStream := b.Uint32()
|
||||
bitStream := b.Uint32NC()
|
||||
nbBits := uint((bitStream & 0xF) + minTablelog) // extract tableLog
|
||||
if nbBits > tablelogAbsoluteMax {
|
||||
println("Invalid tablelog:", nbBits)
|
||||
@@ -79,7 +79,8 @@ func (s *fseDecoder) readNCount(b *byteReader, maxSymbol uint16) error {
|
||||
n0 += 24
|
||||
if r := b.remain(); r > 5 {
|
||||
b.advance(2)
|
||||
bitStream = b.Uint32() >> bitCount
|
||||
// The check above should make sure we can read 32 bits
|
||||
bitStream = b.Uint32NC() >> bitCount
|
||||
} else {
|
||||
// end of bit stream
|
||||
bitStream >>= 16
|
||||
@@ -104,10 +105,11 @@ func (s *fseDecoder) readNCount(b *byteReader, maxSymbol uint16) error {
|
||||
charnum++
|
||||
}
|
||||
|
||||
if r := b.remain(); r >= 7 || r+int(bitCount>>3) >= 4 {
|
||||
if r := b.remain(); r >= 7 || r-int(bitCount>>3) >= 4 {
|
||||
b.advance(bitCount >> 3)
|
||||
bitCount &= 7
|
||||
bitStream = b.Uint32() >> bitCount
|
||||
// The check above should make sure we can read 32 bits
|
||||
bitStream = b.Uint32NC() >> bitCount
|
||||
} else {
|
||||
bitStream >>= 2
|
||||
}
|
||||
@@ -118,7 +120,7 @@ func (s *fseDecoder) readNCount(b *byteReader, maxSymbol uint16) error {
|
||||
|
||||
if int32(bitStream)&(threshold-1) < max {
|
||||
count = int32(bitStream) & (threshold - 1)
|
||||
if debug && nbBits < 1 {
|
||||
if debugAsserts && nbBits < 1 {
|
||||
panic("nbBits underflow")
|
||||
}
|
||||
bitCount += nbBits - 1
|
||||
@@ -148,17 +150,16 @@ func (s *fseDecoder) readNCount(b *byteReader, maxSymbol uint16) error {
|
||||
threshold >>= 1
|
||||
}
|
||||
|
||||
//println("b.off:", b.off, "len:", len(b.b), "bc:", bitCount, "remain:", b.remain())
|
||||
if r := b.remain(); r >= 7 || r+int(bitCount>>3) >= 4 {
|
||||
if r := b.remain(); r >= 7 || r-int(bitCount>>3) >= 4 {
|
||||
b.advance(bitCount >> 3)
|
||||
bitCount &= 7
|
||||
// The check above should make sure we can read 32 bits
|
||||
bitStream = b.Uint32NC() >> (bitCount & 31)
|
||||
} else {
|
||||
bitCount -= (uint)(8 * (len(b.b) - 4 - b.off))
|
||||
b.off = len(b.b) - 4
|
||||
//println("b.off:", b.off, "len:", len(b.b), "bc:", bitCount, "iend", iend)
|
||||
bitStream = b.Uint32() >> (bitCount & 31)
|
||||
}
|
||||
bitStream = b.Uint32() >> (bitCount & 31)
|
||||
//printf("bitstream is now: 0b%b", bitStream)
|
||||
}
|
||||
s.symbolLen = charnum
|
||||
if s.symbolLen <= 1 {
|
||||
|
Reference in New Issue
Block a user