all 18 comments

[–]zyxzevn 4 insightful - 3 fun4 insightful - 2 fun5 insightful - 3 fun -  (3 children)

What CPUs are you using? There is a huge difference in complexity.

From the most complex are 8086 due to segments and Itanium due to manual register rotation. With older processors you even had to make your multiplication or division. And you have a different processor for floating point.

Modern systems are more complex due to programmable sub-units. Like GPU, DMA, DSP.

[–]suzew[S] 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (2 children)

I did not understand some of what you said.
I am using a CPU that is 3700 MHz with 10-core processors

[–]zyxzevn 2 insightful - 2 fun2 insightful - 1 fun3 insightful - 2 fun -  (0 children)

CPUs have different architectures and different instruction-sets.
Some instruction-sets differ after with a new version, especially the SIMD instructions.
SIMD instructions are use to make specialized computations a lot faster, often used for games or encryption.
The SIMD instructions are also the most complicated.

See: video: The top 10 craziest assembly language instructions

On the same channel: video tutorials on x64 assembly

[–]SoCo 2 insightful - 1 fun2 insightful - 0 fun3 insightful - 1 fun -  (0 children)

A RISCky perspective...

I cut my teeth learning ASM with PIC micro-controllers. They use the dead simple RISC (Reduced instruction set) architecture, leaving there only like 30-ish ASM instructions to deal with.

I took to it pretty easily and felt like I got a good fundamental understanding of ASM programming, registers, stacks, and low level stuff out of the experience.

Yet, the PICs I used were 8-bit and didn't have multiply or divide instructions. This lead to another level of fundamental learning as I implemented my own multiply/divide functions using bit-shifting and add/subtracting and multi-byte math functions. Dealing with code-paging was an insightful pain as well. (jump instructions only fit part of the destination address and you must manually flip the high bits of the address in a register first)

As more options for micro-controllers and their supporting libraries/tool-chains came about, I've moved on and not used ASM or PICs in quite a long time. (I mainly focus on AVRs with C/C++ and embedded Linux devices now)

[–]iDontShift 3 insightful - 4 fun3 insightful - 3 fun4 insightful - 4 fun -  (1 child)

be thankful for compilers

[–]suzew[S] 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (0 children)

Thank you, compilers.

[–]magnora7 3 insightful - 3 fun3 insightful - 2 fun4 insightful - 3 fun -  (2 children)

Yeah it is hard, I did a lot of x86 assembly in college.

I read once that the game Rollercoaster Tycoon was coded by one guy in x86, which still blows my mind. That's part of why it runs so smoothly and efficiently. But I imagine it was a crazy amount of work.

[–]suzew[S] 4 insightful - 2 fun4 insightful - 1 fun5 insightful - 2 fun -  (1 child)

Yea, that's crazy.
Prince of Persia game was also coded in ASM.
Monster programmers among us.

[–]magnora7 2 insightful - 2 fun2 insightful - 1 fun3 insightful - 2 fun -  (0 children)

I didn't know that about Prince of Persia. Neat.

I wonder if it'd be possible to make a neural net that does random ASM commands and values and tries to code a random program through trial and error and neural network feedback. That'd be a neat project.

[–]Jackalope 2 insightful - 1 fun2 insightful - 0 fun3 insightful - 1 fun -  (4 children)

Try to appreciate the elegance of assembly - You can do literally anything by with just a handful of very simple instructions.

While you will not likely do much assembly in the industry, this course is worth putting in the effort as it will make you a better programmer. Being able to build your own routines from scratch and understanding every little step involved is a skill that will serve you well no matter what you end up doing.

[–][deleted] 2 insightful - 2 fun2 insightful - 1 fun3 insightful - 2 fun -  (2 children)

Agree. Assembly is like the off-grid homesteading of the computer and programming world.

[–]Jackalope 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (1 child)

Hah!, thats a great analogy.

[–][deleted] 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (0 children)

I love it too. And it can be applied in a similar way to 'off-grid' computing.

[–]suzew[S] 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (0 children)

Thanks for your insight.

[–]fatman 1 insightful - 2 fun1 insightful - 1 fun2 insightful - 2 fun -  (2 children)

Don't worry buddy, keep thinking really hard and your brain is gonna get huge!

[–]suzew[S] 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (1 child)

How brain get big? Monke

[–]fatman 1 insightful - 2 fun1 insightful - 1 fun2 insightful - 2 fun -  (0 children)

Fight hard until you get hired brother, then it's all easy from there. Go through the box.

[–][deleted] 1 insightful - 1 fun1 insightful - 0 fun2 insightful - 1 fun -  (0 children)

Assembly language is tedious. I reserve the description "hard" for stuff like debugging a KnockoutJS problem or dealing with some neckbeard's "clever" use of Clojure destructuring.