MCPcopy Create free account
hub / github.com/RenderKit/embree / alignedMalloc

Function alignedMalloc

common/sys/alloc.cpp:15–25  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13namespace embree
14{
15 void* alignedMalloc(size_t size, size_t align)
16 {
17 if (size == 0)
18 return nullptr;
19
20 assert((align & (align-1)) == 0);
21 void* ptr = _mm_malloc(size,align);
22 if (size != 0 && ptr == nullptr)
23 throw std::bad_alloc();
24 return ptr;
25 }
26
27 void alignedFree(void* ptr)
28 {

Callers 15

mallocMethod · 0.85
allocateMethod · 0.85
blockAlignedMallocMethod · 0.85
StackArrayFunction · 0.85
alignedSYCLMallocFunction · 0.85
allocateMethod · 0.85
tbbRadixSortMethod · 0.85
runMethod · 0.85
createPointsFunction · 0.85
device_initFunction · 0.85
createInstanceFunction · 0.85
createTriangulatedSphereFunction · 0.85

Calls 1

_mm_mallocFunction · 0.85

Tested by

no test coverage detected