Intel® Embree Ray Tracing Kernels
Discussion forum on the open source ray tracing kernels for fast photo-realistic rendering on Intel® CPU(s)
280 Discussions

BVH's memory consumption is not adjusted at the end of the build

Yvain_Raeymaekers
484 Views
Hi,
I am using Embree under Windows and I have noticed that the displayedevaluation of the memory consumption of the BVH did not match its actual size in memory.
Digging a bit deeper, I have found that the implementation of the functionalignedRealloc() of platform.cpp did not do anything (it just returns the pointer).
So the BVH's memory footprint is not reduced at the end of the build as it is supposed to.
Why did you not use the win32 function _aligned_malloc() for its implementation. Is there something wrong with it or is it just an omission ?
Thanks.
0 Kudos
2 Replies
SvenW_Intel
Moderator
484 Views
You are right, the _aligned_malloc, _aligned_realloc, _aligned_free functions, are the better choice. We will fix this in an update.
0 Kudos
SergeyKostrov
Valued Contributor II
484 Views
>>...Why did you not use the win32 function _aligned_malloc() for its implementation...

Itis not a Win32 API function.

It is a CRT-function and, in case of a Visual Studio 20xx,it "unwraps" to _mm_malloc().

...
#define _mm_malloc(a, b) _aligned_malloc(a, b)
...

Note: CRT- C Run-Time
0 Kudos
Reply