Comments (13)
Does anyone in this issue still care about this?
I've had success building on PowerPC (which is a platform not supported by LuaJIT) with this PR: #320
from terra.
I would like to have this capability.
from terra.
It's something we eventually want to do, but have no concrete roadmap for due to some unknowns.
The LLVM JIT is being converted from their old JIT to MCJIT. We use the old JIT because it works well as an incremental compiler, something that hasn't been integrated into MCJIT yet. Unfortunately, the old JIT only really works on x86. Hopefully we will be able to use MCJIT soon, which will remove the blocker.
The second issue is that LLVM doesn't handle C calling convensions, so our code generator (tcompiler.cpp) will need to be updated with ARM calling conventions. This shouldn't be too difficult once JITing on ARM is possible.
from terra.
Could we get any update on that?
from terra.
Yeah, we have some preliminary arm support now. We've tested it on Nvidia's
Tegra K1 board, and at one point we were able to get it running on the
Raspberry Pi, but I don't have one set up right now to test with the latest
release.
However, we haven't implemented the entire ARM calling convention yet. When
calling C functions from Terra, and Terra functions from Lua, this
limitation restricts what types can be passed and returned. In particular,
structs and arrays cannot be passed/returned as values (pointers to them
are fine), and you cannot return multiple values from Terra (they are
packed in structs). When calling Terra functions from Terra there are no
restrictions.
It's often the case that you can work around the calling convention stuff,
since most C APIs don't pass structs by value, and you can avoid creating
code that does it yourself.
this is some code to get it running on the Tegra K1 board running ubuntu:
sudo add-apt-repository universe
sudo apt-get install build-essential llvm-3.4-dev clang-3.4
libclang-3.4-dev git
git clone https://github.com/zdevito/terra
cat > terra/Makefile.inc <<END
TERRA_CXX = g++
TERRA_CC = gcc
LLVM_CONFIG = $(shell which llvm-config-3.4)
END
make -C terra
On Fri, Nov 14, 2014 at 8:10 AM, Bartek Banachewicz <
[email protected]> wrote:
Could we get any update on that?
—
Reply to this email directly or view it on GitHub
#53 (comment).
from terra.
There is an open pull request regarding ARM. Should it be closed?
from terra.
Yes, I closed that, thanks. This issue will stay open until all of our functionality is supported on ARM.
from terra.
Pinging for a query to status. Can a build off of master on an ARM architecture yield a working interpreter? What are the largest known missing features?
I'm very deep on the ARM side at present - - if a build is easy to achieve, I would be happy to contribute ARM builds and test pass/fail reports.
from terra.
I think that Terra should support the other architectures in general, but it remains a question of effort vs benefits, I suppose.
from terra.
If LuaJIT supports your platform, this should pretty much work out of the box (with a sufficiently recent version of LLVM).
For platforms LuaJIT doesn't support, like I mentioned in the last comment, you'll need to use PR #320, which continues to be a work in progress but is feature-complete enough that we've been able to use it for doing runs on the Summit supercomputer (a PPC64le machine).
from terra.
I haven't specifically tested ARM, but we've had success using PR #320 on PPC64le for a long time now, so I'm going to close this as "good enough".
If there are any actual issues with ARM support, please open new issues.
from terra.
Just wanted to update this to add: ARM64 binaries are included in release 1.0.1 and pass roughly 96% of the test suite (as tested on a Raspberry Pi with Ubuntu 22.04).
from terra.
As of 1.0.5 Terra now fully supports AArch64.
from terra.
Related Issues (20)
- SPIRV Support HOT 2
- Building and running Terra on Termux HOT 6
- cconv_more.t fails on Apple M2 with N=10 HOT 1
- "CommandLine Error: Option 'help-list' registered more than once!" HOT 4
- Miscompilation with LLVM > 6 HOT 5
- Tracking LLVM removal blockers for future LLVM deprecations
- Select native target triple and architecture
- Restore CI test for dynamic linking
- constantinits.t breaks on LLVM 17 Linux HOT 2
- Can't define function over std.Vector(StructType) without building the type first HOT 1
- hello.t and a few other tests broken on llvm15 HOT 4
- question: using Terra to transpile C to Rust/Go HOT 2
- sprintf standard library core dump HOT 4
- Windows CI on Github Actions is breaking nondeterministically HOT 1
- Compile time regression in compile_time_array.t on LLVM 17
- Nondeterministic failure in fakeasm.t in LLVM 17 on Linux
- Known issues in LLVM 17
- Cannot find system headers on macos apple silicon
- Terra is looking for Windows maintainers
- setinlined not working in JIT mode on LLVM >= 17 HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from terra.