TinySTM  1.0.5
Data Fields
stm_tx_attr Union Reference

Transaction attributes specified by the application. More...

Data Fields

struct {
   unsigned int   id: 16
 Application-specific identifier for the transaction. More...
 
   unsigned int   read_only: 1
 Indicates whether the transaction is read-only. More...
 
   unsigned int   visible_reads: 1
 Indicates whether the transaction should use visible reads. More...
 
   unsigned int   no_retry: 1
 Indicates that the transaction should not retry execution using sigsetjmp() after abort. More...
 
   unsigned int   no_extend: 1
 Indicates that the transaction cannot use the snapshot extension mechanism. More...
 
}; 
 
int32_t attrs
 All transaction attributes represented as one integer. More...
 

Detailed Description

Transaction attributes specified by the application.

Field Documentation

int32_t stm_tx_attr::attrs

All transaction attributes represented as one integer.

For convenience, allow (stm_tx_attr_t)0 cast.

unsigned int stm_tx_attr::id

Application-specific identifier for the transaction.

Typically, each transactional construct (atomic block) should have a different identifier. This identifier can be used by the infrastructure for improving performance, for instance by not scheduling together atomic blocks that have conflicted often in the past.

unsigned int stm_tx_attr::no_extend

Indicates that the transaction cannot use the snapshot extension mechanism.

(Working only with UNIT_TX)

unsigned int stm_tx_attr::no_retry

Indicates that the transaction should not retry execution using sigsetjmp() after abort.

If no attributes are specified when starting a transaction, the default behavior is to retry.

unsigned int stm_tx_attr::read_only

Indicates whether the transaction is read-only.

This information is used as a hint. If a read-only transaction performs a write, it is aborted and restarted in read-write mode. In that case, the value of the read-only flag is changed to false. If no attributes are specified when starting a transaction, it is assumed to be read-write.

unsigned int stm_tx_attr::visible_reads

Indicates whether the transaction should use visible reads.

This information is used when the transaction starts or restarts. If a transaction automatically switches to visible read mode (e.g., after having repeatedly aborted with invisible reads), this flag is updated accordingly. If no attributes are specified when starting a transaction, the default behavior is to use invisible reads.


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