On Sun Aug 03 16:11:56 2008, Neopallium wrote:
> 
> I have separated the bugfixes into different patch files and included
> one
> large patch file (all_changes.patch) that includes all the other
> patches.
> 
> fix_assignlist.patch:
> In Lua you can swap variables using an assignlist like this:
> v1,v2 = v2,v1
> The problem is that both v1 & v2 would equal the value in v2.  The
> value in v1
> was lost.  To fix this I added the use of temp registers to store the
> values
> before the final assignments.  The life.lua script was effected by
> this bug.
> 
> test_swap_assignlist.patch:
> Adds test case for bug fixed in 'fix_assignlist.patch'
> 
both applied in r29995.

> fix_environ_reg_cache.patch:
> Accessing a global in Lua after using a logical "and" operation would
> cause a
> crash if the second operand was a global variable and the first
> operand was
> false.  The POST pass was caching the register name used to access
> global
> variable to speed up global access.  That cached register needs to be
> cleared
> after method calls and branches.  It wasn't being cleared after the
> logical "and" operation so the next global access try using a register
> that
> will not be set if the branch wasn't taken.  This bug is why the
> life.lua
> script was crashing.
> 
> test_global_access.patch:
> Adds test case for bug fixed in 'fix_environ_reg_cache.patch'
both applied in r29997.

> 
> fix_fornum.patch:
> The loop count variable in "for" loops was being passed by reference
> instead
> of by value as is required for numbers in Lua.  To fix this I added a
> temp
> register for the real loop counter and cloned that value into the
> count
> variable that is visible to the loop code.  This bug effected the
> sieve.lua
> script making it return only 1 prime.
applied in r30005.

> 
> fix_lua_bytecode_loader.patch:
> This patch fixes the loading of Lua bytecode files.
applied in r29998.

> 
> test_fix_bisect_output.patch:
> The expected output for the bisect.lua script seems to be wrong.  I
> have
> tested that script with Lua 5.1.3 on three different computers and the
> output
> doesn't match the expected output for this test case.  Even the "Live
> demo"
> on lua.org: http://www.lua.org/cgi-bin/demo matches the output from my
> three
> computers.  This patch updates the expected output file so it matches
> the
> output from the official Lua output.
Applied with modification in r30009.
The current output reference was created with Lua 5.1.3 on Windows (from
LuaBinaries).
The code of the Lua interpreter is extremely portable, but not the output.
So, now there are 2 reference outputs.

Thanks again for these real improvements.

François.

Note: the ticket #57504 (mktime vs 64bits) was prematurely closed.
See http://rt.perl.org/rt3/Ticket/Update.html?id=57504

> 
> test_from_lua.patch:
> Removes TODO on bisect & sieve tests.  Changes skip message for life
> test
> from "crash" to "uses to much memory with default runcore"
> 
> The life.lua script uses too much memory (>1 Gbyte) when using the
> slow/fast/computed-goto cores and even when the JIT is turned on.
> Using
> the "--leak-test" option doesn't show any leaks and the "--gc-debug"
> option
> doesn't improve memory usage.  The CGP & switched cores don't have
> this
> problem they use less then 60 Mbytes.
> 
> diffstats for all_changes.patch:
>  src/POSTGrammar.tg       |   14 ++++++++++----
>  src/lib/luaaux.pir       |    2 +-
>  t/assign.t               |   30 +++++++++++++++++++++++++++++-
>  t/expr.t                 |   18 +++++++++++++++++-
>  t/test-from-lua.t        |   12 +-----------
>  t/test/bisect-output.txt |    6 +++---
>  6 files changed, 61 insertions(+), 21 deletions(-)
> 

Reply via email to