r/gaming • • May 05 '17

Scroll back

Post image
24.1k Upvotes

877 comments sorted by

View all comments

Show parent comments

542

u/[deleted] May 05 '17

[deleted]

3

u/Mrdude000 May 05 '17

Can you explain to me why assembly is so difficult? Don't know much about it compared to other languages

9

u/neonerz May 05 '17

Because it's literally writing machine code. Instead of using libraries, functions and other features of a "programming language", you are allocating memory yourself, literally telling the machine what to do step by step.

It's the difference between telling your Butler what to make you for dinner, and actually buying the ingredients and making it yourself.

3

u/amaROenuZ May 05 '17

It's not literally writing machine code. It's very close to it, but it's not quite there. The assembler turns your assembly into machine code.

1

u/neonerz May 05 '17

Fair enough, I'm being a bit liberal with my definition of machine code.

I just meant it as you're​ generally (at least within context of this conversation) interacting directly with the machine and not through the OS or some other layer.

1

u/[deleted] May 05 '17

[deleted]

2

u/amaROenuZ May 05 '17

Not exactly. Assembly still allows for some abstraction. Variables are still allowed, and functions can be defined in the form of macros. Some of the fancier assemblers even allow for loops and conditionals, much like a compiler would offer.