Hacker News

Top stories

Live mirror
30 storiesupdated just nowView source snapshot
  1. Human brain is two separate organs, Stanford Medicine-led research finds(stanford.edu ↗)
    116comments
  2. AI-generated posters don’t have to be horrible(john.hartnup.uk ↗)
    175comments
  3. “The Secret Life of Circuits” is here(coredump.cx ↗)
    26comments
  4. GPT-6 Astra Solves a WWI German Radio Cipher(prinzai.com ↗)
    82comments
  5. Android 17 is the first since 3.x to add new APIs without releasing to the AOSP(grapheneos.social ↗)
    452comments
  6. Laya the open source version of Jev(convaiinnovations.com ↗)
    4comments
  7. If math is more than proof, we need to better celebrate the rest of it(terrytao.wordpress.com ↗)
    109comments
  8. San Francisco Onion Futures Company(onionfutures.com ↗)
    77comments
  9. Communication by means of modulated Johnson noise(pnas.org ↗)
    2comments
  10. Cloudflare Quick Tunnels(cloudflare.com ↗)
    285comments
  11. How to Write with an LLM(sockpuppet.org ↗)
    342comments
  12. SDCC – Small Device C Compiler(sourceforge.net ↗)
    20comments
  13. Science Is Open Software(jepedersen.dk ↗)
    40comments
  14. Saving another 100TB of RAM(cloudflare.com ↗)
    83comments
  15. You can run Git on object storage if you re-make packfiles(tigrisdata.com ↗)
    19comments
  16. Why building a Rust LSP is hard(rust-glancer.github.io ↗)
    32comments
  17. How OpenAI Used Its Own LLMs to Design Its Jalapeño Chip(ieee.org ↗)
    94comments
  18. Ctenophores: Wonders of Biology(quantamagazine.org ↗)
    6comments
  19. NASA-IBM Lunar Foundation open-Source Geospatial AI Model(usra.edu ↗)
    4comments
  20. From Stonemasons to Carpenters(thelastsoftwareengineer.substack.com ↗)
    1comments
  21. The first new cat species discovered in 100 years(nationalgeographic.com ↗)
    108comments
  22. OpenJev(openjev.com ↗)
    270comments
  23. Show HN: Cactus Needle 3: 8-29MB automation models can match DeepSeek V4 Flash(cactuscompute.com ↗)
    89comments
  24. Goroutine Leak Profiles(go.dev ↗)
    4comments
  25. Photon-Emission-Guided Laser Fault Injection Enables RP2350 Secure Debug(ledger.com ↗)
    73comments
  26. Apple M6 Pro Achieves the Highest Single-Core CPU Score in Geekbench 7(geekbench.com ↗)
    88comments
  27. Veronese's Dogs(publicdomainreview.org ↗)
    1comments
  28. Cache-to-Cache: Direct Semantic Communication Between LLMs (2025)(arxiv.org ↗)
    14comments
  29. Warez: The Infrastructure and Aesthetics of Piracy (2021)(archive.org ↗)
    84comments
  30. Inside ZCode: Silently uploading your Git history to the cloud(ferstar.org ↗)
    102comments

Stack Computers: the new wave (1989)

36 pointsby 10y agousers.ece.cmu.edu
28 comments
10y agoHN ↗

Are we going back to programming in Forth now?

10y agoHN ↗

Once or twice a month Forth and Lisp posts get repeated...

10y agoHN ↗

There's lisp posts here all the time, but forth posts are regrettably sporadic.

10y agoHN ↗

So going back to Forth is probably not a good idea, but consider this....

1. Modern CPU microarchitectures issue multiple instructions/micro-instructions per clock.

2. Modern CPU microarchitectures rely heavily on register renaming in order to avoid bottlenecking on register allocation.

3. High code density is a huge win because: a) highly dense code reduces the cache footprint for a given amount of expressed functionality, which in turn reduces the amount of die area that need be dedicated to instruction cache in a well-balanced processor. b) highly dense code reduces the amount of bus traffic filling the instruction cache from main memory, thus reducing the overall memory bandwidth required to execute a given amount of functionality. Taking a & b together, they explain, in part, why X86 is still king of the hill, and it certainly explains why X86 won over Itanium. X86 code, for all its accumulated cruft, is very dense.

4. Stack machine code is also very dense, because exactly zero bits are dedicated to register names in every instruction.

So... given that the register numbers in typical 2-address or 3-address machines are getting renamed away anyway, why have them at all? Let the compiler generate 0-address code for a stack machine, and let the instruction decoder parse a long string of tokens during a single clock, using standard register renaming techniques to assign virtual stack locations from a large buffer pool. It could issue multiple stack ops per clock, but unwound into simple 3-address micro-ops for the CPU back end. It's really just the final step in moving the register allocator from the compiler to the CPU.

These are all solved problems for the X86 instruction set. Given that existence proof, it is difficult to argue that it would be hard to do for a clean stack-machine ISA.

10y agoHN ↗

This is the premise of the Mill architecture; though I haven't heard from them for a while now.

10y agoHN ↗

Really? The stuff I've seen about Mill is that they are doing a VLIW machine, which is a very different concept.

10y agoHN ↗

While I think that's true, it's also orthogonal to the 'belt' concept [1] they're using, which I think GP was referring to.

I'm also curious about the state of the Mill - judging by the forums on their website they've been basically dark for about a year and a half now, though Ivan Godard claims that everything is still moving along, just slightly slower than expected.

[1] https://millcomputing.com/docs/belt/

10y agoHN ↗

I don't know why the mill architecture has not gone into production yet. That technology has been in development for 13 years. It brings forth some interesting ideas. What is holding them back?

10y agoHN ↗

It is a startup though the degree of funding is not clear.

10y agoHN ↗

Haven't followed CPU arch in a very long time so my memory may fail, but the B7700 (1977) based on B5000 (1961) architecture demonstrated what you say on an industrial scale. The machine read in a long 48 bit string of opcodes, mapping them directly to hardware (adders, barrel shifters, inc/dec logic, branch prediction), maximizing throughput by anticipating needs for the next few clocks like setting up and (where possible) execute in different parts of the CPU. Since many operations were already present in pipeline and a cache miss or instruction branch could maybe predicted sooner you could see a long way into the future in some cases. This would leave the memory bus more free for data. And if I remember correctly, it would issue multiple (abstract?) cached stack operations to memory if possible, as the interface was quite sophisticated. And other CPUs could service the stack, SMP, if necessary. I had to troubleshoot these opcodes to the bit level back then, in 1981.

10y agoHN ↗

Did you keep any material about your time with the B7700? photos, printer listings, tapes, manuals? We're trying to build an emulator for the Burroughs B6700 (and by extension the B7700) so every scrap of information helps.

10y agoHN ↗

Very interesting! (I say this as someone interested in emulation in general, I sadly am not familiar with Burroughs equipment, although I know the name is synonymous with early cutting edge design.)

Does this project have any sort of publicly accessible online home yet?

10y agoHN ↗

nothing yet, we need to find a complete release of MCP for the Burroughs B6700 before we plan out the project.

10y agoHN ↗

I see, I just took a quick look around the Googles. I'm (somewhat) nearby over the water in Sydney :P

I have no idea where I'll end up in the future, but if I ever see anything interesting I now know where to send it.

10y agoHN ↗

RISC-V papers found x86 to not be very dense. Average instruction is 4 bytes, intruction count is very low. 2 operand instructions are a little less flexible than 3

10y agoHN ↗

Afaik, the Java virtual machine is also heavily stack-based.

10y agoHN ↗

Is that relevant to the hardware implementation though?

10y agoHN ↗

I seem to remember that the attempts at implementing the JVM in hardware haven't worked out all that well and the stack implementation was blamed for their inability to beat a software implementation on x86. I wonder if anyone here has more information or personal experience?

10y agoHN ↗

Most compilers use AST for internal intermediate code. TempleOS uses a stack machine intermediate code. At the end, it converts from intermediate code to x86_64 machine code.

10y agoHN ↗

Hi Terry, Do you have a document describing the stack machine intermediate code for TempleOS?

10y agoHN ↗

"Burroughs Machines: Implementation: A series of minicomputers" This is misleading; these were often very well regarded military grade and size, 48/51 bit stack based machines, hundreds of disk spindles and massive I/O, up to 8 CPU symmetric multiprocessing (7 IIRC cause you needed an I/O cabinet). And a sophisticated OS called MCP. Virtual memory. In 1977, or 1969, or earlier. https://en.wikipedia.org/wiki/Burroughs_large_systems Datamation archives tell the story.

10y agoHN ↗

I've been waiting for a stack computer with a GaAs CPU and bubble memory for I don't know how long!

10y agoHN ↗

I joined Harris Semiconductors' RTX2000 dev team after grad school & helped customers benchmark code using hand-built assembly language.

It was a ton of fun explaining stack ops to x86 designers :), plus the architecture ran rings around competitors' microcontrollers. Alas, cool architectures do not guarantee design wins.