rtcontrib -n

Hello everybody,

working with rtcontrib, I have problems to use more than one core. While
the main rtcontrib process
works at 100% CPU load, the rtrace processes only work at 5% CPU load.
The reason may be connected with the -x option of rtrace that I don't
understand. This is the rtrace process automatically generated by
rtcontrib:

rtrace -dj .9 -dr 3 -ab 1 -ad 350 -ab 3 -ad 1024 -lw .0003 -ld- -ti
sky_glow -w -h- -x 1 -y 0 -dt 0 -as 0 -aa 0 -o~~TmWdp -PP pfg5s274 -fff
ground.oct
As can be seen, the -x option is set 1 while the -y option is set 0.

Reading the man page of rtrace concerning the -n option, it reads:
"There is no benefit from specifying more processes than there are cores
available on the system or the -x setting, which forces a wait at each
flush."

However, I don't understand what that means or what the -x and -y options
of rtrace do exactly.
How can I reach 100% CPU load also for the rtrace subprocesses?

Thanks for your help.
Wendelin Sprenger

···

___________________________________
Mag.rer.nat. Wendelin Sprenger
Division Thermal Systems and Buildings
Fraunhofer Institute for Solar Energy Systems ISE
Heidenhofstr. 2, 79110 Freiburg, Germany
Phone: +49 (0) 7 61/ 45 88-57 45
[email protected]

Hello Wendelin,

Good sleuth work, but in fact since rtcontrib doesn't employ the -n option of rtrace, the flushing behavior doesn't affect efficiency in this case. The problem is that the controlling process in rtcontrib is often the bottleneck in these calculations. Unless each primary ray sent to rtrace spawns many, many daughter rays, most of the time overall will be spent communicating with and collecting results from the multiple rtrace child processes that the rtcontrib parent process creates.

I have looked at the possibility of changing the way I partition the problem to put more work into the subprocesses, but the logic for that has thus far eluded me. The rtcontrib program is quite complicated, and I would rather not increase its complexity further. The only way I've found to effectively speed up rtcontrib on multiple cores when each rtrace process is churning through many rays quickly is to subdivide the input and reassemble it at the end. This is a bit painful and requires some book-keeping on the part of the user, but for difficult or repetitive problems it may be worth the effort.

Best of luck,
-Greg

···

From: [email protected]
Date: October 13, 2011 2:25:40 AM PDT

Hello everybody,

working with rtcontrib, I have problems to use more than one core. While the main rtcontrib process
works at 100% CPU load, the rtrace processes only work at 5% CPU load.
The reason may be connected with the -x option of rtrace that I don't understand. This is the rtrace process automatically generated by rtcontrib:

rtrace -dj .9 -dr 3 -ab 1 -ad 350 -ab 3 -ad 1024 -lw .0003 -ld- -ti sky_glow -w -h- -x 1 -y 0 -dt 0 -as 0 -aa 0 -o~~TmWdp -PP pfg5s274 -fff ground.oct
As can be seen, the -x option is set 1 while the -y option is set 0.

Reading the man page of rtrace concerning the -n option, it reads:
"There is no benefit from specifying more processes than there are cores available on the system or the -x setting, which forces a wait at each flush."

However, I don't understand what that means or what the -x and -y options of rtrace do exactly.
How can I reach 100% CPU load also for the rtrace subprocesses?

Thanks for your help.
Wendelin Sprenger