usermode/library/mtm/src/mode/dtable.h File Reference

Definition of the dispatch table. More...

#include "mtm_i.h"
#include "mode/mode.h"

Go to the source code of this file.

Classes

struct  mtm_dtable_s
struct  mtm_dtable_group_s

Defines

#define FOREACH_ABI_FUNCTION(ACTION,)
#define FOREACH_DTABLE_ENTRY(ACTION, ARG)
#define _DTABLE_MEMBER(result, function, args, ARG)   result (_ITM_CALL_CONVENTION * function##p) args;
#define _GEN_READ_BARRIER(ACTION, result_type, encoding,)
#define _GEN_WRITE_BARRIER(ACTION, result_type, encoding,)
#define FOREACH_READ_BARRIER(ACTION,)   _ITM_GENERATE_FOREACH_SIMPLE_TRANSFER (_GEN_READ_BARRIER, ACTION, __VA_ARGS__)
#define FOREACH_WRITE_BARRIER(ACTION,)   _ITM_GENERATE_FOREACH_SIMPLE_TRANSFER (_GEN_WRITE_BARRIER, ACTION, __VA_ARGS__)
#define ACTION(mode)   mtm_dtable_t * mtm_##mode;

Typedefs

typedef mtm_dtable_s mtm_dtable_t
typedef mtm_dtable_group_s mtm_dtable_group_t

Variables

mtm_dtable_group_t normal_dtable_group
mtm_dtable_group_tdefault_dtable_group


Detailed Description

Definition of the dispatch table.

Author:
Haris Volos <hvolos@cs.wisc.edu>
This file contains the definition of the dispatch table, which is used to support dynamic switching between execution modes as described in section 4.1 of the paper:

Design and Implementation of Transactional Constructs for C/C++, OOPLSLA 2008

The dispatch table contains only the ABI functions that take as first argument a transaction descriptor. The rest of the ABI is implemented in intelabi.c

Definition in file dtable.h.


Define Documentation

#define _GEN_READ_BARRIER ( ACTION,
result_type,
encoding   ) 

Value:

ACTION (result_type, R##encoding, dummy_args, __VA_ARGS__)     \
    ACTION (result_type, RaR##encoding, dummy_args, __VA_ARGS__)   \
    ACTION (result_type, RaW##encoding, dummy_args, __VA_ARGS__)   \
    ACTION (result_type, RfW##encoding, dummy_args, __VA_ARGS__)

Definition at line 53 of file dtable.h.

#define _GEN_WRITE_BARRIER ( ACTION,
result_type,
encoding   ) 

Value:

ACTION (result_type, W##encoding, dummy_args, __VA_ARGS__)     \
    ACTION (result_type, WaR##encoding, dummy_args, __VA_ARGS__)   \
    ACTION (result_type, WaW##encoding, dummy_args, __VA_ARGS__)

Definition at line 59 of file dtable.h.

#define FOREACH_ABI_FUNCTION ( ACTION   ) 

Value:

ACTION (void,     abortTransaction,     (mtm_tx_t *td,                               \
                                             _ITM_abortReason reason,                    \
                                             const _ITM_srcLocation *loc), __VA_ARGS__)  \
    ACTION (void,     rollbackTransaction,  (mtm_tx_t *td,                               \
                                             const _ITM_srcLocation *loc), __VA_ARGS__)  \
    ACTION (void,     commitTransaction,    (mtm_tx_t *td,                               \
                                             const _ITM_srcLocation *loc), __VA_ARGS__)  \
    ACTION (bool,     tryCommitTransaction, (mtm_tx_t *td,                               \
                                             const _ITM_srcLocation *loc), __VA_ARGS__)  \
    ACTION (void,     commitTransactionToId,(mtm_tx_t *td,                               \
                                             const _ITM_transactionId tid,               \
                                             const _ITM_srcLocation *loc), __VA_ARGS__)  \
    ACTION (uint32_t, beginTransaction,     (mtm_tx_t *td,                               \
                                             uint32 __properties,                        \
                                             const _ITM_srcLocation *loc), __VA_ARGS__)  \

Definition at line 27 of file dtable.h.

#define FOREACH_DTABLE_ENTRY ( ACTION,
ARG   ) 

Value:

FOREACH_ABI_FUNCTION(ACTION,ARG)                               \
    _ITM_FOREACH_TRANSFER (ACTION,ARG)

Definition at line 44 of file dtable.h.


Generated on Sat Apr 23 11:43:36 2011 for Mnemosyne by  doxygen 1.4.7