[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: RE: Lua Benchmark
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Wed, 21 Jul 1999 10:33:34 -0300 (EST)
>From lua-l@tecgraf.puc-rio.br Wed Jul 21 04:08:34 1999
>From: "Vincent PENQUERC'H" <vpenquerch@cr2a-di.fr>
>Why do using local variables is so much faster ?
>Is this due to tag methods ?
If you look at the code in lvm.c, you'll see that using a local variable
is quite simple (search for 'case PUSHLOCAL'), whereas using a global variable
(search for 'case GETGLOBAL') needs a call to luaV_getglobal (yes, because of
tag methods).
--lhf