Solid::Processor Class

class Solid::Processor
Header: #include <Processor>
CMake: find_package(KF6 REQUIRED COMPONENTS Solid)
target_link_libraries(mytarget PRIVATE KF6::Solid)
Inherits: Solid::DeviceInterface

Public Types

enum InstructionSet { NoExtensions, IntelMmx, IntelSse, IntelSse2, IntelSse3, …, AltiVec }
flags InstructionSets

Public Functions

virtual ~Processor() override
bool canChangeFrequency() const
Solid::Processor::InstructionSets instructionSets() const
int maxSpeed() const
int number() const

Static Public Members

Solid::DeviceInterface::Type deviceInterfaceType()

Detailed Description

@class Solid::Processor processor.h <Solid/Processor>

This device interface is available on processors.

Member Type Documentation

enum Processor::InstructionSet
flags Processor::InstructionSets

This enum contains the list of architecture extensions you can query.

@see InstructionSets

The InstructionSets type is a typedef for QFlags<InstructionSet>. It stores an OR combination of InstructionSet values.

Member Function Documentation

[override virtual noexcept] Processor::~Processor()

Destroys a Processor object.

bool Processor::canChangeFrequency() const

Indicates if the processor can change the CPU frequency.

True if a processor is able to change its own CPU frequency. (generally for power management).

@return true if the processor can change CPU frequency, false otherwise

Note: Getter function for property canChangeFrequency.

[static] Solid::DeviceInterface::Type Processor::deviceInterfaceType()

Get the Solid::DeviceInterface::Type of the Processor device interface.

@return the Processor device interface type @see Solid::Ifaces::Enums::DeviceInterface::Type

Solid::Processor::InstructionSets Processor::instructionSets() const

Queries the instructions set extensions of the CPU.

@return the extensions supported by the CPU @see Solid::Processor::InstructionSet

Note: Getter function for property instructionSets.

int Processor::maxSpeed() const

Retrieves the maximum speed of the processor.

@return the maximum speed in MHz, or 0 if the device can't be queried for this information.

Note: Getter function for property maxSpeed.

int Processor::number() const

Retrieves the processor number in the system.

@return the internal processor number in the system, starting from zero

Note: Getter function for property number.