Patrick Giagnocavo
2018-10-15 14:40:59 UTC
First, thanks for GNU APL!
I have a simple script that I have written, it compares one list of approximately 5000 10-digit phone numbers with another list of 1700 ten-digit phone numbers and tells me which numbers (items) in the second list, are not in the larger list.
So I do the 2 FIO [49] for each file, assigning each to a variable, then
result<- large5klist~smallerlist
(rho)result
47 1 (rho) result (to print it out) ; I know in this case there are 47 results and I want it printed in just 1 column, i.e. one phone number per line
)OFF
when I run this under Linux (a recent svn trunk), without the banner etc., it completes in approximately 0.520 seconds; actually the banner doesn't seem to make much difference in output.
When I run "comm -23 list1.txt list2.txt" it takes 0.016 seconds on the same hardware.
Now, I don't expect such performance, but, is there a way to reduce the time? Is there a way to start APL such that it can "fork" a task to handle this, so that startup time is almost zero?
And (I think about doing this via a web interface) is there a way to run APL under FastCGI? My guess is that the interpreter startup time is the issue, rather than the actual execution of the commands. I will try to test just an "empty" APL startup e.g. a script which contains only )OFF , and see what amount of time that takes.
Cheers
Patrick Giagnocavo
***@zill.net
I have a simple script that I have written, it compares one list of approximately 5000 10-digit phone numbers with another list of 1700 ten-digit phone numbers and tells me which numbers (items) in the second list, are not in the larger list.
So I do the 2 FIO [49] for each file, assigning each to a variable, then
result<- large5klist~smallerlist
(rho)result
47 1 (rho) result (to print it out) ; I know in this case there are 47 results and I want it printed in just 1 column, i.e. one phone number per line
)OFF
when I run this under Linux (a recent svn trunk), without the banner etc., it completes in approximately 0.520 seconds; actually the banner doesn't seem to make much difference in output.
When I run "comm -23 list1.txt list2.txt" it takes 0.016 seconds on the same hardware.
Now, I don't expect such performance, but, is there a way to reduce the time? Is there a way to start APL such that it can "fork" a task to handle this, so that startup time is almost zero?
And (I think about doing this via a web interface) is there a way to run APL under FastCGI? My guess is that the interpreter startup time is the issue, rather than the actual execution of the commands. I will try to test just an "empty" APL startup e.g. a script which contains only )OFF , and see what amount of time that takes.
Cheers
Patrick Giagnocavo
***@zill.net