transaction_callable not recognized by compiler

transaction_callable not recognized by compiler

I'm using the STM 4.0 compiler with a new Ubuntu 10.10 installation.

But the compiler doesn't recognize some of the transaction constructs. For example, transaction_safe works fine, transaction_callable creates an error.
Here is some sample code:


int foo(int a){
    return ++a;

void bar(){
    // do nothing

int main(){
    int i;
    #pragma omp parallel for
        int val = i;
	    val = foo(val);
	printf("%dn", val);

The Error Message is:

icc -Qtm_enabled -openmp foo.c -o foo
foo.c(24) (col. 6): error: non transaction ready function "bar" called inside __transaction section
foo.c(18): (col. 5) remark: OpenMP DEFINED LOOP WAS PARALLELIZED.
compilation aborted for foo.c (code 2)

I've checked the compiler. It is the Prototype Edition 4.0.

I would appreciate any suggestions.
Thank you in advance.


2 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

By default __transaction is assumed to be an __transaction[[atomic]] You can only have transaction_safe calls inside these regions. To call a transcation_callable function use __transaction [[relaxed]] { ... bar()...}

Leave a Comment

Please sign in to add a comment. Not a member? Join today