Live data from Hacker News

Frame – Linux X server in Assembly

isene.org

51–60 of 115 posts

Re: Frame – Linux X server in Assembly

#54

It's funny to see someone using a LLM as a compiler, making it convert higher-level operations into assembly, instead of just using a compiler.

There is evidence that LLMs are capable of making assembly that runs a great deal more efficiently than the compiler can manage on its own.

The purpose of an optimizing compiler is not merely to produce efficient assembly. The goal of an optimizing compiler is to produce efficient assembly while confidently preserving a program's observable logical semantics. Asking an LLM to spit out raw unstructured assembly based on inferred context from a specification given in English is a contender for one of the worst ideas I have ever heard; I award you no points, and may God have mercy on your soul.

Re: Frame – Linux X server in Assembly

#55

How many times have people posted here about how software is no longer optimized because CPUs keep evolving, making programmers lazy? It seems things have changed. The question is: will LLMs manage to squeeze the most out of this hardware, better than compilers do? In the few tests I’ve run, yes, a lot.

Most of the gain seems to come from choosing a much smaller program. Frame implements enough X11 for this one desktop and leaves out decades of compatibility work that a compiler would still have to preserve.

Re: Frame – Linux X server in Assembly

#56

It's funny to see someone using a LLM as a compiler, making it convert higher-level operations into assembly, instead of just using a compiler.

There is evidence that LLMs are capable of making assembly that runs a great deal more efficiently than the compiler can manage on its own.

[dead]

Re: Frame – Linux X server in Assembly

#58

When first looking at the source code, I wondered why one would waste so much time to write 25k lines in raw assembly language, but then I saw that it was generated with Claude, for whom it does not matter much how expanded is the written text. If someone had written this program manually, the strategy would have been very different. With a good macro-assembler (and nasm is good enough) one should define a great numb…

Once you create an abstraction (like a macro, routine, language) you forfeit the benefits using machine code gives you wherever you use that abstraction, since there could be some bespoke implementation that solves the problem.

That entire point is moot here because the abstraction in this case is a massive ball of crap and it's used everywhere. So you never get the benefit you think you would for using a lower level language. That's why generally LLMs are best with python and even better with a "harness" (domain specific framework and language)

Post reply on HN