Welcome to Intel® Software Network Quick Login | Join | Help |
Search in Intel® Software Network Forums
in Go

intrinsic non transactional memory operations

Last post 05-29-2008, 9:38 AM by MAD\rnaraya. 3 replies.
Sort Posts: Previous Next
 05-15-2008, 1:47 AM 30254878  

intrinsic non transactional memory operations

I'm currently using STM compiler to implement my own containers. However, it seems the compiler is applying some non-transactional version of memory operations such as memset internally. I've made the code as short as possible. The following code causes

tx_warning: tryclass2.cpp(29): a non tm_callable/tm_pure intrinsic function 'memset' called inside __tm_atomic section


I've written my own version of tmmemset, tmmemcpy, etc. The problem is how could I tell the compiler to use my implementation instead of its own?

#include "intel_compatibility.h"

class MyListNode{
public:
    int data;
};



class MyList{
public:

    struct _MyList_impl{

        MyListNode node;

        __attribute__((tm_callable))
        _MyList_impl():node(){}
    };

    _MyList_impl _M_impl;

    __attribute__((tm_callable))
    MyList():_M_impl(){}
};

int main()
{
    __tm_atomic{
        MyList a;
    }
}


Thanks for all your great work and patience.
 
 05-19-2008, 9:36 AM 30255039 in reply to 30254878  

Re: intrinsic non transactional memory operations

Use -fno-builtin so the standard intrinsic library functions will not be recognized
 
 05-28-2008, 9:40 PM 30255708 in reply to 30255039  

Re: intrinsic non transactional memory operations

Well, that works in this case. But it seems I cannot use the intrinsic transactional malloc/free anymore with that switch. Is it possible that I could selectively use the intrinsic functions? Thanks very much.
 
 05-29-2008, 9:38 AM 30255739 in reply to 30255708  

Re: intrinsic non transactional memory operations

Unfortunately transactional malloc/free are recognized as part of our standard intrinsic library functions and disabled with -fno_builtin option is used.  We will consider separation of transactional malloc/free and controlling under a different option.
 
View as RSS news feed in XML

Shortcuts


Tags For This Post

...

Community Tags

...