Intel® oneAPI Threading Building Blocks
Ask questions and share information about adding parallelism to your applications when using this threading library.
Announcements
This community is designed for sharing of public information. Please do not share Intel or third-party confidential information here.

What exactly scalable_msize does?

renorm
Beginner
177 Views
Very quick question. Can this fail?
[cpp]ptr = scalable_aligned_malloc(size, alignment);
assert(size==scalable_msize(ptr));[/cpp]
Thanks.
0 Kudos
2 Replies
Alexey_K_Intel3
Employee
177 Views
Yes it can.

You can think of scalable_msize as the biggest size for which scalable_realloc returns the same address that it received.
Ilnar
Beginner
177 Views
[bash]assert(size <= scalable_msize(ptr));[/bash]
Reply