I try to use __m128i as the value type of an edge-aligned vector with GCC, and I get the following error:
/usr/include/tbb/cache_aligned_allocator.h:105:32: error: request for the member '~ tbb :: cache_aligned_allocator <__ vector (2) long long int> :: value_type in' * p, which is not a -class type 'tbb :: cache_aligned_allocator <__ vector (2) long long int> :: value_type {aka __vector (2) long long int}
The compiler tracks it in the following line in tbb / cache_aligned_allocator.h:
void destroy( pointer p ) {p->~value_type();}
Here is the code that causes the compiler error:
#include <vector>
#include <emmintrin.h>
#include <tbb/cache_aligned_allocator.h>
int main()
{
std::vector<int, tbb::cache_aligned_allocator<int> > success;
std::vector<__m128i, tbb::cache_aligned_allocator<__m128i> > failure;
return 0;
}
Debian, GCC - 4.6.1-2, TBB - 3.0 + r147-1.
Threading Building Blocks, - ?