lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Thu, Jan 5, 2017 at 10:50 AM, Roberto Ierusalimschy
<roberto@inf.puc-rio.br> wrote:
>> Maybe Lua should have 13 seconds timeout to make the competition honest?
>
> The numbers you gave were these:
>
> 2    C, Pascal
> 3    Brainf**k, C#, COBOL, D, PyPy
> 4    F#, Go, Java
> 5    Fortran, Haskell, Smalltalk, Tcl, VB.NET
> 7    Scala
> 8    Clojure
> 9    Perl, PHP
> 10   Javascript, Julia, Python, R, Ruby
> 12   Common Lisp, Erlang, Lua 5.2
>
> The whole table seems quite arbitrary. Fortran is equivalent to
> Smalltalk and Tcl?  Lua is slower than PHP? Brainfuck is faster than
> [whatever]?
>
> -- Roberto

I'm a little surprised by Fortran's position considering it OUGHT to
be top tier. I'm also surprised that VB.NET doesn't class alongside C#
since they're the same VM.

That said, BF is actually surprisingly fast for certain classes of
problems. A naive BF interpreter is obviously really slow, but the
current best-in-class BF implementations translate to C and convert
idiomatic expressions into more compact forms -- e.g. ++++++++ gets
translated into something like "*p += 8;" and [->+<] gets translated
into *(p+1) += *p; *p = 0;

I suspect some of that list might be handicaps based not only on the
capabilities of the language but on the capabilities of the hackers
that usually submit solutions using that language.

/s/ Adam