Live data from Hacker News

Advanced Compilers: Self-Guided Online Course

cs.cornell.edu

51–60 of 241 posts

Re: Advanced Compilers: Self-Guided Online Course

#52

Domain-specific compilers are a bigger field, where there's more opportunity to do something interesting Take C (or some other language) and its mature optimizing compilers as a foundation, and write a program that compiles a high-level description of a domain-specific program into C For example, NN-512 ( https://NN-512.com ) is a compiler that takes as input a simple text description of a convolutional neural net in…

Not open source but I'm working on a system that turns a DSL (embedded into Jupyter notebooks) into either c or c with opencl for a niche finance application. Not a huge project (<10k lines of code). Nature of the problem means that DSL can be very simple (it's aimed at non-programmers). This approach also means that could easily add other targets - e.g. cuda or wasm.

Re: Advanced Compilers: Self-Guided Online Course

#53

Earlier quoted context omitted.

There are various weird and wonderful niche languages out there, if you appreciate programming languages as an end in themselves. Two examples: Sentient [0] and Factor [1][2]. [0] https://sentient-lang.org/ [1] https://factorcode.org/ [2] Factor's home-page does a poor job of presenting examples to give a flavour for the language, so here's one on GitHub: https://github.com/factor/factor/blob/master/basis/roman/rom..…

Sentient looks neat! Does it use the same strategies as Prolog under the hood?

Good question, I'm afraid I don't know enough about either language to answer that.

The Sentient pages mention Prolog, for what that's worth: https://sentient-lang.org/intro/declarative

Re: Advanced Compilers: Self-Guided Online Course

#54
post #12

On the related note, what would you guys recommend as an introduction to compilers, say for beginners?

Crafting Interpreters has been great. It starts with an AST-walking interpreter (in Java), so you get to focus on parsing and the simplest form of interpretation, and then it moves to a bytecode interpreter (in C) so you get to learn about compiling to a more primitive target via a lower-level language (much of which should translate to a "real" compiler). Very approachable, has lots of side-context and an entertaining style. The language you interpret was custom-designed for the course, which helps a lot, and resembles a simplified JavaScript without all the messy parts.

Re: Advanced Compilers: Self-Guided Online Course

#56
post #40

Anyone interested in following the course together during the holidays? To keep each other motivated etc.

I would love to do so! I'm a masters student who has been wishing there was an advanced compilers course in my program, there's only the undergrad level one, so this is perfect! Let me know how I can get in contact.

Re: Advanced Compilers: Self-Guided Online Course

#58

Domain-specific compilers are a bigger field, where there's more opportunity to do something interesting Take C (or some other language) and its mature optimizing compilers as a foundation, and write a program that compiles a high-level description of a domain-specific program into C For example, NN-512 ( https://NN-512.com ) is a compiler that takes as input a simple text description of a convolutional neural net in…

Not open source but I'm working on a system that turns a DSL (embedded into Jupyter notebooks) into either c or c with opencl for a niche finance application. Not a huge project (<10k lines of code). Nature of the problem means that DSL can be very simple (it's aimed at non-programmers). This approach also means that could easily add other targets - e.g. cuda or wasm.

Awesome. Link?

Re: Advanced Compilers: Self-Guided Online Course

#59
I’ve worked on multiple compilers (optimizations expert) at MSFT on VS and CUDA and gave developed a DSL and worked on Database Compilers. I can’t hire compiler people with right skills. We’re building an IDE and those parsers are written differently, and we use Scala packrat parser combinators. These courses teach very little judgement or industry relevant stuff. When do you use packrat parser vs LALR vs LL? Good luck hiring an engineer with advanced compiler courses knowing any of this. I’d like to sit down all university professors who teach compiler courses and teach them a course on what’s relevant.

Re: Advanced Compilers: Self-Guided Online Course

#60
post #48
post #40

Anyone interested in following the course together during the holidays? To keep each other motivated etc.

Yes! How should we organize this? Maybe start with an IRC channel?

Yes! an IRC channel would be great! Do you want to start it and post the info here? Or else I can start
Post reply on HN