github.com/segmentio/parquet-go@v0.0.0-20230712180008-5d42db8f0d47/value_amd64.go (about)

     1  //go:build !purego
     2  
     3  package parquet
     4  
     5  import "golang.org/x/sys/cpu"
     6  
     7  //go:noescape
     8  func memsetValuesAVX2(values []Value, model Value, _ uint64)
     9  
    10  func memsetValues(values []Value, model Value) {
    11  	if cpu.X86.HasAVX2 {
    12  		memsetValuesAVX2(values, model, 0)
    13  	} else {
    14  		for i := range values {
    15  			values[i] = model
    16  		}
    17  	}
    18  }