streamich / ass-js Goto Github PK
View Code? Open in Web Editor NEWAssembler.js — X86_64 and Ethereum
Home Page: https://www.npmjs.com/package/ass-js
License: The Unlicense
Assembler.js — X86_64 and Ethereum
Home Page: https://www.npmjs.com/package/ass-js
License: The Unlicense
When the sub
instruction is used, it is encoded as an adc
(current npm version)
var assjs = require('ass-js');
var asm = assjs.X64();
asm._('sub', ['rax', 0x42]);
asm._('sub', ['rax', 0x4242]);
asm._('sub', ['rax', 'rbx']);
asm._('sub', ['rbx', 0x42]);
asm._('sub', ['rbx', 0x4242]);
asm._('sub', ['rbx', 'rbx']);
console.log(asm.toString());
console.log(asm.compile());
Code:
000 main:
001 subq rax, 0x42 ; 000000|000000 0x48, 0x83, 0xD0, 0x42 4 bytes
002 subq rax, 0x00004242 ; 000004|000004 0x48, 0x15, 0x42, 0x42, 0x00, 0x00 6 bytes
003 subq rax, rbx ; 00000A|00000A 0x48, 0x11, 0xD8 3 bytes
004 subq rbx, 0x42 ; 00000D|00000D 0x48, 0x83, 0xD3, 0x42 4 bytes
005 subq rbx, 0x00004242 ; 000011|000011 0x48, 0x81, 0xD3, 0x42, 0x42, 0x00, 0x00 7 bytes
006 subq rbx, rbx ; 000018|000018 0x48, 0x11, 0xDB 3 bytes
Encoding:
<Buffer 48 83 d0 42 48 15 42 42 00 00 48 11 d8 48 83 d3 42 48 81 d3 42 42 00 00 48 11 db>
Expected encoding:
<Buffer 48 83 e8 42 48 2d 42 42 00 00 48 29 d8 48 83 eb 42 48 81 eb 42 42 00 00 48 29 db>
Hey there,
I was looking at your project and I couldn't figure out a reason as to why I would (and what, rather) implement with this.
Would you have any example that would clarify why someone would use ass-js ? [this sounds terrible]
Thank you!
master
branch failed. 🚨I recommend you give this issue a high priority, so other packages depending on you could benefit from your bug fixes and new features.
You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can resolve this 💪.
Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.
Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the master
branch. You can also manually restart the failed CI job that runs semantic-release.
If you are not sure how to resolve this, here is some links that can help you:
If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.
The npm token configured in the NPM_TOKEN
environment variable must be a valid token allowing to publish to the registry https://registry.npmjs.org/
.
If you are using Two-Factor Authentication, make configure the auth-only
level is supported. semantic-release cannot publish with the default auth-and-writes
level.
Please make sure to set the NPM_TOKEN
environment variable in your CI with the exact value of the npm token.
Good luck with your project ✨
Your semantic-release bot 📦🚀
@streamich
sorry: I see no email to address this rather than in issues:
How well (and with how much work) would this assembler be able to mock/run the Ethereum EVM? https://github.com/ethereumjs/ethereumjs-vm
the opcodes are in https://github.com/ethereumjs/ethereumjs-vm/blob/master/lib/opcodes.js
This is a wildly fascinating idea to me, but since there's no licensing noted anywhere I'm hesitant to do anything with it, since it's "in limbo", legally speaking.
Would you be willing to specify an open source license in the project?
I personally use the Very Open License in all my code (the Unlicense is very similar), but Choose A License will walk you through the more popular options.
I just came across it and only briefly skimmed the readme.
In the sample code, it declares asm, but the very next line says code.compile
. I’m not sure if it means asm.compile
or something else.
Anyway, I’m just genuinely curious. Thanks for the hard work!
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
These updates have been manually edited so Renovate will no longer make changes. To discard all commits and start over, click on a checkbox.
package.json
fast-extend ^0.0.2
jest 29.7.0
jest-tap-reporter 1.9.0
ts-jest 29.1.2
typescript 5.4.5
ts-node 10.9.2
gulp 5.0.0
gulp-typescript 5.0.1
mkdirp 3.0.1
coffee-register 2.2.0
static-buffer 1.0.1
rimraf 5.0.5
ethereumjs-vm 4.2.0
semantic-release 23.0.8
@types/node 20.12.7
@types/jest 29.5.12
mol-conventional-changelog 1.4.3
.travis.yml
node 9
node 8
node 7
node 6
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.