gem5  v21.0.1.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Debug::SimpleFlag Class Reference

#include <debug.hh>

Inheritance diagram for Debug::SimpleFlag:
Debug::Flag

Public Member Functions

 SimpleFlag (const char *name, const char *desc, bool is_format=false)
 
bool enabled () const override
 
void enable () override
 
void disable () override
 
bool isFormat () const
 Checks whether this flag is a conventional debug flag, or a flag that modifies the way debug information is printed. More...
 
- Public Member Functions inherited from Debug::Flag
 Flag (const char *name, const char *desc)
 
virtual ~Flag ()
 
std::string name () const
 
std::string desc () const
 
 operator bool () const
 

Protected Member Functions

void sync () override
 

Protected Attributes

const bool _isFormat = false
 Whether this flag changes debug formatting. More...
 
bool _tracing = false
 
bool _enabled = false
 
- Protected Attributes inherited from Debug::Flag
const char * _name
 
const char * _desc
 

Additional Inherited Members

- Static Public Member Functions inherited from Debug::Flag
static void globalEnable ()
 
static void globalDisable ()
 
- Static Protected Attributes inherited from Debug::Flag
static bool _globalEnable = false
 

Detailed Description

Definition at line 81 of file debug.hh.

Constructor & Destructor Documentation

◆ SimpleFlag()

Debug::SimpleFlag::SimpleFlag ( const char *  name,
const char *  desc,
bool  is_format = false 
)
inline

Definition at line 93 of file debug.hh.

Member Function Documentation

◆ disable()

void Debug::SimpleFlag::disable ( )
inlineoverridevirtual

Implements Debug::Flag.

Definition at line 100 of file debug.hh.

References _enabled, and sync().

Referenced by TEST().

◆ enable()

void Debug::SimpleFlag::enable ( )
inlineoverridevirtual

Implements Debug::Flag.

Definition at line 99 of file debug.hh.

References _enabled, and sync().

Referenced by TEST().

◆ enabled()

bool Debug::SimpleFlag::enabled ( ) const
inlineoverridevirtual

Implements Debug::Flag.

Definition at line 97 of file debug.hh.

References _tracing.

Referenced by TEST().

◆ isFormat()

bool Debug::SimpleFlag::isFormat ( ) const
inline

Checks whether this flag is a conventional debug flag, or a flag that modifies the way debug information is printed.

Returns
True if this flag is a debug-formatting flag.

Definition at line 108 of file debug.hh.

References _isFormat.

Referenced by pybind_init_debug(), and TEST().

◆ sync()

void Debug::SimpleFlag::sync ( )
inlineoverrideprotectedvirtual

Reimplemented from Debug::Flag.

Definition at line 90 of file debug.hh.

References _enabled, Debug::Flag::_globalEnable, and _tracing.

Referenced by disable(), and enable().

Member Data Documentation

◆ _enabled

bool Debug::SimpleFlag::_enabled = false
protected

Definition at line 88 of file debug.hh.

Referenced by disable(), enable(), and sync().

◆ _isFormat

const bool Debug::SimpleFlag::_isFormat = false
protected

Whether this flag changes debug formatting.

Definition at line 85 of file debug.hh.

Referenced by isFormat().

◆ _tracing

bool Debug::SimpleFlag::_tracing = false
protected

Definition at line 87 of file debug.hh.

Referenced by enabled(), and sync().


The documentation for this class was generated from the following file:

Generated on Tue Jun 22 2021 15:28:50 for gem5 by doxygen 1.8.17