msvcp90: Add implementation of _Concurrent_vector_Internal_clear.
Signed-off-by: Hua Meng <161220092@smail.nju.edu.cn> Signed-off-by: Piotr Caban <piotr@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
2abdbe2118
commit
38b2acaedd
|
@ -1987,8 +1987,22 @@ DEFINE_THISCALL_WRAPPER(_Concurrent_vector_base_v4__Internal_clear, 8)
|
||||||
MSVCP_size_t __thiscall _Concurrent_vector_base_v4__Internal_clear(
|
MSVCP_size_t __thiscall _Concurrent_vector_base_v4__Internal_clear(
|
||||||
_Concurrent_vector_base_v4 *this, void (__cdecl *clear)(void*, MSVCP_size_t))
|
_Concurrent_vector_base_v4 *this, void (__cdecl *clear)(void*, MSVCP_size_t))
|
||||||
{
|
{
|
||||||
FIXME("(%p %p) stub\n", this, clear);
|
MSVCP_size_t seg_no, elems;
|
||||||
return 0;
|
int i;
|
||||||
|
|
||||||
|
TRACE("(%p %p)\n", this, clear);
|
||||||
|
|
||||||
|
seg_no = this->early_size ? _vector_base_v4__Segment_index_of(this->early_size) + 1 : 0;
|
||||||
|
for(i = seg_no - 1; i >= 0; i--) {
|
||||||
|
elems = this->early_size - (1 << i & ~1);
|
||||||
|
clear(this->segment[i], elems);
|
||||||
|
this->early_size -= elems;
|
||||||
|
}
|
||||||
|
while(seg_no < (this->segment == this->storage ? STORAGE_SIZE : SEGMENT_SIZE)) {
|
||||||
|
if(!this->segment[seg_no]) break;
|
||||||
|
seg_no++;
|
||||||
|
}
|
||||||
|
return seg_no;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ?_Internal_compact@_Concurrent_vector_base_v4@details@Concurrency@@IAEPAXIPAXP6AX0I@ZP6AX0PBXI@Z@Z */
|
/* ?_Internal_compact@_Concurrent_vector_base_v4@details@Concurrency@@IAEPAXIPAXP6AX0I@ZP6AX0PBXI@Z@Z */
|
||||||
|
|
Loading…
Reference in New Issue