Things are getting interesting in the SPO 600 course. It’s time to get familiar with modern processor architectures: the x86_64, which powers all most everything today and the new ARMv8 that is gaining traction mostly because of its energy efficiency. Also, for the first time, we will “forget” assembly and focus on the compiler.
So, what is the difference between x86_64 and ARMv8?
Making a processor is hard and expensive, so instead, they decided to make the x86 (32bits) to work as 64bits – x86_64. That strategy popularized the 64bit environment. On the other side, the ARMv8 was designed for 64bits from the beginning, and its energy efficiency made it accessible on mobile applications. Who remembers the RISC vs CISC competition? The RISC concept tells us to execute simple operations quickly. The CISC concept is quite the opposite: complex operations will perform better than a bunch of simple ones. Who won? Well, everybody won! Nowadays, the RISC introduced some CISC features and vice-versa and we have faster CPUs. Lastly, they all differ on registers, instructions, cache and many more.
Luckily, for the ones that don’t want to go assembly - like me - the compiler will know how to produce the executable for each architecture. However, we might end up with a not so well performed product as we were making it in assembly. To help us with that, there are compiler options (-static | -g | -fno-builtin | -O0 | -O3) that we can play around that could improve the overall performance.
We know that compilation is a painful process and can take a lot of time. To address this, the “make” utility will configure and compile our package. It is smart enough to know the proper execution sequence and what doesn’t need to be recompiled – due to no changes, for example.
My next post will talk more about the compiler. See you.
So, what is the difference between x86_64 and ARMv8?
Making a processor is hard and expensive, so instead, they decided to make the x86 (32bits) to work as 64bits – x86_64. That strategy popularized the 64bit environment. On the other side, the ARMv8 was designed for 64bits from the beginning, and its energy efficiency made it accessible on mobile applications. Who remembers the RISC vs CISC competition? The RISC concept tells us to execute simple operations quickly. The CISC concept is quite the opposite: complex operations will perform better than a bunch of simple ones. Who won? Well, everybody won! Nowadays, the RISC introduced some CISC features and vice-versa and we have faster CPUs. Lastly, they all differ on registers, instructions, cache and many more.
Luckily, for the ones that don’t want to go assembly - like me - the compiler will know how to produce the executable for each architecture. However, we might end up with a not so well performed product as we were making it in assembly. To help us with that, there are compiler options (-static | -g | -fno-builtin | -O0 | -O3) that we can play around that could improve the overall performance.
We know that compilation is a painful process and can take a lot of time. To address this, the “make” utility will configure and compile our package. It is smart enough to know the proper execution sequence and what doesn’t need to be recompiled – due to no changes, for example.
My next post will talk more about the compiler. See you.
Comments
Post a Comment