Documentation
¶
Overview ¶
Package shield provides CPU isolation for benchmark execution.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(*Shield)
Option configures a shield.
func WithLogger ¶
WithLogger configures the logger for CPU shield operations.
func WithShieldName ¶
WithShieldName configures the name of the shield cpuset. Note this is interpreted relative to the root.
func WithShieldNumCPU ¶
WithShieldNumCPU configures the number of CPUs assigned to the shield cpuset.
func WithSystemName ¶
WithSystemName configures the name of the system cpuset. Note this is interpreted relative to the root.
func WithSystemNumCPU ¶
WithSystemNumCPU configures the minimum number of CPUs assigned to the system cpuset.
type Shield ¶
type Shield struct {
// contains filtered or unexported fields
}
Shield uses cpusets to setup exclusive access to some CPUs.
func (*Shield) Available ¶
Available reports whether the shield mechanism can be applied. Note this is a rudimentary check that the environment supports cpusets at all, it is still possible that applying the shield would error.
func (*Shield) ShieldName ¶
ShieldName returns the name of the shield cpuset.