This question already has an answer here:
这个问题在这里已有答案:
- Are std::vector elements guaranteed to be contiguous? 7 answers
- std :: vector元素是否保证是连续的? 7个答案
For a vector of 128bit integer type (std::vector<__m128i> vec;
), are those 128bit integers always put in contiguous memory?
对于128位整数类型的向量(std :: vector <__ m128i> vec;),那些128位整数是否总是放在连续的内存中?
1 个解决方案
#1
2
Yes, that is the the vector
guarantee. All elements will occupy a contiguous memory block, managed by the vector object.
是的,这是矢量保证。所有元素都将占用由矢量对象管理的连续内存块。
#1
2
Yes, that is the the vector
guarantee. All elements will occupy a contiguous memory block, managed by the vector object.
是的,这是矢量保证。所有元素都将占用由矢量对象管理的连续内存块。