https://github.com/xarantolus/assembly-script
x86-64 Assembler for the browser, supporting a small subset of the GNU Assembler Intel syntax
https://github.com/xarantolus/assembly-script
rust wasm webassembly x86-64 x86-assembly
Last synced: 6 months ago
JSON representation
x86-64 Assembler for the browser, supporting a small subset of the GNU Assembler Intel syntax
- Host: GitHub
- URL: https://github.com/xarantolus/assembly-script
- Owner: xarantolus
- License: mit
- Created: 2022-06-22T06:21:18.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-06-07T08:46:19.000Z (over 2 years ago)
- Last Synced: 2025-02-08T12:17:55.441Z (8 months ago)
- Topics: rust, wasm, webassembly, x86-64, x86-assembly
- Language: Rust
- Homepage:
- Size: 152 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# assembly-script
This is a very basic `x86_64` (very small subset) Assembler based on the [`iced-x86`](https://crates.io/crates/iced-x86) Rust crate. I built it because I couldn't find a version of the GNU Assembler for `x86_64` that worked on the web.I use it in the [MemeAssembly playground](https://github.com/xarantolus/MemeAssembly-playground-vue) to translate `x86_64` Assembly code into its binary representation. This binary representation is then run in the browser.
This project will probably not be useful to you if you don't have very similar goals, e.g. like assembling a minimal `x86_64` subset on the web.
### Build instructions
First make sure you have the Rust toolchain installed.1. [Install `wasm-pack`](https://rustwasm.github.io/wasm-pack/installer/)
2. Clone this repo
git clone https://github.com/xarantolus/assembly-script.git
3. Go to its directory:
cd assembly-script
4. Run `make` to generate the WebAssembly binary
make
5. You can now run a local web server and open [`user.html`](user.html) to see a demo, or see the generated `pkg` directory for info on how to use this in your own projects (or [`user.html`](user.html) as an example)