<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Too bad you didn't write it in perl, then you could have just used
perlcompile to spit out C code for actual compiling.<br>
<br>
About shell and other interpreted languages, what gets expensive is
looping, since for each loop iteration you must interpret, compile, and
run each lines in that loop. With shell script, add to that forking,
which is expensive too. <br>
<br>
On modern computers, the time saved might not be worth dealing with
recoding your script in C. All the "magic" stuff like back ticks is not
very fun to implement in C. Plus you have to deal with a strictly typed
language, no automatic memory management, etc<br>
<br>
you'd be better off recoding it in perl. then you'll have an easy way
to get it in C and see if that really saves you time.<br>
<br>
<br>
<pre class="moz-signature" cols="72">Daniel Bourque
Systems/Network Administrator
Weather Data Inc

Office (316) 266-8013
Office (316) 265-9127 ext. 3013
Mobile (316) 640-1024
</pre>
<br>
<br>
Gary Baluha wrote:
<blockquote
 cite="mid29f517690706281112o4f7f94e5pc348a2a3196ebca1@mail.gmail.com"
 type="cite">
  <meta http-equiv="Context-Type"
 content="text/html; charset=ISO-8859-1">
I remember reading somewhere in the Hobbit documentation that when an
extension script starts to do a lot of things, it should be coded in a
compiled language such as C, instead of as a shell script.  I have a
custom script that takes a lot of data and converts it into NCV graphs,
and I believe it is at the point where I should consider rewriting it
in C.
  <br>
  <br>
Before I get to far into it, is the hobbitd_sample.c something that I
should look at for this?  I'm not sure if I'm reading the documentation
on it correctly, if it is a good example for an external script.  Has
anyone else had experience in needing to convert a shell script to
C/C++/etc for Hobbit?  I'm just trying to get a rough idea of how much
effort this will require.
  <br>
</blockquote>
</body>
</html>