#include <sys/time.h>
#include <errno.h>
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <setjmp.h>
#include <assert.h>
#include <sched.h>
#include <misc/debug.h>
#include <misc/generic_types.h>
#include <core/stats.h>
#include <core/sentinel.h>
#include <core/koa.h>
#include <core/fm.h>
#include <core/buffer.h>
#include <core/config.h>
#include <core/tx.h>
Go to the source code of this file.
Functions | |
int | _TXC_global_init () |
Performs global initialization of the library. | |
int | _TXC_global_shutdown () |
Shutdowns the library. | |
int | _TXC_thread_init () |
Initializes and assigns an xCalls descriptor to a thread. | |
void | _TXC_transaction_abort (txc_tx_abortreason_t abort_reason) |
Aborts a transaction. | |
txc_tx_xactstate_t | _TXC_get_xactstate () |
Returns the transactional state of the current thread. | |
void | _TXC_transaction_pre_begin (const char *srcloc_str, const char *src_file, const char *src_fun, int src_line) |
Informs the xCall library that a transaction is going to begin. | |
void | _TXC_transaction_post_begin () |
Informs the xCall library that a transaction has begun. | |
void | _TXC_fm_register (int flags, int *err) |
Specifies what action to take when an asynchronous failure occurs. | |
Variables | |
txc_sentinelmgr_t * | txc_g_sentinelmgr |
txc_buffermgr_t * | txc_g_buffermgr |
txc_koamgr_t * | txc_g_koamgr |
txc_txmgr_t * | txc_g_txmgr |
txc_statsmgr_t * | txc_g_statsmgr |
timeval | txc_initialization_time |
Wrapper functions implementing the public interface of the library.
Definition in file interface.c.
txc_tx_xactstate_t _TXC_get_xactstate | ( | ) |
Returns the transactional state of the current thread.
Definition at line 124 of file interface.c.
References txc_l_txd, and txc_tx_get_xactstate().
int _TXC_global_init | ( | ) |
Performs global initialization of the library.
Creates all necessary managers.
Definition at line 46 of file interface.c.
References txc_buffermgr_create(), txc_config_init(), txc_g_buffermgr, txc_g_koamgr, txc_g_sentinelmgr, txc_g_statsmgr, txc_g_txmgr, txc_koamgr_create(), TXC_R_SUCCESS, txc_runtime_settings, txc_sentinelmgr_create(), txc_statsmgr_create(), and txc_txmgr_create().
int _TXC_global_shutdown | ( | ) |
Shutdowns the library.
Definition at line 78 of file interface.c.
References txc_g_statsmgr, TXC_R_SUCCESS, and txc_stats_print().
int _TXC_thread_init | ( | ) |
Initializes and assigns an xCalls descriptor to a thread.
Definition at line 92 of file interface.c.
References txc_g_txmgr, txc_l_txd, TXC_R_SUCCESS, and txc_tx_create().
void _TXC_transaction_abort | ( | txc_tx_abortreason_t | abort_reason | ) |
Aborts a transaction.
Requests the xCall library to abort a transaction.
[in] | abort_reason | Reason for abort. |
Definition at line 108 of file interface.c.
References txc_l_txd, and txc_tx_abort_transaction().
void _TXC_transaction_pre_begin | ( | const char * | srcloc_str, | |
const char * | src_file, | |||
const char * | src_fun, | |||
int | src_line | |||
) |
Informs the xCall library that a transaction is going to begin.
[in] | srcloc_str | String describing the transaction's source location. |
[in] | src_file | The file where the transaction is located. |
[in] | src_fun | The function where the transaction is located. |
[in] | src_line | The line number where the transaction is located. |
Definition at line 142 of file interface.c.
References txc_l_txd, and txc_tx_pre_begin().