"Konstantin" == Konstantin Tokarev <[email protected]> writes:
Konstantin> I think that it could be useful to add support for
Konstantin> predicates written in perl to creduce. In this case
Konstantin> predicate could be loaded as a module reducing run
Konstantin> overhead.
This is an interesting idea. Do you have an example of a predicate that you
would actually like to use like this?
I can think of at least two reasons that someone might want to use a predicate
written in Perl. This first is that somebody might simply want to use Perl
language features --- Perl regexps, existing Perl modules, etc. The second is
to be more efficient at run time.
In thinking about the overhead of shell scripting, consider: If the predicate
has to invoke one (or more) C/C++ compilers, and possibly a validity-checking
tool like Frama-C or KCC, there is a limit to how much efficiency can be gained
by moving the predicate script itself from shell to Perl.
Although I haven't measured it, I would expect that the time spent forking
shells and whatnot for an external predicate script is quite small compared to
the time taken by the compiler and Frama-C/KCC, which are invoked by the
script --- regardless of whether the script is written in shell or Perl.
If you have an example of an "in creduce" predicate that would be much more
efficient for you, I would like to see it!
Thanks ---
Eric.
--
-------------------------------------------------------------------------------
Eric Eide <[email protected]> . University of Utah School of Computing
http://www.cs.utah.edu/~eeide/ . +1 (801) 585-5512 voice, +1 (801) 581-5843 FAX