usermode/library/mtm/src/intelabi.c File Reference

Implements the rest of the Intel ABI that is not exported via the dispatch table. More...

#include "mtm_i.h"
#include <stdio.h>
#include "init.h"
#include "useraction.h"

Go to the source code of this file.

Functions

int _ITM_CALL_CONVENTION _ITM_versionCompatible (int version)
const char *_ITM_CALL_CONVENTION _ITM_libraryVersion (void)
_ITM_howExecuting _ITM_CALL_CONVENTION _ITM_inTransaction (mtm_tx_t *tx)
_ITM_transactionId _ITM_CALL_CONVENTION _ITM_getTransactionId (mtm_tx_t *td)
mtm_tx_t *_ITM_CALL_CONVENTION _ITM_getTransaction (void)
int _ITM_CALL_CONVENTION _ITM_getThreadnum (void)
void _ITM_CALL_CONVENTION
ITM_NORETURN 
_ITM_error (const _ITM_srcLocation *loc UNUSED, int errorCode UNUSED)
void _ITM_CALL_CONVENTION _ITM_userError (const char *errorStr, int errorCode)
void _ITM_CALL_CONVENTION _ITM_dropReferences (mtm_tx_t *td, const void *start, size_t size)
void _ITM_CALL_CONVENTION _ITM_registerThrownObject (mtm_tx_t *td, const void *exception_object, size_t s)
int _ITM_CALL_CONVENTION _ITM_initializeProcess (void)
void _ITM_CALL_CONVENTION _ITM_finalizeProcess (void)
int _ITM_CALL_CONVENTION _ITM_initializeThread (void)
void _ITM_CALL_CONVENTION _ITM_finalizeThread (void)
void _ITM_CALL_CONVENTION _ITM_registerThreadFinalization (void(_ITM_CALL_CONVENTION *thread_fini_func)(void *), void *arg)
void _ITM_CALL_CONVENTION _ITM_addUserCommitAction (mtm_tx_t *__td, _ITM_userCommitFunction fn, _ITM_transactionId tid, void *arg)
void _ITM_CALL_CONVENTION _ITM_addUserUndoAction (mtm_tx_t *__td, const _ITM_userUndoFunction fn, void *arg)
void _ITM_CALL_CONVENTION _ITM_changeTransactionMode (mtm_tx_t *td, _ITM_transactionState __mode, const _ITM_srcLocation *__loc)


Detailed Description

Implements the rest of the Intel ABI that is not exported via the dispatch table.

Definition in file intelabi.c.


Function Documentation

void _ITM_CALL_CONVENTION _ITM_addUserCommitAction ( _ITM_transaction __td,
_ITM_userCommitFunction  __commit,
_ITM_transactionId  resumingTransactionId,
void *  __arg 
)

Add an entry to the user commit action log

Parameters:
__td The transaction descriptor
__commit The commit function
resumingTransactionId The id of the transaction that must be in the undo path before a commit can proceed.
__arg The user argument to store in the log entry

Definition at line 194 of file intelabi.c.

void _ITM_CALL_CONVENTION _ITM_addUserUndoAction ( _ITM_transaction __td,
const _ITM_userUndoFunction  __undo,
void *  __arg 
)

Add an entry to the user undo action log

Parameters:
__td The transaction descriptor
__undo Pointer to the undo function
__arg The user argument to store in the log entry

Definition at line 204 of file intelabi.c.

void _ITM_CALL_CONVENTION _ITM_changeTransactionMode ( _ITM_transaction td,
_ITM_transactionState  __mode,
const _ITM_srcLocation __loc 
)

Enter an irrevocable mode. If this function returns then execution is now in the new mode, however it's possible that to enter the new mode the transaction must be aborted and retried, in which case this function will not return.

Parameters:
__td The transaction descriptor.
__mode The new execution mode.
__src The source location.

Definition at line 213 of file intelabi.c.

void _ITM_CALL_CONVENTION _ITM_dropReferences ( _ITM_transaction __td,
const void *  __start,
size_t  __size 
)

A method to remove any references the library may be storing for a block of memory.

Parameters:
__td The transaction descriptor
__start The start address of the block of memory
__size The size in bytes of the block of memory

Definition at line 128 of file intelabi.c.

int _ITM_CALL_CONVENTION _ITM_getThreadnum ( void   ) 

Get the thread number which the TM logging and statistics will be using.

Definition at line 97 of file intelabi.c.

References mtm_tx_s::thread_num.

mtm_tx_t* _ITM_CALL_CONVENTION _ITM_getTransaction ( void   ) 

Returns:
A pointer to the current transaction descriptor.

Definition at line 83 of file intelabi.c.

_ITM_transactionId _ITM_CALL_CONVENTION _ITM_getTransactionId ( _ITM_transaction __td  ) 

A method to retrieve a tag that uniquely identifies a transaction

Parameters:
__td The transaction descriptor

Definition at line 75 of file intelabi.c.

References mtm_tx_s::id.

int _ITM_CALL_CONVENTION _ITM_initializeProcess ( void   ) 

Initialization, finalization Result of initialization function is zero for success, non-zero for failure, so you want if (!_ITM_initializeProcess()) { ... error exit ... }

Definition at line 144 of file intelabi.c.

_ITM_howExecuting _ITM_CALL_CONVENTION _ITM_inTransaction ( _ITM_transaction __td  ) 

Is the code executing inside a transaction?

Parameters:
__td The transaction descriptor.
Returns:
1 if inside a transaction, 0 if outside a transaction.

Definition at line 61 of file intelabi.c.

References mtm_tx_s::status.

const char* _ITM_CALL_CONVENTION _ITM_libraryVersion ( void   ) 

Version checking

Definition at line 54 of file intelabi.c.

void _ITM_CALL_CONVENTION _ITM_registerThrownObject ( _ITM_transaction td,
const void *  __obj,
size_t  __size 
)

Register the thrown object to avoid undoing it, in case the transaction aborts and throws an exception from inside a catch handler.

Parameters:
__td The transaction pointer.
__obj The base address of the thrown object.
__size The size of the object in bytes.

Definition at line 135 of file intelabi.c.

void _ITM_CALL_CONVENTION _ITM_userError ( const char *  errString,
int  exitCode 
)

A method to print error from inside the transaction and exit

Parameters:
errString The error description
exitCode The exit code

Definition at line 120 of file intelabi.c.

int _ITM_CALL_CONVENTION _ITM_versionCompatible ( int   ) 

Call with the _ITM_VERSION_NO macro defined above, so that the library can handle compatibility issues.

Definition at line 47 of file intelabi.c.


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