t_cpu Class Reference

#include <cpu.h>

Collaboration diagram for t_cpu:

Collaboration graph
[legend]

Public Member Functions

 t_cpu ()
bool big_endian () const
bool little_endian () const
void setAssertAbort (bool val)
bool lgAssertAbort () const
long nCPU () const
const char * host_name () const
void printDataPath () const

Private Member Functions

void enable_traps () const

Static Private Member Functions

static void signal_handler (int sig)

Private Attributes

union {
   char   c [4]
   int32   i
endian
int32 Float_SNaN_Value
int32 Double_SNaN_Value [2]
bool p_lgAssertAbort
long n_avail_CPU
char HostName [STDLEN]
vector< string > chSearchPath
int nFileDone

Friends

FILE * open_data (const char *fname, const char *mode, access_scheme scheme)
void set_NaN (sys_float &x)
void set_NaN (sys_float x[], long n)
void set_NaN (double &x)
void set_NaN (double x[], long n)

Detailed Description

Definition at line 146 of file cpu.h.


Constructor & Destructor Documentation

t_cpu::t_cpu (  ) 

Definition at line 38 of file cpu.cpp.

References big_endian(), chSearchPath, CLOUDY_DATA_PATH, DEBUG_ENTRY, Double_SNaN_Value, enable_traps(), endian, Float_SNaN_Value, HostName, i, little_endian(), n_avail_CPU, nFileDone, p_lgAssertAbort, signal_handler(), Split(), SPM_RELAX, and STDLEN.

Here is the call graph for this function:


Member Function Documentation

bool t_cpu::big_endian (  )  const [inline]

Definition at line 184 of file cpu.h.

References endian.

Referenced by MyIsnan(), and t_cpu().

void t_cpu::enable_traps (  )  const [private]

Definition at line 240 of file cpu.cpp.

Referenced by signal_handler(), and t_cpu().

const char* t_cpu::host_name (  )  const [inline]

Definition at line 213 of file cpu.h.

References HostName.

bool t_cpu::lgAssertAbort (  )  const [inline]

Definition at line 210 of file cpu.h.

References p_lgAssertAbort.

Referenced by OUT_OF_RANGE().

bool t_cpu::little_endian (  )  const [inline]

Definition at line 185 of file cpu.h.

References endian.

Referenced by MyIsnan(), and t_cpu().

long t_cpu::nCPU (  )  const [inline]

Definition at line 212 of file cpu.h.

References n_avail_CPU.

Referenced by ParseOptimize().

void t_cpu::printDataPath (  )  const

Definition at line 431 of file cpu.cpp.

References chSearchPath, cpu, i, and ioQQQ.

Referenced by open_data(), and ParsePrint().

void t_cpu::setAssertAbort ( bool  val  )  [inline]

Definition at line 192 of file cpu.h.

References p_lgAssertAbort, and signal_handler().

Referenced by main(), and ParseSet().

Here is the call graph for this function:

void t_cpu::signal_handler ( int  sig  )  [static, private]

Definition at line 419 of file cpu.cpp.

References cpu, and enable_traps().

Referenced by setAssertAbort(), and t_cpu().

Here is the call graph for this function:


Friends And Related Function Documentation

FILE* open_data ( const char *  fname,
const char *  mode,
access_scheme  scheme 
) [friend]

Definition at line 438 of file cpu.cpp.

void set_NaN ( double  x[],
long  n 
) [friend]

Definition at line 594 of file cpu.cpp.

void set_NaN ( double &  x  )  [friend]

Definition at line 577 of file cpu.cpp.

void set_NaN ( sys_float  x[],
long  n 
) [friend]

Definition at line 559 of file cpu.cpp.

void set_NaN ( sys_float x  )  [friend]

set_NaN - set variable or array to SNaN

Definition at line 551 of file cpu.cpp.


Field Documentation

char t_cpu::c[4] [private]

Definition at line 152 of file cpu.h.

vector<string> t_cpu::chSearchPath [private]

the default search path to the data files

Definition at line 176 of file cpu.h.

Referenced by open_data(), printDataPath(), and t_cpu().

int32 t_cpu::Double_SNaN_Value[2] [private]

Definition at line 160 of file cpu.h.

Referenced by set_NaN(), and t_cpu().

union { ... } t_cpu::endian [private]

alias an int32 to 4 chars to test if we are on a big-endian or little-endian CPU the array cpu.endian.c[] is initialized in cdInit()

Referenced by big_endian(), little_endian(), and t_cpu().

int32 t_cpu::Float_SNaN_Value [private]

Definition at line 156 of file cpu.h.

Referenced by set_NaN(), and t_cpu().

char t_cpu::HostName[STDLEN] [private]

the name of the computer, not detected on all systems

Definition at line 174 of file cpu.h.

Referenced by host_name(), and t_cpu().

int32 t_cpu::i [private]

Definition at line 153 of file cpu.h.

Referenced by printDataPath(), and t_cpu().

long t_cpu::n_avail_CPU [private]

the number of available CPUs on the system, not detected on all systems

Definition at line 172 of file cpu.h.

Referenced by nCPU(), and t_cpu().

int t_cpu::nFileDone [private]

Definition at line 177 of file cpu.h.

Referenced by open_data(), and t_cpu().

bool t_cpu::p_lgAssertAbort [private]

should a failed assert raise SIGABRT so that we can catch it in a debugger?

Definition at line 169 of file cpu.h.

Referenced by lgAssertAbort(), setAssertAbort(), and t_cpu().


The documentation for this class was generated from the following files:
Generated on Mon Feb 16 12:14:38 2009 for cloudy by  doxygen 1.4.7