- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi;
I'm currently experimenting with IPP's rendering domain support.
On the ray-tracing sample, when I try to render this ply file:
ftp://ftp.cyberware.com/pub/samples/ms/satva/satva-100.zip
Using openmp multithreading support, the sample crashes while building the parallel kd-tree. (On the KDTreeBuildAlloc line)
This is my command line for using 8 threads (Development machine is core i7 920, but it crashes on a p4 too).
-n 8 j:\ipp\malaysia-100.ply 1024 1024 j:\ipp\malaysia-100.bmp
Note that _OPENMP must be defined, and openmp support should be enabled on compiler (VS 2008 compiler), otherwise the renderer runs on a single thread. (It incorrectly displays 8 threads used message on finish).
Does anybody have an opinion about this? Is the kdtreebuildalloc function really thread safe? I should note that the sample seems to be running on smaller datasets fine.
I'm currently experimenting with IPP's rendering domain support.
On the ray-tracing sample, when I try to render this ply file:
ftp://ftp.cyberware.com/pub/samples/ms/satva/satva-100.zip
Using openmp multithreading support, the sample crashes while building the parallel kd-tree. (On the KDTreeBuildAlloc line)
This is my command line for using 8 threads (Development machine is core i7 920, but it crashes on a p4 too).
-n 8 j:\ipp\malaysia-100.ply 1024 1024 j:\ipp\malaysia-100.bmp
Note that _OPENMP must be defined, and openmp support should be enabled on compiler (VS 2008 compiler), otherwise the renderer runs on a single thread. (It incorrectly displays 8 threads used message on finish).
Does anybody have an opinion about this? Is the kdtreebuildalloc function really thread safe? I should note that the sample seems to be running on smaller datasets fine.
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
It looks to be a memory overflowing error. To process huge models in multithreaded mode, it needs to assign AvailMemory parameter in kd-tree building function appropriately, and prevent memory overflowing error.
The engineer suggested setting this parameter to (Overall available memory)/(numThreads).
Thanks,
Chao
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the reply. It's been over 1 year since I asked that question :) , and I got the same answer from support. (I finished the project using single threaded kd tree construction btw).
The problem here is that available memory is not a solid defined thing, it varies, and memory fragmentation and other unforeseen factors still prevent successful kdtree construction sometimes. (Even if you have the memory).
I think that the AvailMemory parameter should be ditched in future versions and the kd tree constructor code should do the necessary error checking, and returns an error code so that the application never crashes by setting an incorrect AvailMemory parameter.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for the update. I agree that availMemory parameter should be check by the sample. I will forward to the code owner.
Chao

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page