|
libclues
Linux C++ Tracing Library
|
The futex operation to be performed in the context of a futex system call. More...
#include <futex.hxx>
Inheritance diagram for clues::item::FutexOperation:Public Types | |
| enum class | Command : int { WAIT = FUTEX_WAIT , WAKE = FUTEX_WAKE , WAIT_REQUEUE_PI = FUTEX_WAIT_REQUEUE_PI , CREATE_FD = FUTEX_FD , REQUEUE = FUTEX_REQUEUE , CMP_REQUEUE = FUTEX_CMP_REQUEUE , CMP_REQUEUE_PI = FUTEX_CMP_REQUEUE_PI , WAKE_OP = FUTEX_WAKE_OP , WAIT_BITSET = FUTEX_WAIT_BITSET , WAKE_BITSET = FUTEX_WAKE_BITSET , LOCK_PI = FUTEX_LOCK_PI , LOCK_PI2 = FUTEX_LOCK_PI2 , TRYLOCK_PI = FUTEX_TRYLOCK_PI , UNLOCK_PI = FUTEX_UNLOCK_PI } |
| enum class | Flag : int { PRIVATE_FLAG = FUTEX_PRIVATE_FLAG , REALTIME = FUTEX_CLOCK_REALTIME } |
| using | Flags = cosmos::BitMask<Flag> |
Public Types inherited from clues::SystemCallItem | |
| enum class | Flag { DEFER_FILL = 1 << 0 } |
| using | Flags = cosmos::BitMask<Flag> |
Public Member Functions | |
| std::string | str () const override |
| Returns a human readable string representation of the item. | |
| void | processValue (const Tracee &) override |
| Processes the value stored in m_val acc. to the actual item type. | |
| auto | command () const |
| auto | flags () const |
Public Member Functions inherited from clues::item::ValueInParameter | |
| ValueInParameter (const std::string_view short_name, const std::string_view long_name={}) | |
Public Member Functions inherited from clues::item::ValueParameter | |
| ValueParameter (const ItemType type, const std::string_view short_name, const std::string_view long_name={}) | |
Public Member Functions inherited from clues::SystemCallItem | |
| SystemCallItem (const ItemType type, const std::string_view short_name={}, const std::string_view long_name={}) | |
| Constructs a new SystemCallItem. | |
| auto | type () const |
| bool | isIn () const |
| bool | isOut () const |
| bool | isInOut () const |
| bool | isReturnValue () const |
| void | fill (const Tracee &proc, const Word word) |
| Fills the item from the given register data. | |
| bool | needsUpdate () const |
| Returns whether the item needs to be updated after the system call is finished. | |
| std::string_view | shortName () const |
| Returns the friendly short name for this item. | |
| std::string_view | longName () const |
| Returns the friendly long name for this item, if available, else the short name. | |
| auto | hasLongName () const |
| bool | isZero () const |
| Returns whether the parameter is set to 0 / NULL. | |
| Word | value () const |
| Returns the currently stored raw value of the item. | |
| template<typename OTHER> | |
| OTHER | valueAs () const |
Helper to cast the strongly typed Word m_val to other strong enum types. | |
| ForeignPtr | asPtr () const |
| Flags | flags () const |
| bool | deferFill () const |
Protected Attributes | |
| Command | m_cmd = Command{0} |
| Flags | m_flags |
Protected Attributes inherited from clues::SystemCallItem | |
| const SystemCall * | m_call = nullptr |
| The system call context this item part of. | |
| const ItemType | m_type |
| The type of item. | |
| std::string_view | m_short_name |
| A human readable short name for the item, should be one word only. | |
| std::string_view | m_long_name |
| A human readable longer name for the item. | |
| Word | m_val |
| The raw register value for the item. | |
| Flags | m_flags |
| Flags influencing the processing of the item. | |
Additional Inherited Members | |
Protected Member Functions inherited from clues::SystemCallItem | |
| virtual void | updateData (const Tracee &t) |
| Called upon exit of the system call to update possible out parameters. | |
| void | setSystemCall (const SystemCall &sc) |
| Sets the system call context this item is a part of. | |
The futex operation to be performed in the context of a futex system call.
The operation consists of a command and a set of bit mask flags.
| using clues::item::FutexOperation::Flags = cosmos::BitMask<Flag> |
|
strong |
Definition at line 22 of file futex.hxx.
|
strong |
|
inlineexplicit |
|
inline |
|
inline |
|
overridevirtual |
Processes the value stored in m_val acc. to the actual item type.
This function is called for all parameter types upon entry to a system call, and for ItemType::RETVAL upon exit from a system call.
For parameters of ItemType::PARAM_OUT this callback can be used to reset any stored data to be filled in later when updateData() is called.
Reimplemented from clues::SystemCallItem.
Definition at line 54 of file futex.cxx.
|
overridevirtual |
Returns a human readable string representation of the item.
This member function should be specialized in derived classes to output the item's data in a fashion suitable for the concrete item type.
Reimplemented from clues::SystemCallItem.
Definition at line 11 of file futex.cxx.
|
protected |