Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
14 Views

Failing in running test_malloc_compliance

Hi,

I am porting TBB 2.2 to HPUX IA64 platform. As mentioned in the attached file, there are some errors when running the /src/test/test_malloc_compliance.cpp and some other files under test directory. The errors are such that functions such as getpagesize() and other functions are not defined. I included the appropriate header files and it runs test_maloc_functionality fine but when it tries to run test_malloc_compliance it hangs, actually the entire system hangs. I dont know why this happens. Could anyone suggest a method to solve this problem?. If I leave the errors just like that (ie. not define getpagesize() ) then it runs the examples perfectly. Is it necessary that the /src/test/ directory also be built? . Any help would be great!

Thanks,
Johnson
0 Kudos
7 Replies
Highlighted
14 Views

Most probable reason for the entire system hangs is failing to set memory limits. That's strange because in HP-UX man page at http://docs.hp.com/en/B2355-60103/getrlimit.2.html I don't see special notes on RLIMIT_AS support that we use for limiting proposes. You can find more exact information on hang by running test_malloc_compliance with -v key, i.e. LD_LIBRARY_PATH=. ./test_malloc_compliance.exe -v 1.

By the way, output file you attached is identical to the attachment in "ld: (Warning) Unsatisfied symbol" thread.
0 Kudos
Highlighted
Beginner
14 Views

Hi Alexandr,

When test_malloc_compliance.exe is running, the system hangs. Actually there was one thing that I forgot to mention, it was showing an error "ulimit: specified value greater than user allowed". This error was at line no: 39 in /build/test_launcher.sh. I checked the configuration of the system using ulimit -aH and found out that the allowed stack size or maximum is 8152 and the specified value in test_launcher.sh was 10240. I reduced this value to 8000 and thats when this whole error of hanging took place. Hopefully this could bring more light into the problem. Btw I attached the same file since the errors regarding the undefining of getpagesize() and various such errors are present in this file.

Thanks,
Johnson
0 Kudos
Highlighted
14 Views

When test_malloc_compliance.exe is running, the system hangs.

So, could you detect (either using -v or by bisection in a debugger) on which exactly step test_malloc_compliance.exe and the system hang? Another possible useful technique is looking at memory usage by test_malloc_compliance.exe in another terminal window. If it becameunusually high (as you can see limit is 200 MB per thread) it might be sign of setrlimit-releated problem.
0 Kudos
Highlighted
Beginner
14 Views

Hi Alexandr,

I tried running test_malloc_compliance.exe individually using the command ./test_malloc_compliance.exe -v 1, I get the following error
The memory manager cannot access sufficient memory to initialize; exiting

Hopefully this is useful

Thanks,
Johnson
0 Kudos
Highlighted
14 Views

Could you find which exactly MapMemory call returns no memory and what errno it set? By the way, are you map MapMemory to something special or it calls malloc?
0 Kudos
Highlighted
Beginner
14 Views

Hi Alexandr,

I tried using the -v with ./test_malloc_compliance.exe and this is the output I got. I have attached the output with this post.

Thanks,
Johnson
0 Kudos
Highlighted
14 Views

Could you try to comment out NULLReturn call? If it helps, the reason is a problem in memory limit implementation by OS. Then, you can try to create isolated test case agains setrlimit.
0 Kudos