On Fri, 2004-04-09 at 18:33, Clint Jeffery wrote:
> Kostas,
> 
> A 2x-3x slowdown is a suprising report given that we are talking about the same
> virtual machine with some mods.  It would be good to figure out the cause.
> The # of garbage collections, for example, might be interesting to check.
> 
> Some of Unicon's added features do indeed have a performance cost, but I
> have never seen this degree of slowdown before.  I do in fact hope that
> an internet volunteer or research angel will revive the work on increasing
> Icon and/or Unicon's speed, there is plenty that could easily be done there.

I've done enough testing to convince myself that there is something
unusual about Kostas' set up.  Either different compilers, or different
compile time options, or both - or *something*.  For example, here's
another variant of his test (which does more iterations to increase
the running time in an attempt to get above the noise).  [Note this is
a slightly slower machine than the one I ran tests with earlier, but is
still a Linux RedHat 9 computer.]  As you see from these results, not
only are the times comparable, but the Unicon version is actually
a bit faster!  (The results were similar with three other runs, as
well.)

=======================================================================
->cat baz.icn
# Timing test: Unicon vs. Icon
procedure main(args)
  local L, L2, x
  n := integer(args[1]) | 5
  sum := 0
  every 1 to n do {
    t1 := &time
    every 1 to 10 do {
      L := []
      every 1 to 100000 do put(L, ?0)
      L2 := []
      every x := !L do put(L2, x^2)
      }
    t2 := &time
    write("time: ",t2-t1)
    sum +:= t2-t1
    }
  write("Average time: ",real(sum)/n)
end
->unicon baz.icn
Parsing baz.icn: .
/opt/bin/icont -c   -O baz.icn /tmp/uni97553471
Translating:
baz.icn:
  main
No errors
/opt/bin/icont  baz.u
Linking:
->time baz 8
time: 1640
time: 1710
time: 1700
time: 1700
time: 1630
time: 1690
time: 1700
time: 1660
Average time: 1678.75
baz 8  13.42s user 0.05s system 99% cpu 13.543 total
->icont baz.icn
Translating:
baz.icn:
  main
No errors
Linking:
->r time
time baz 8
time: 2000
time: 2110
time: 2060
time: 2110
time: 2120
time: 2080
time: 2120
time: 2100
Average time: 2087.5
baz 8  16.70s user 0.10s system 99% cpu 16.884 total
->
========================================================================

-Steve
-- 
Steve Wampler <[EMAIL PROTECTED]>


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
Unicon-group mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/unicon-group

Reply via email to