oneTBB icon indicating copy to clipboard operation
oneTBB copied to clipboard

Use tbbmalloc_proxy

Open 1003581 opened this issue 2 years ago • 4 comments

I had a c++ code that uses tbbmalloc_proxy and this improved the performance alot on Windows 10 I packaged c++ code as python interfaceI using SWIG but it seems that SWIG ignores tbb and just uses the malloc implmenetation from ntddll.dll Any ideas how to overcome this issue ?

1003581 avatar Jul 20 '22 01:07 1003581

@1003581 did you try to use a linker option or header file option from documentation?

no-ponomarev avatar Jul 27 '22 15:07 no-ponomarev

@1003581 did you try to use a linker option or header file option from documentation? I add tbbmalloc_proxy.h to my source code,but it dose not work.

1003581 avatar Jul 29 '22 07:07 1003581

Was this issue resolved? I am having a similar issue. I have a DLL which includes tbbmalloc_proxy.h and when called from Python, TBB's allocator is not being used. Is there any way to use tbbmalloc_proxy.dll without linking Python against it? I am only concerned with allocations inside the DLL in which I have included tbbmalloc_proxy.h.

condonov avatar Nov 24 '22 12:11 condonov

Was this issue resolved? I am having a similar issue. I have a DLL which includes tbbmalloc_proxy.h and when called from Python, TBB's allocator is not being used. Is there any way to use tbbmalloc_proxy.dll without linking Python against it? I am only concerned with allocations inside the DLL in which I have included tbbmalloc_proxy.h.

NO. I overload the new/delete functions for specific classes, this avoids the use of ”tbbmalloc_proxy.h“. Maybe you can see if this helps. https://github.com/swig/swig/issues/2324#event-7022785347

1003581 avatar Dec 08 '22 09:12 1003581