views:

75

answers:

2

Hi,

I wrote tcl script as an glue between different apps which are computationally intensive.
When I run top command I see that 2 cpu's are 100% utilized.
The one is for the tcl and the second is for the application I am running.
The question is: why the tcl is utilizing fully one of the processors when the binary application is heavily computationally?

Thx.

A: 

More specifics would be helpful: which tools are you speaking about? For what purpose do they provide a Tcl interface? Did you create the Tcl script? How do you invoke it?

+1  A: 

If I were guessing I'd say the TCL script is polling something; returned messages perhaps? The 'right' way is to use interrupts, but that's always a fun TCL exercise. On the other hand there's a possibility the TCL isn't the problem at all - if you can get at the TCL source, put "after 1000000" or the like after the tool call; then you'll know if it's really the TCL you have, or something else masked by the DLL.

If there's no good way to edit the vendor TCL then perhaps you can use TCL on a 'slow' remote machine, and call the application itself on the 'fast' machine using SSH or telnet.

Tim Crone
thx for the answer, the tcl is waiting for the results and that was the issue. thx one more time.
name