mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-31 15:27:42 -04:00 
			
		
		
		
	Vendor Update (#16121)
* update github.com/PuerkitoBio/goquery * update github.com/alecthomas/chroma * update github.com/blevesearch/bleve/v2 * update github.com/caddyserver/certmagic * update github.com/go-enry/go-enry/v2 * update github.com/go-git/go-billy/v5 * update github.com/go-git/go-git/v5 * update github.com/go-redis/redis/v8 * update github.com/go-testfixtures/testfixtures/v3 * update github.com/jaytaylor/html2text * update github.com/json-iterator/go * update github.com/klauspost/compress * update github.com/markbates/goth * update github.com/mattn/go-isatty * update github.com/mholt/archiver/v3 * update github.com/microcosm-cc/bluemonday * update github.com/minio/minio-go/v7 * update github.com/prometheus/client_golang * update github.com/unrolled/render * update github.com/xanzy/go-gitlab * update github.com/yuin/goldmark * update github.com/yuin/goldmark-highlighting Co-authored-by: techknowlogick <techknowlogick@gitea.io>
This commit is contained in:
		
							
								
								
									
										20
									
								
								vendor/github.com/klauspost/compress/zstd/enc_best.go
									
									
									
										generated
									
									
										vendored
									
									
								
							
							
						
						
									
										20
									
								
								vendor/github.com/klauspost/compress/zstd/enc_best.go
									
									
									
										generated
									
									
										vendored
									
									
								
							| @@ -132,7 +132,7 @@ func (e *bestFastEncoder) Encode(blk *blockEnc, src []byte) { | ||||
| 	} | ||||
| 	_ = addLiterals | ||||
|  | ||||
| 	if debug { | ||||
| 	if debugEncoder { | ||||
| 		println("recent offsets:", blk.recentOffsets) | ||||
| 	} | ||||
|  | ||||
| @@ -220,6 +220,20 @@ encodeLoop: | ||||
| 			best = bestOf(best, matchAt(candidateL.prev-e.cur, s, uint32(cv), -1)) | ||||
| 			best = bestOf(best, matchAt(candidateL2.offset-e.cur, s+1, uint32(cv2), -1)) | ||||
| 			best = bestOf(best, matchAt(candidateL2.prev-e.cur, s+1, uint32(cv2), -1)) | ||||
|  | ||||
| 			// See if we can find a better match by checking where the current best ends. | ||||
| 			// Use that offset to see if we can find a better full match. | ||||
| 			if sAt := best.s + best.length; sAt < sLimit { | ||||
| 				nextHashL := hash8(load6432(src, sAt), bestLongTableBits) | ||||
| 				candidateEnd := e.longTable[nextHashL] | ||||
| 				if pos := candidateEnd.offset - e.cur - best.length; pos >= 0 { | ||||
| 					bestEnd := bestOf(best, matchAt(pos, best.s, load3232(src, best.s), -1)) | ||||
| 					if pos := candidateEnd.prev - e.cur - best.length; pos >= 0 { | ||||
| 						bestEnd = bestOf(bestEnd, matchAt(pos, best.s, load3232(src, best.s), -1)) | ||||
| 					} | ||||
| 					best = bestEnd | ||||
| 				} | ||||
| 			} | ||||
| 		} | ||||
|  | ||||
| 		// We have a match, we can store the forward value | ||||
| @@ -260,7 +274,7 @@ encodeLoop: | ||||
|  | ||||
| 			nextEmit = s | ||||
| 			if s >= sLimit { | ||||
| 				if debug { | ||||
| 				if debugEncoder { | ||||
| 					println("repeat ended", s, best.length) | ||||
|  | ||||
| 				} | ||||
| @@ -398,7 +412,7 @@ encodeLoop: | ||||
| 	blk.recentOffsets[0] = uint32(offset1) | ||||
| 	blk.recentOffsets[1] = uint32(offset2) | ||||
| 	blk.recentOffsets[2] = uint32(offset3) | ||||
| 	if debug { | ||||
| 	if debugEncoder { | ||||
| 		println("returning, recent offsets:", blk.recentOffsets, "extra literals:", blk.extraLits) | ||||
| 	} | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user