Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's still a decent machine for C especially when compared with, say, 8051. I'm currently developing an entire product line based on a '51 derivative and just seeing what kind of assembly Keil C51 compiler produces is enough to make my eyes bleed. The amount of kludges required to make C work on that architecture is horrifying. Want an example? There's no stack when running under C51.


There's certainly a stack when running under C51, for function call returns. C51 just assigns local variables into 128 byte data segment. But say, PUSH ACC works just fine when you drop into assembler.

Then again, stack on 8051 might be sometimes pretty small. From 10 to 128+ bytes.


Right. Still, the fact that local variables aren't stack- but overlay- based is enough to blow my mind.


Yeah. The small device I am most familiar with is the z80, which is really not a good C machine either.




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

Search: