estimate

package
v3.0.0-alpha5.0...-c974331 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2024 License: LGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	//elias-fano index building is single-threaded
	// when set it to 3GB - observed OOM-kil at server with 128Gb ram and 32CPU
	IndexSnapshot = EstimatedRamPerWorker(4 * datasize.GB)

	//1-file-compression is multi-threaded
	CompressSnapshot = EstimatedRamPerWorker(1 * datasize.GB)

	StateV3Collate = EstimatedRamPerWorker(5 * datasize.GB)

	//BlocksExecution - in multi-threaded mode
	BlocksExecution = EstimatedRamPerWorker(512 * datasize.MB)
)

Variables

This section is empty.

Functions

func AlmostAllCPUs

func AlmostAllCPUs() int

AlmostAllCPUs - return all-but-one cpus. Leaving 1 cpu for "work producer", also cloud-providers do recommend leave 1 CPU for their IO software user can reduce GOMAXPROCS env variable

Types

type EstimatedRamPerWorker

type EstimatedRamPerWorker datasize.ByteSize

func (EstimatedRamPerWorker) Workers

func (r EstimatedRamPerWorker) Workers() int

Workers - return max workers amount based on total Memory/CPU's and estimated RAM per worker

func (EstimatedRamPerWorker) WorkersByRAMOnly

func (r EstimatedRamPerWorker) WorkersByRAMOnly() int

WorkersByRAMOnly - return max workers amount based on total Memory and estimated RAM per worker

func (EstimatedRamPerWorker) WorkersHalf

func (r EstimatedRamPerWorker) WorkersHalf() int

func (EstimatedRamPerWorker) WorkersQuarter

func (r EstimatedRamPerWorker) WorkersQuarter() int

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL