Page 1 of 1

Lua version used for Hollywood?

Posted: Tue Apr 18, 2017 1:41 pm
by SamuraiCrow
Hello!

In an effort to try to make Hollywood faster on the 68k Amiga models I wanted to try different compiler options on the Lua that was used as the basis for Hollywood. Specifically, I wanted to try out https://github.com/bebbo/amigaos-cross-toolchain which is based on GCC 6.2 with some custom passes added to the backend. I found a mention on Lua: user projects website that claims it is 5.0.2 so that is what I'm going to tinker with for now. I've been googling for a while so I'd better start testing. I see that 5.0.3 is out now too if there is a bugfix in it I'll check it out.

Cheers!

Re: Lua version used for Hollywood?

Posted: Tue Apr 18, 2017 5:26 pm
by p-OS
The entry in Lua user projects seems to be quite old.
But according to HW7 docs (chapter Credits) ist is still Lua 5.02

Re: Lua version used for Hollywood?

Posted: Tue Apr 18, 2017 5:42 pm
by SamuraiCrow
Thanks! Now I just have to figure out how to run the cross-compiler-toolchain build script. The installer is in Python but lacks the plugin to unpack an LHa file at this time.

Re: Lua version used for Hollywood?

Posted: Tue Apr 18, 2017 6:40 pm
by airsoftsoftwair
Yes, it is still Lua 5.0.2 but with lots of modifications, see here for an overview.

Re: Lua version used for Hollywood?

Posted: Wed Apr 19, 2017 12:30 pm
by SamuraiCrow
Thanks airsoftsoftwair!

I've gotten the M68k GCC 6.2 cross-toolchain to compile on my Linux box. Now that I know which version of Lua to use as a benchmark to test the C compiler I'll have to clear up a duplicated definition in the default includes in the toolchain and compare to the VBCC code. I hope this produces some cleaner code so Hollywood will work better on a 68k Amiga.

Re: Lua version used for Hollywood?

Posted: Wed May 31, 2017 6:50 pm
by SamuraiCrow
After having looked into LuaJIT, I see that it requires Lua 5.1 syntax for variable argument (vararg) formatting. How hard would it be to switch to LuaJIT 2.0.5? If it's easier than I think, it might be practical for a third party (like some friends and I) to write a 68k backend for it. If it's hard we won't even bother.

Re: Lua version used for Hollywood?

Posted: Thu Jun 01, 2017 11:56 pm
by airsoftsoftwair
I don't think a switch to LuaJIT is feasible because the 5.0.2 VM used by Hollywood has been massively hacked. That's also why it's pretty much stalled at 5.0.2. The goal was to be completely compatible with my custom VM which was used before Hollywood 2.0. That's why Hollywood's Lua VM supports all kinds of exotic stuff like Goto() and Gosub() and internally it's really a major hack. So a switch to LuaJIT isn't possible without going to great pains.