C# Class IntelShared.Common.ProcessorQueryAndControl

Exibir arquivo Open project: 01org/NMPRK Class Usage Examples

Public Methods

Method Description
DecodeTimeWindowForPowerLimit ( ulong val, double timeUnit ) : double
EncodeTimeWindowForPowerLimit ( double val, double timeUnit ) : ulong
FromBinaryFractionFormat ( BitArray ba ) : double
GetCpuInfo ( int &phyProc, int &cores, int &logProc, LogicalProcessorInfo &aProcessorList ) : void
GetCurrentFrequency ( int miMaxNonTurboRatio ) : double
GetCurrentPState ( int &PState, int &NumPStates ) : bool
GetCurrentProcessorNumber ( ushort &group ) : uint
GetMaxNonTurboRatio ( ) : int
GetMinNonTurboRatio ( ) : int
GetPStateVoltage ( uint msr, BitRange range ) : float
GetPackagePowerLimitValues ( PackagePowerLimitIndex idx ) : PackagePowerLimit
GetRaplPowerUnits ( double &powerUnits, double &energyUnits, double &timeUnits ) : bool
GetRegisterValue ( uint msr, int bit ) : bool
GetRegisterValue ( uint msr ) : ulong
GetRegisterValue ( uint msr, BitRange range ) : ulong
GetTSC ( ) : ulong
GetTurboBoostStatus ( bool &Enabled, double &Frequency, int &PState, int &NumPStates ) : bool
GetTurboModeDisable ( bool &disable ) : bool
SetAffinity ( LogicalProcessorInfo lpInfo ) : void
SetPackagePowerLimitValues ( PackagePowerLimitIndex idx, PackagePowerLimit ppl, PackagePowerLimitMask mask ) : void
SetRegisterValue ( uint msr, int bit, bool val ) : bool
SetRegisterValue ( uint msr, BitRange range, ulong value ) : ulong
SetTurboModeDisable ( bool disable ) : bool

Private Methods

Method Description
CheckForGPPExEntryPoint ( ) : bool
CloseHandle ( [ hObject ) : bool
CountNumberOfBitsSetInMask ( UIntPtr bitMask ) : uint
CreateMask ( uint aStart, uint aStop ) : ulong
DuplicateHandle ( IntPtr hSourceProcessHandle, IntPtr hSourceHandle, IntPtr hTargetProcessHandle, IntPtr &lpTargetHandle, uint dwDesiredAccess, [ bInheritHandle, uint dwOptions ) : bool
Fail ( ) : Exception
GetActiveProcessorCount ( [ GroupNumber ) : int
GetActiveProcessorGroupCount ( ) : ushort
GetCacheType ( _PROCESSOR_CACHE_TYPE value ) : string
GetCountsForGT64LPs ( _LOGICAL_PROCESSOR_RELATIONSHIP aType, int &aCount, LogicalProcessorInfo &aProcessorList ) : bool
GetCurrentProcessorNumber ( ) : uint
GetCurrentProcessorNumberEx ( _PROCESSOR_NUMBER &ProcNumber ) : uint
GetCurrentThread ( ) : IntPtr
GetLogicalProcessorInformation ( [ infos, uint &infoSize ) : bool
GetLogicalProcessorInformationEx ( [ RelationshipType, [ Buffer, uint &ReturnedLength ) : bool
GetLogicalProcessorInformationExWrapper ( _LOGICAL_PROCESSOR_RELATIONSHIP _LOGICAL_PROCESSOR_RELATIONSHIP, _SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX_P oDummy, uint &returnLength ) : bool
GetMaximumProcessorCount ( [ GroupNumber ) : int
GetMaximumProcessorGroupCount ( ) : ushort
GetNumaDataArray ( _LOGICAL_PROCESSOR_RELATIONSHIP aType ) : _SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX_N[]
GetNumaNodeProcessorMaskEx ( [ Node, _GROUP_AFFINITY &ProcessorMask ) : bool
GetPackagePowerLimit1_RegVal ( ) : ulong
GetPackagePowerLimit2_RegVal ( ) : ulong
GetPhysicalProcessorCount ( int &aCores, int &aLPs, LogicalProcessorInfo &aProcessorList ) : int
GetPhysicalProcessorCountForGT64LPs ( int &aCores, int &aLPs, LogicalProcessorInfo &aProcessorList ) : int
GetProcessorDataArray ( _LOGICAL_PROCESSOR_RELATIONSHIP aType ) : _SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX_P[]
GetProcessorInfo64 ( ) : List
GetProcessorInfo86 ( ) : List
GetThreadGroupAffinity ( IntPtr hThread, _GROUP_AFFINITY &GroupAffinity ) : bool
GetTimeWindowPowerLimit1_RegVal ( ) : ulong
GetTimeWindowPowerLimit2_RegVal ( ) : ulong
ProcessorQueryAndControl ( ) : System
ReadMPerfAPerf ( ulong &MPERF, ulong &APERF ) : void
SetThreadAffinityMask ( IntPtr hThread, UIntPtr dwThreadAffinityMask ) : UIntPtr
SetThreadGroupAffinity ( IntPtr hThread, _GROUP_AFFINITY &GroupAffinity, _GROUP_AFFINITY &PreviousGroupAffinity ) : System.Boolean

Method Details

DecodeTimeWindowForPowerLimit() public static method

public static DecodeTimeWindowForPowerLimit ( ulong val, double timeUnit ) : double
val ulong
timeUnit double
return double

EncodeTimeWindowForPowerLimit() public static method

public static EncodeTimeWindowForPowerLimit ( double val, double timeUnit ) : ulong
val double
timeUnit double
return ulong

FromBinaryFractionFormat() public static method

public static FromBinaryFractionFormat ( BitArray ba ) : double
ba System.Collections.BitArray
return double

GetCpuInfo() public static method

public static GetCpuInfo ( int &phyProc, int &cores, int &logProc, LogicalProcessorInfo &aProcessorList ) : void
phyProc int
cores int
logProc int
aProcessorList LogicalProcessorInfo
return void

GetCurrentFrequency() public static method

public static GetCurrentFrequency ( int miMaxNonTurboRatio ) : double
miMaxNonTurboRatio int
return double

GetCurrentPState() public static method

public static GetCurrentPState ( int &PState, int &NumPStates ) : bool
PState int
NumPStates int
return bool

GetCurrentProcessorNumber() public static method

public static GetCurrentProcessorNumber ( ushort &group ) : uint
group ushort
return uint

GetMaxNonTurboRatio() public static method

public static GetMaxNonTurboRatio ( ) : int
return int

GetMinNonTurboRatio() public static method

public static GetMinNonTurboRatio ( ) : int
return int

GetPStateVoltage() public static method

public static GetPStateVoltage ( uint msr, BitRange range ) : float
msr uint
range BitRange
return float

GetPackagePowerLimitValues() public static method

public static GetPackagePowerLimitValues ( PackagePowerLimitIndex idx ) : PackagePowerLimit
idx PackagePowerLimitIndex
return PackagePowerLimit

GetRaplPowerUnits() public static method

public static GetRaplPowerUnits ( double &powerUnits, double &energyUnits, double &timeUnits ) : bool
powerUnits double
energyUnits double
timeUnits double
return bool

GetRegisterValue() public static method

public static GetRegisterValue ( uint msr, int bit ) : bool
msr uint
bit int
return bool

GetRegisterValue() public static method

public static GetRegisterValue ( uint msr ) : ulong
msr uint
return ulong

GetRegisterValue() public static method

public static GetRegisterValue ( uint msr, BitRange range ) : ulong
msr uint
range BitRange
return ulong

GetTSC() public static method

public static GetTSC ( ) : ulong
return ulong

GetTurboBoostStatus() public static method

public static GetTurboBoostStatus ( bool &Enabled, double &Frequency, int &PState, int &NumPStates ) : bool
Enabled bool
Frequency double
PState int
NumPStates int
return bool

GetTurboModeDisable() public static method

public static GetTurboModeDisable ( bool &disable ) : bool
disable bool
return bool

SetAffinity() public static method

public static SetAffinity ( LogicalProcessorInfo lpInfo ) : void
lpInfo LogicalProcessorInfo
return void

SetPackagePowerLimitValues() public static method

public static SetPackagePowerLimitValues ( PackagePowerLimitIndex idx, PackagePowerLimit ppl, PackagePowerLimitMask mask ) : void
idx PackagePowerLimitIndex
ppl PackagePowerLimit
mask PackagePowerLimitMask
return void

SetRegisterValue() public static method

public static SetRegisterValue ( uint msr, int bit, bool val ) : bool
msr uint
bit int
val bool
return bool

SetRegisterValue() public static method

public static SetRegisterValue ( uint msr, BitRange range, ulong value ) : ulong
msr uint
range BitRange
value ulong
return ulong

SetTurboModeDisable() public static method

public static SetTurboModeDisable ( bool disable ) : bool
disable bool
return bool