Live data from Hacker News

GHC now runs in the browser

discourse.haskell.org

111–120 of 131 posts

Re: GHC now runs in the browser

#111
post #110
post #107

Earlier quoted context omitted.

> If it becomes bootstrappable, then of course all the above critique is immediately retracted. So basically you're saying you're just trying to get people to carry water for your project? > because there is still literally no way to compile it from source https://gitlab.haskell.org/ghc/ghc/-/wikis/building/#buildin... I cannot comprehend how you can get to the conclusion that a compiler that was litterally made so t…

My project has no need of Haskell, but if anyone puts in the work to make haskell compileable from only public source code my team and I will put in the work to reproduce, package, and maintain it for the community for free as we do most other languages. Your link details building GHC with an existing non reproducible GHC compiler binary compiled by a single individual that must be blindly trusted. Full source bootst…

> Your link details building GHC with an existing non reproducible GHC compiler binary compiled by a single individual that must be blindly trusted.

You mean Hadrian? Its source is shipped with GHC.

Even if you were not to trust Hadrian, the doc also has info about building GHC using make.

> since day 1.

Could it be that languages made around 2010 have learned a thing or two from previous languages?

Re: GHC now runs in the browser

#112
post #94

Earlier quoted context omitted.

The Haskell compiler creates a slightly different output every time you compile a program[1]. This makes it difficult to ensure that the binary that is free-to-download downloaded is actually malware free. If it were easy to check, then you could rest easy, assuming that someone out there is doing the check for you (and it would be big news if malware was found). If you're a hardened security person, then the convers…

Unlike Nix and Guix, Stagex goes much further in that it has a 100% mandate on supply chain integrity. It trusts no single maintainer or computer and disallows any binary blobs. It is thus not possible to package any software that cannot be bootstrapped, reproduced, and signed by at least two maintainers. Haskell and Ada are the only languages not possible for us to support, or any software built with them. Everythin…

How are you bootstrapping a modern C compiler without an existing C/C++ compiler and linker?

Re: GHC now runs in the browser

#113
post #67

Can anyone point to a "practical Haskell" tutorial/book/whatever for people that already know functional programming? I'm in this sour spot where most tutorials are boring to me so I just can't follow through. I know what a monad is. What a typeclass is. Even what HKTs are. I can make sense of "a monad is just a monoid in the category of endofunctors" if I give it a few minutes to unravel the ball of twine... But I w…

I typically recommend LYAH (https://learnyouahaskell.github.io/chapters.html), followed by Real World Haskell (already mentioned).

Re: GHC now runs in the browser

#114
post #94

Earlier quoted context omitted.

Unlike Nix and Guix, Stagex goes much further in that it has a 100% mandate on supply chain integrity. It trusts no single maintainer or computer and disallows any binary blobs. It is thus not possible to package any software that cannot be bootstrapped, reproduced, and signed by at least two maintainers. Haskell and Ada are the only languages not possible for us to support, or any software built with them. Everythin…

How are you bootstrapping a modern C compiler without an existing C/C++ compiler and linker?

In assembly, like stage0 does: https://github.com/oriansj/stage0

Re: GHC now runs in the browser

#115
post #111
post #110

Earlier quoted context omitted.

My project has no need of Haskell, but if anyone puts in the work to make haskell compileable from only public source code my team and I will put in the work to reproduce, package, and maintain it for the community for free as we do most other languages. Your link details building GHC with an existing non reproducible GHC compiler binary compiled by a single individual that must be blindly trusted. Full source bootst…

> Your link details building GHC with an existing non reproducible GHC compiler binary compiled by a single individual that must be blindly trusted. You mean Hadrian? Its source is shipped with GHC. Even if you were not to trust Hadrian, the doc also has info about building GHC using make. > since day 1. Could it be that languages made around 2010 have learned a thing or two from previous languages?

Building GHC regardless of using hadrian or make still requires an existing GHC binary. That is the core trust problem.

GHC has a recursive dependency on itself with no way to go back before that loop.

Re: GHC now runs in the browser

#116

Earlier quoted context omitted.

How are you bootstrapping a modern C compiler without an existing C/C++ compiler and linker?

In assembly, like stage0 does: https://github.com/oriansj/stage0

Technically it is raw x86 machine code in hexadecimal, a scheme called "hex0"

Re: GHC now runs in the browser

#117
post #94

Earlier quoted context omitted.

Unlike Nix and Guix, Stagex goes much further in that it has a 100% mandate on supply chain integrity. It trusts no single maintainer or computer and disallows any binary blobs. It is thus not possible to package any software that cannot be bootstrapped, reproduced, and signed by at least two maintainers. Haskell and Ada are the only languages not possible for us to support, or any software built with them. Everythin…

How are you bootstrapping a modern C compiler without an existing C/C++ compiler and linker?

From 180 bytes of human readable machine code all the way up.

https://codeberg.org/stagex/stagex/src/branch/main/packages/...

Re: GHC now runs in the browser

#118
post #3

Earlier quoted context omitted.

yeah why would anyone want to run code on a website

Loading 50mb of WASM is a big tradeoff just to run code on a website.

For comparison: the homepage of cnn.com right now is 33.37MB on my machine. 16.82MB of which is JavaScript.

Re: GHC now runs in the browser

#119
post #37

Unfortunately there is still no way to actually bootstrap haskell (or anything based on it) which makes it impossible to put anything written in Haskell near any high trust linux distribution or environment. I guess sandboxing the untrusted binary in a browser is -something- to let people play with haskell in a lower risk way for the moment at least but it is hard to take a language seriously or trust it with no way…

doesn't rust have the same problem? I've known this about haskell for ages and I think it's just the new norm ("trust us, bro")
Post reply on HN