PhaserKell
Hi, I would like to make in the near future a programming language like https://vlang.io/
I think Elixir is an excellent candidate for this job but I fear two points:
-
Would the performance be sufficient? According to some articles Elixir would be slower than Java, do you have bindings to LLVM?
-
I can’t ask my users to download the project and elixir to run it, do you have a way to get a static binary?
I am interested in GitHub - nicolasdilley/dwarf-interpreter: The compiler for the dwarf's language · GitHub and when I compile it I get a tiny binary of 1 mo, how did it do?
Trending in Questions
Hey guys,
I’ve got a huge CSV ( around 10 GB ) that needs to be processed hourly
Do you guys have any suggestions what is the best prac...
New
Hello!
Could someone please give me a help/sample code, how to delete a file from s3 using waffle/waffle_ecto from Phoenix app.
I creat...
New
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
Anyone here using Honeybadger?
My Honeybadger account is being overwhelmed with noise from some bots. Seeing a lot of
Bandit.HTTPError...
New
So my question is quite simple and i have found no conclusive answer on forum, google or AI.
Should we use :erlang.float for Integer to ...
New
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New
Other Trending Topics
I am happy to introduce the very α version of the new programming language compiled to BEAM.
Welcome Cure.
It has literally three kille...
New
Hobbes is a low-level distributed database for the Elixir programming language.
Hobbes provides a simple, safe, and scalable storage lay...
New
ExRatatui lets you cook up rich terminal UIs in Elixir, powered by Rust’s ratatui via Rustler NIFs. Build interactive terminal applicatio...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
There are three potential reasons for members of this forum to have a look at https://vutuv.de
You are tired or annoyed of LinkedIn.
Yo...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #blog-post
- #elixir-ls
- #elixirconf-us
- #ai
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming










Showing Posts 1 to 8- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
kokolegorille
Hello, welcome to the forum,
I cannot answer all your questions, but I can tell You dwarf-interpreter is using escript.
There is the possibiliy to build a release, a self contained file that could be run on client. Now included in Elixir 1.9 (previously, it was distillery package in charge of this).
It should be preferred when distributing your application
If You search for Erlang LLVM, You might find this pdf.
Erlang and Elixir are known for easy interoperability with other languages.
NobbZ
You can use elixir to write the compiler, I wouldn’t implement the VM in it though.
If though you make your language adhere to the BEAM semantics, then you could just emit beam bytecode or core Erlang and use the BEAM ecosystem for your own purposes.
If though you want to really build your own VM to run the code in, languages that give you better control over your memory are suited much better for that task. In general I wouldn’t want to implement a VM in a language that is runtime garbage collected…
Completely native binaries though are a different kind of beast. I’m currently not aware of LLVM bindings for Erlang or Elixir. And also I wouldn’t want to do native code gen without a library like LLVM…
PhaserKell
Do you have any documents using Beam? On the other hand I could possibly make an interpreter instead or simply a compiler to a JVM / Beam bytecode
NobbZ
What kinds of documents do you mean?
There is the BEAM book and also BEAM wisdom. Perhaps you can find even more valuable resources in Best resources on BEAM internals?.
As well as there might be some wisdom available in the OTP sourcecode or in the two RUST re-implementations ErlangRT and enigma.
You could, but if your language has a lot of mutability or objects (I do infer this from your constant mention of the JVM) or other semantics building on those, then the BEAM is probably not a suitable runtime for your language.
Still, building a compiler for your language on the BEAM is a valid choice.
PhaserKell
I would like to make a general functional programming language purpoose based on asynchronous
NobbZ
Do you continue that post asynchronously? If it’s complete though, I’m not understanding what you exactly mean.
lpil
Hi @PhaserKell! I’ve created a language or two on the BEAM (see GitHub - gleam-lang/gleam: ⭐️ A friendly language for building type-safe, scalable systems! · GitHub) and I’d be happy to talk to you about the process. If you drop by the freenode IRC I can be found in #gleam-lang channel.
rvirding
Hi, I have done 2 languages on top Erlang/BEAM, public languages anyway, LFE (Lisp Flavoured Erlang) GitHub - lfe/lfe: Lisp Flavoured Erlang (LFE) · GitHub and Luerl GitHub - rvirding/luerl: Lua in Erlang · GitHub . The first is a Lisp which keeps the basic Erlang semantics as provide by the BEAM while the second is an implementation Lua implemented in Erlang. [*] Note that the BEAM is designed to run Erlang and most the of the Erlang language features are directly implemented in the BEAM.
Luerl works by compiling down to a VM for which I have then written an interpreter. This to provide the data and code handling which Lua requires but is not provided by the BEAM. Basically Lua has shared, mutable and global data which we don’t do. Yes, the resulting language is slower but the Erlang interface is fast and you get free access to Erlang’s concurrency and parallelism.
[*] I call the first “native” languages on the Erlang Ecosystem, Elixir is of course another one, while the second “non-native” languages.