Hacker Newsnew | past | comments | ask | show | jobs | submit | zgs's commentslogin

Seems like another way to deliver nukes to targets...


Small ones anyway. W80 [1] W54 [2]. Most of them are over 500 lbs.

High altitude weather balloons on the other hand can carry up to 8000 lbs like the one from China the US let meander coast to coast over several military installations which could carry a B53 nuke after small modifications. Detonated at a high altitude could shut down the power grid coast to coast.

[1] - https://en.wikipedia.org/wiki/W80_(nuclear_warhead)

[2] - https://en.wikipedia.org/wiki/W54

[3] - https://en.wikipedia.org/wiki/B53_nuclear_bomb


Under uClinux, executables can be position independent or not. They can run from flash or RAM. They can be compressed (if they run in RAM). Shared libraries are supported on some platforms. All in all it's a really good environment and the vfork() limitation generally isn't too bad.

I spent close to ten years working closely with uClinux (a long time ago). I implemented the shared library support for the m68k. Last I looked, gcc still included my additions for this. This allowed execute in place for both executables and shared libraries -- a real space saver. Another guy on the team managed to squeeze the Linux kernel, a reasonable user space and a full IP/SEC implementation into a unit with 1Mb of flash and 4Mb of RAM which was pretty amazing at the time (we didn't think it was even possible). Better still, from power on to login prompt was well under two seconds.


Out by a factor of five or more.

A $1 Linux capable ARM: https://www.eevblog.com/forum/microcontrollers/the-$1-linux-...

I'd expect that there were even cheaper processors now since it's eight years later.


Microchip is always more expensive than the Chinese stuff, but Microchip contributions to Linux are mainline (!!!!), and is often worth the extra few $$$$.

Fully open hardware, with mainline Linux open source drivers. It's hard to beat SAM9x60 in openness, documentation and overall usability. It's specs are weaker but keeping up with mainline Linux is very, very relevant. Especially in this discussion


I used decNumber in the WP 34S project (https://sourceforge.net/projects/wp34s/) and more recently in the C47 project (https://47calc.com).

You are correct in that the decNumber library doesn't support trig operations. Arithmetic, log, exp and square root plus rounding and some conversion functions.

My experience is that decNumber is generally slow. Logarithms are especially slow. Intel's decimal library is much faster & as you noted, it uses binary operations to start it's algorithms.


It might be shorter to do some multiplications:

0x08C0C166 = 2⁴ × 3 × 5⁵ × 11 × 89 + 1 = 10⁴ × 3 × 5 × 11 × 89 + 1

Plenty of values that can be reused (11 = 10 + 1 and 89 = 10² - 11).

Still, there is quite a bit of manipulation required and only 17 instructions to do them in.


That's a very clever approach — I hadn't even thought of factoring the target value like that.

Decomposing `0x08C0C166` into `2⁴ × 3 × 5⁵ × 11 × 89 + 1` and reusing parts like `11 = 10 + 1` and `89 = 10² - 11` is genuinely interesting.

Still, as you said, packing all the necessary manipulations into just 17 instructions is the real challenge — especially when you try to avoid any immediate constants, memory access, or stack usage.

If you do find a shorter sequence that matches the constraints exactly, please share! I’d love to see how far this can be optimized.


The initial XOR instruction isn't required, registers are zeroed as per the problem statement.


Yes, you're absolutely right — the initial `xor cl, cl` is technically redundant if we assume all registers are zeroed at start, as stated in the problem.

I kept it in the solution mostly out of habit and to make the logic more explicit, but you're correct that it could be removed, bringing the count down to 16.

That said, for consistency (and because some AI models needed it to understand the logic flow), I still include it when comparing instruction count across different versions.

But you're totally right: under the problem's assumptions, `xor cl, cl` is free.


Better check his pockets on the way out :)


I think there is a spurious "and H" in the title :)


Later uClinux was available on m68k platforms without memory managers. The approach taken doesn't seem close to the one in the article.

I managed to put in shared execute in place library support, the limitation being the number of shared libraries rather than what they supported.


My favourite mathematical problem looks to have been solved.


Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: