lua-users home
lua-l archive

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

On Wed, Jul 1, 2020 at 7:51 AM Pierre Chapuis <> wrote:
> It honestly looks like a GCC bug. Building with any optimization level
> other than the default of O2 (I tried with O0, O1, O3 and Os) prevents
> the crash.

I built GCC 10.1.0 from source on Debian 10. I can reproduce the
problem now. Looking at the 10.1.0 release notes I saw that the
compiler implements more aggressive automatic inlining. I rebuilt the
Lua interpreter with the "-fno-inline" flag and the crash went away.
It's a workaround, but you may want to run the test suite, who knows
what other problems are lurking in a Lua interpreter built with gcc

There are downsides to living on the bleeding edge, gcc 10.1.0 was
released on May 7. I have never used Arch Linux, if possible I'd
suggest rolling back the compiler to gcc 8 or 9.

I'll build the tip of the release/gcc-10 branch. That'll take a good
while on my slow machine. Perhaps this issue has been fixed, there are
lots of bug fix commits in that branch post 10.1.