I don't know... "neat hack", but it seems there is so much out there that could actually have some kind of practical application that it's a bit of a waste to work on "silly" projects. I love to hack on things that don't have any immediately evident business model or real world application, but I think purposefully working on something that never will is perhaps a bit unfortunate. Yeah, he learned something for sure,…
I'm assuming you've been downvoted because slightly more than 50% of HNers think of this project as an artistic/fun project. But the fact is, even a purely artistic/fun project will have some creativity or originality in it. I would consider a toy language or Brainf__k written for the first time as artistic. But this project is just a JIT for Brainf__k, there's no creativity in it, and all it did was give the author…
I wrote an LLVM-powered trace-based JIT for Brainfuck
41–50 of 56 posts
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#42Hey folks, I'm the actual author of this. I actually work on LLVM-proper during my day job. This was just a fun exercise to demonstrate that it was possible. I also have plans to write a tutorial based on it.
please cover the blog-post also from an LLVM-n00bie perspective., with appropriate code references whereever possible.
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#43Is anyone else oddly inspired to make an OCaml to Brainf k translator just to build a staggeringly awesome rube goldberg machine?
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#44Hey folks, I'm the actual author of this. I actually work on LLVM-proper during my day job. This was just a fun exercise to demonstrate that it was possible. I also have plans to write a tutorial based on it.
Also an example of how to implement a direct-threaded interpreter. Some performance data from a Brainfuck mandelbrot benchmark. Interpreter: 37.787s Tracing JIT: 11.716s Static Compiler: 2.402s The tracing JIT loses out to the static compiler largely because there's no dynamic dispatch in Brainfuck for the tracer to optimize out. There's probably some performance to be recovered by tuning the tracer thresholds and mi…
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#45Hey folks, I'm the actual author of this. I actually work on LLVM-proper during my day job. This was just a fun exercise to demonstrate that it was possible. I also have plans to write a tutorial based on it.
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#46Earlier quoted context omitted.
> You assume that a person cannot gain something by simply learning something that has no practical purpose Actually, what I wrote , if you'd bother to read it, is: "Yeah, he learned something for sure, but that's pretty much all it can be." so don't put words into my mouth. The point boils down to this: * It'll probably never become big. * That doesn't really matter, it's mostly for learning and for fun. * But even…
The effort you've expended to debate this will soon meet & then exceed the effort that went into the tracing JIT in question. When you reach that point, you'll have some soul searching to do.
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#47Is anyone else oddly inspired to make an OCaml to Brainf k translator just to build a staggeringly awesome rube goldberg machine?
I can not find it, but I have seen a C to brainfuck compiler. Don't ask.
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#48Earlier quoted context omitted.
Also an example of how to implement a direct-threaded interpreter. Some performance data from a Brainfuck mandelbrot benchmark. Interpreter: 37.787s Tracing JIT: 11.716s Static Compiler: 2.402s The tracing JIT loses out to the static compiler largely because there's no dynamic dispatch in Brainfuck for the tracer to optimize out. There's probably some performance to be recovered by tuning the tracer thresholds and mi…
Thanks for writing this -- it's awesome to see JIT principles boiled down to the point where you can easily understand the whole system. Please let us know if you publish the tutorial; I'd love to see more detail on the JIT. In particular, it would be the perfect template to demonstrate feedback-directed optimization opportunities and to measure the overhead of tracing; it would be incredibly interesting to see what…
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#49Earlier quoted context omitted.
Thanks for writing this -- it's awesome to see JIT principles boiled down to the point where you can easily understand the whole system. Please let us know if you publish the tutorial; I'd love to see more detail on the JIT. In particular, it would be the perfect template to demonstrate feedback-directed optimization opportunities and to measure the overhead of tracing; it would be incredibly interesting to see what…
The tracing overheads are pretty huge. Running with tracing but without compilation takes 107s.
Re: I wrote an LLVM-powered trace-based JIT for Brainfuck
#50Earlier quoted context omitted.
You're assuming that every thing that people work on actually needs the potential to become "big". What about the people that study klingon? Or Esperanto? Or Elvish? You assume that a person cannot gain something by simply learning something that has no practical purpose. This isn't the case. By working on BF, someone might make some neuron connections that help them with logical thought with other projects, by break…
Then how about giving an example of somebody who had some benefit of learning Klingon, not related to Klingon as is?