Better HN
topnewbestaskshowjobs
Log inSign up

LightMachine

2,083 karma · joined Sep 27, 2015 (11y ago) · 346 submissions

Submissions

comment 4y ago · link · parent

Changing it to pure s-expressions would be easy though, I guess just `let` isn't following that rule? I do love the no-parenthesis lets though.

comment 4y ago · link · parent

Yes! The fact HVM can apply a function 2^N times in N steps is still mind-blowing to me. I think solutions to important problems might come from exploiting this fact. Keep in mind you need to use some techniques for that to work. In special, there are 3 important rules. I've just written an overview here: https://github.com/Kindelia/HVM/blob/master/HOW.md#bonus-abu...

comment 4y ago · link · parent

Author here.

HVM is the ultimate conclusion to years of optimal evaluation research. I've been a great enthusiast of optimal runtimes. Until now, though, my most efficient implementation had barely passed 50 million rewrites per second. It did beat GHC in cases where optimality helped, like λ-encoded arithmetic, but in more real-world scenarios, it was still far behind. Thanks to a recent memory layout breakthrough, though, we managed to reach a peak performance of 2.5 billion rewrites per second, on the same machine. That's a ridiculous 50x improvement.

That is enough for it to enjoy roughly the same performance of GHC in normal programs, and even outperform it when automatic parallelism kicks in, if that counts! Of course, there are still cases where it will perform worse (by 2x at most usually, and some weird quadratic cases that should be fixed [see issues]), but remember it is a 1-month prototype versus the largest lazy functional compiler in the market. I'm confident HVM's current design is able to scale and become the fastest functional runtime in the world, because I believe the optimal algorithm is inherently superior.

I'm looking for partners! Check the notes at the end of the repository's README if you want to get involved.

comment 4y ago · link · parent

The reason for the syntax is that HVM aims to be a low level compile target, which sounds confusing because closures make it look very high level, but it should be seen as LLVM IR. It isn't meant for direct human use on the long term. Ideally it will be the compile target of languages like Haskell, Lean, Idris, Agda, Kind (my language) and others. As such, I just went for a syntax that simplifies and speeds up parsing, while still keeping it usable if you need to manually edit: there is no backtracking on this syntax.

comment 4y ago · link · parent

VictorTaelin here. It won't show a speedup because you already optimized it to a low level algorithm manually! The point of that benchmark is to stress-test the cost of overwhelming abstraction. What is really notable is that addition by repeated increment on HVM performs as well as addition with a carry bit. The former is an elegant one-liner, the later is a 8-cases error prone recursive definition. The point is to show how you can often write highly abstract, elegant mathematical definitions, and it will perform as well as a manually crafted version, and that is very cool.

comment 4y ago · link · parent

HVM is the ultimate conclusion to years of optimal evaluation research. I've been a great enthusiast of optimal runtimes. Until now, though, my most efficient implementation had barely passed 50 million rewrites per second. It did beat GHC in cases where optimality helped, like λ-encoded arithmetic, but in more real-world scenarios, it was still far behind. Thanks to a recent memory layout breakthrough, though, we managed to reach a peak performance of *2.5 billion* rewrites per second, on the same machine. That's a ridiculous 50x improvement.

That is enough for it to enjoy roughly the same performance of GHC in normal programs, and even outperform it when automatic parallelism kicks in, if that counts! Of course, there are still cases where it will perform worse (by 2x at most usually, but remember it is a 1-month prototype versus the largest functional compiler in the world). I'm confident HVM's current design is able to scale and become the fastest functional runtime in the world, because I believe the optimal algorithm is inherently superior.

I'm looking for partners! Check the notes at the end of the repository's README if you want to get involved.

comment 4y ago · link · parent

Thank you! Sad this post got no traction. I wonder if Hacker News allows posting again in a future.

248.

Show HN: High-order Virtual Machine (HVM) – A Parallel Functional Runtime(github.com ↗)

150 points · by LightMachine · 4y ago · 13 comments

comment 5y ago · link · parent

Speaking of the subject, if someone DOES want a credential and already knows a lot of CS, are there good online courses that provide sped up process? I have been programming since 20 years ago, am a lead developer at a large company, but have no degree. Sadly some companies like Google do require it to even consider submissions, so I wonder if I should enroll an online course just for the paper.

comment 5y ago · link · parent

That isn't even necessary. I've been exploring GPT-3 for a while and it is completely incapable of any reasoning. If you enter short unique logical sentences like "Bob had 5 apples, gave 2 to Mary, then ate the same amount. How many apples Bob has left?" No matter how many previous examples you give it (to be sure it gets the question), it gets it wrong. It is simply incapable of reasoning about what is going on.

comment 5y ago · link · parent

This mindset kills more people than Hitler. Have a good day.

comment 5y ago · link · parent

You do not understand the situation. Breaking ECDSA would mean everyone gains access to everyone else's private keys. There is no recovery after that, because even if the network is updated to use a quantum-resistant scheme, how do you prove you're the owner of that BTC? And without a central party, who decides you're the rightful owner of your BTC, if 10's of other people insist they own it?

comment 5y ago · link · parent

Well [Kind](https://github.com/uwu-tech/kind) has only one "axiom" (the lambda), so, I don't know? This is a really inspiring thought and I'm glad people are debating it for the content and not attacking Wolfram just because.

comment 5y ago · link · parent

Mining is voting weighted by wasted CPU power. Stake is voting weighted by wealth. That's all, really.

Both are used to build decentralized networks, since they allow it to pick a random participant to order the previous X transactions (aka block), without being susceptible to sybil attacks. PoS is much less energy-hungry than PoW, but it has a problem: how do you distribute money fairly, to begin with? Which is why Ethereum started with a few years of PoW to only then shift to PoS. Pretty clever IMO.

255.

Show HN: Kind, a minimal, efficient, practical proof language(github.com ↗)

2 points · by LightMachine · 5y ago · discuss

comment 5y ago · link · parent

Exactly. This is so infuriating. Whoever let little-endian win made a huge disfavor for humanity.

comment 5y ago · link · parent

How do you find Discord servers for a specific interest?

comment 5y ago · link · parent

Ethics aside, if we could simulate a whole brain, then we could simulate billions of brains and try all sorts of things, something we wouldn't be able to do with physical humans. At least not without being labelled as mass murderers and turning into a bird.

comment 5y ago · link · parent

Just replied to let you know that you have an amazing take on the matter.

comment 5y ago · link · parent

If 75% of the users want something, of course they can do that. They uninstall Bitcoin, implement a new software with the new rules, and install it. This becomes the new "Bitcoin". That is called a hard fork. You can't prevent that because it literally means people just chose to use something else. They may even keep the name and call the new thing Bitcoin, for what it is worth.

261.

List of top tokens, with host platform(coinmarketcap.com ↗)

2 points · by LightMachine · 5y ago · discuss

comment 5y ago · link · parent

That isn't what polymorphism means, polymorphism would be more like Point<Float> and Point<Double> using the same Point definition.

263.

FormCoreJS: A 700-LOC proof language that compiles to ultra-fast JavaScript(github.com ↗)

2 points · by LightMachine · 5y ago · discuss

264.

Goodbye, JavaScript: Formality is now implemented in itself(github.com ↗)

2 points · by LightMachine · 5y ago · discuss

265.

Multiplication with Optimal β-Reduction(github.com ↗)

2 points · by LightMachine · 6y ago · discuss

266.

Multiplication with Optimal β-Reduction(github.com ↗)

1 points · by LightMachine · 6y ago · discuss

267.

Thoughts about Formality(medium.com ↗)

1 points · by LightMachine · 6y ago · discuss

268.

Show HN: Navim browses files on the terminal with minimal amount of keystrokes(github.com ↗)

1 points · by LightMachine · 6y ago · discuss

1
89101112