QBE

Languages and libraries

compiler backend

SHOW HN2016

241points
68comments
#102of 2,264 in 2016
Top 5%of 2016 by points

How HN took it

CuriousMostly questions and neutral comments

7 positive, 19 neutral or asking, 1 mixed, 3 critical, out of 30 comments about the project. Thread score +0.05.

Idea: 4 for, 1 againstPerformance: 3 for, 0 againstDesign: 0 for, 1 against

The thread, comment by comment

Each row is a top-level comment and its replies, in HN's order. Select a cell to open that comment on HN.

positive neutral or mixed critical about another commenter or something else the maker

What HN said

What people liked

  • Admired goal of small, simple compiler design

    From 3 comments
    • I've always found this sort of "I'm going to make my own" approche as being the best for innovation. I really hope this goes through and continues development.
      gravypod on HN
    • This is a wonderful idea! As a compiler person, I'm excited to see how well this works and wish you all the success in the world. > QBE aims to be a pure C embeddable backend…
      gnuvince on HN
    • At times I feel that LLVM is quite a monster, and I really like your goals of keeping things small & simple. Kudos! Can you expand on your point about "LLVM does NOT provide full…
      riscy on HN
  • Useful for education due to small size

    From 1 comment
    • > Its small size serves both its aspirations of correctness ... No, a compiler (hell, a software) written in C is not correct, period. If you want a C compiler that has slight…
      Drup on HN

Objections

  • A compiler written in C cannot be fully correct; CompCert is preferable

    From 1 comment
    • > Its small size serves both its aspirations of correctness ... No, a compiler (hell, a software) written in C is not correct, period. If you want a C compiler that has slight…
      Drup on HN
  • Using C is risky for correctness; suggested safer languages like OCaml

    From 1 comment
    • Interesting project mpu. I like the stuff here: http://c9x.me/compile/doc/llvm.html Especially the optimizations that get you the first 70%. I've been asking optimization people…
      nickpsecurity on HN

Requests

  • Benchmarks of compile times against other compilers

    From 1 comment
    • Any benchmarks of compile times vs other compilers?
      azakai on HN
  • Support for C++ calling or coroutines

    From 2 comments
    • > Very good compatibility with C code How much harder would it be to call C++?
      hobo_mark on HN
    • Can QBE do coroutines (e.g 'yield')? Or maybe it's a front-end issue only?
      Ace17 on HN

Questions

  • How does it compare to libfirm?

    From 1 comment
    • How does this compare to libfirm[1]? 1. http://pp.ipd.kit.edu/firm/
      npx on HN
  • How does the SSA handling differ from LLVM's stack slots?

    From 2 comments
    • > Implementing SSA construction is hard. To save its users from having to implement it, LLVM provides stack slots. This means that one increment of a variable v will be composed…
      munin on HN
    • > you can simply emit non-ssa form and QBE will fixup things for you That's exactly what LLVM does though, except the "non-SSA form" involves loads/stores to alloca'd values. The…
      munin on HN

Alternatives named

  • LLVM

    From 2 comments
    • > Implementing SSA construction is hard. To save its users from having to implement it, LLVM provides stack slots. This means that one increment of a variable v will be composed…
      munin on HN
    • Thank you for your words. It is often called NIH, but eh, I learned a lot! And I think that I made some modest improvements over LLVM, you can check them out in my comparison at…
      mpu on HN
  • libfirm

    From 1 comment
    • How does this compare to libfirm[1]? 1. http://pp.ipd.kit.edu/firm/
      npx on HN
  • CompCert

    From 1 comment
    • > Its small size serves both its aspirations of correctness ... No, a compiler (hell, a software) written in C is not correct, period. If you want a C compiler that has slight…
      Drup on HN

Category, keywords, summaries and labels on this page were made by AI (Thread Reader v2) and not checked by hand. Each point links to the comments it came from.

Add a badge to your READMEShown on HackerShow
[![Shown on HackerShow](https://hackershow.org/badge.svg)](https://hackershow.org/show/11555527)