TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Embedding LuaJIT in 30 minutes

64 pointsby fcambusalmost 10 years ago

3 comments

foskalmost 10 years ago
LuaJIT is such an amazing just-in-time compiler, faster than the traditional Lua compiler, supported on many platforms and used everywhere where speed and performance are a priority.<p>For example it&#x27;s being used in Redis to provide Lua scripting, and can also be used with nginx (OpenResty). While developing Kong (<a href="https:&#x2F;&#x2F;github.com&#x2F;Mashape&#x2F;kong" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;Mashape&#x2F;kong</a>) we noticed that LuaJIT provided substantial performance improvements.<p>I hope that the recent step down of the main committer won&#x27;t affect the future of the project [1].<p>[1] <a href="http:&#x2F;&#x2F;www.freelists.org&#x2F;post&#x2F;luajit&#x2F;Looking-for-new-LuaJIT-maintainers" rel="nofollow">http:&#x2F;&#x2F;www.freelists.org&#x2F;post&#x2F;luajit&#x2F;Looking-for-new-LuaJIT-...</a>
评论 #10057469 未加载
评论 #10057732 未加载
评论 #10065690 未加载
vvandersalmost 10 years ago
Lua is such a fantastic language for embedding.<p>I&#x27;ve seen entire game logic done in 200kb on platforms that had less than 32mb of total CPU memory.
aDevilInMealmost 10 years ago
The author informs that the stack is &quot;difficult bit to wrap your head around first&quot;, then makes a bizarre statement &quot;Once again – pushed values are indexed with negative, function arguments with positive numbers.&quot; This is not correct, you can use positive or negative indexes in either case. Positive indexes are absolute and negative are relative to the top of the stack.
评论 #10058849 未加载