zoslib
z/OS C/C++ Library
Loading...
Searching...
No Matches
Functions
zos-sys-info.cc File Reference
#include "zos-sys-info.h"
#include <assert.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>

Functions

int __get_num_online_cpus (void)
 
int __get_num_frames (void)
 
oslvl_t __get_os_level (void)
 
bool __is_os_level_at_or_above (oslvl_t level)
 
bool __is_stfle_available ()
 
bool __is_vxf_available ()
 
bool __is_vef1_available ()
 
char * __get_cpu_model (char *buffer, size_t size)
 

Function Documentation

◆ __get_cpu_model()

char * __get_cpu_model ( char *  buffer,
size_t  size 
)

Gets the 4 character CPU model of the system, including the null terminating character. Truncated if buffer size is too small.

Parameters
bufferpointer to the buffer where the cpu model is to be stored
sizethe size of the buffer
Returns
pointer to the buffer.

◆ __get_num_frames()

int __get_num_frames ( void  )

Get the number of frames currently available to the system

Returns
returns the number of available frames

◆ __get_num_online_cpus()

int __get_num_online_cpus ( void  )

Get the number of online CPUs

Returns
returns the number of online CPUs

◆ __get_os_level()

oslvl_t __get_os_level ( void  )

Get the OS level

Returns
the OS level as ZOSLVL_V2R1/2/3/4/5 (values are in ascending order)

◆ __is_os_level_at_or_above()

bool __is_os_level_at_or_above ( oslvl_t  level)

Check if current OS is at or above a given level

Returns
true if the current OS level is at or above the given level, and false otherwise

◆ __is_stfle_available()

bool __is_stfle_available ( )

Check if STFLE (STORE FACILITY LIST EXTENDED) instruction is available

Returns
true if the STFLE instruction is available

◆ __is_vef1_available()

bool __is_vef1_available ( )

Check if the current z arch includes Vector Enhancements Facility 1

Returns
true if Vector Enhancements Facility 1 instructions are available, and false otherwise

◆ __is_vxf_available()

bool __is_vxf_available ( )

Check if the current z arch includes Vector Extension Facility

Returns
true if Vector Extension Facility instructions are available, and false otherwise