Can’t load this website, what is it?
Thanks for your help my good man.
This is so nice… Thanks.
It seems like reading the book is the only way. I shall do just that.
Understood. Thanks. I really wish they would allow people to upload their own games. Kinda like that old website (Newgrounds? idk).
++A; thanks! So, in a domain-specific language, like ASDL which I implemented, it’s mostly the denotational semantics at work, but in a GPL like C, it’s mostly operational. Am I right?
btw if you got the time, could you pls explain axiomatic semantics, that would be great. I don’t at all understand this one. Thanks.
This statement is completely wrong. Like, to a baffling degree. It kinda makes me wonder if you’re trolling.
No I just struggle at getting my meaning across + these stuff are new to me. What I meant was ‘Go does memory management LIKE a VM does’. Like ‘baking in the GC’. Does that make sense? Or am I still wrong?
@Ferk @FizzyOrange @posgamer @reflectedodds @ExperimentalGuy: There are errors in what I said. I admit I am not an expert. I will come back with better explanations for my stance, after I have read more about it.
First off, I apologize if I did not add a disclaimer saying I could be wrong. But given this, what is exactly the difference between denotaional and operational semantics? I base what I said on [my understanding of books about language theory. But it seems like I got the wrong gist. Where do you recommend I start?
PS: I’ll add a void to the post rn.
First, tell me what you mean by ‘closure’. I did not mean ‘closure’ as an operational function literal. Keep that in mind.
If you use JVM 8 yes. Use Zero.
I think forks of it are being developed. I found a fork under active development, but I can’t seem to find it.
I know about all this — I actually began implementing my own JVM language a few days ago. I know Android uses Dalvik btw. But I guess a lot of people can use this info; infodump is always good. I do that.
btw I actually have messed around with libgcc-jit and I think at least on x86, it makes zero difference. I once did a test:
– Find /e/ with MAWK -> 0.9s – Find /e/ with JAWK -> 50s.
No shit! It’s seriously slow.
Now compare this with go-awk: 19s.
Go has reference counting and heap etc, basically a ‘compiled VM’. I think if you want fast code, ditch runtime.
I think that happens when app developers learn2optimize. Stop using interpreted bytecode languages on small processors!
My man we have UNIX because PDP-11 was expensive!
Hey now, I am just a yokel from Mazar-Sharif, New York who sells dingbat carcasses for infant consumption, but does Android even use JVM? I was under the consumption it uses Dalvik? Let me consume a dingbat – ok, so who cares what “java” gets compiled to, JIT, AOT even tree-walked, we’re talking about JVM here. Here: https://sourceforge.net/projects/jasmin/ An ancient JVM bytecode assembler.
I think by ‘GADTs’ you mean an AST (could be mistaken). In that case, it would not be a bytecode interpreter, it would be a tree walker. In most languages, an AST is translated down to bytecode, and passed to a VM execution engine. How this engine deals with closures is highly compliant on the architecture of the AST.
First, keep this in mind: A closure is just a closure at the higher-level. Job of the AST is to translate it down to ta more abstract form, thus, a closure would most probably be inlined. Otherwise, it will be a global subroutine defined somewhere on the stack. It never makes sense not to inline closures, unless that closure is a ‘hotzone’, e.g. frequently used, in whcih case you should most obviously define as a subroutine, and if possible, JIT.
A VM lke NekoVM has a higher-order, terse IR with which you can handle closures like you do in JS.
Don’t conflate higher-order constructs with intermediate representations. If you are interested to see a VM development in progress, star my RuppVM. Still early though. But i tend to work on it actively.
Thanks.
Are you specifying everything beforehand? If not, I’d recommend locking in on an ISA with stack effect pre-determined. Also, minimize as much as you can.
First off: Read Xia-Feng Li’s excellent book if you have not.
Then.
Here are some minimization tips I am doing for my RuppVM. I just began working on it less that 24 hours ago. But the tips are based on over 6 months of off-and-on trying to make a VM, and failing. I am sure this one will take, because of these minimization efforts:
ISA.txt
file, look at what I am doing for FFI. You don’t need intricate type mappings for the FFI. Just register a ‘hook’ to an address in memory (or ELF).These variables are not exactly portable, but you can use them, abuse them, etc:
extern etext
-> First address past the text segment;extern edata
-> First address past the initialized data segment;extern end
-> end of bssI think there are portable libraries for handling ELFs and PEs. You could also write your own Assembly code for it. For loading functions from files, for the FFI, these help a lot.
Another aspect you should implement is a ‘signal trampoline’. This trampoline will help handle signals from the OS, and hook it to your green threads.
Now, don’t take these as gospel. I am sure you know most of these already. But in case there’s new info, feel free to adapt it.
Star RuppVM, I will be adding a lot of stuff to it soon.
EDIT: I looked, there does not seem to be any ‘portable’ libraries for handling PE and ELF with the same interface. I guess ther can’t be, two different beasts.
EDIT 2: The FFI could prove to be much more complex than I thought? There’s libffi though.
Removed by mod