[LLVMdev] R600/SI build failure on Leopard (Use of C++11)

Christian König christian.koenig at amd.com
Tue Nov 26 02:31:57 PST 2013


Am 26.11.2013 11:01, schrieb Tim Northover:
>> Is that safely portable?  ie is it required that pre-C++11 std:vector be implemented such that the data is stored contiguously in a realloc'd array?
> Yep. Very first paragraph of the std::vector description (23.2.4p1): "
> The elements of a vector are stored contiguously, meaning that if v is
> a vector<T, Allocator> where T is some type other than bool, then it
> obeys the identity &v[n] == &v[0] + n for all 0 <= n < v.size()".
>
> Cheers.
>
> Tim.

With std::vector it is indeed guaranteed that the data is stored in 
continuous memory.

But at this point a "SmallVector<SDValue, 4>" is probably more 
appropriate anyway and there "data()" is obviously defined.

Just a copy & paste error, should I make a patch for this or does 
anybody else already did one?

Cheers,
Christian.




More information about the llvm-dev mailing list