Assembly programming
Pages: 1 2
Alan Adams (2486) 1149 posts |
and, most importantly at the moment, to allow the same code to be compiled for a different processor, e.g. a 64-bit ARM. Digital Equipment had this issue when switching from 32-bit VAX processors to 64-bit Alphas. A lot of their code was written in Vax assembler. They solved the problem by writing a compiler for Vax assembler, that output Alpha code. It helped that they also provided 32-bit wrappers for the 64-bit API, so the assembled code could still call the old API. |
Kuemmel (439) 384 posts |
…as we live in a free world, everybody can code in what he likes, except at work, may be the boss is telling you otherwise ;-) Just the point to speed of resulting code in high level vs. assembler. As I demonstrated in my aldershot thread on my Mandelbrot stuff I think there are some optimizations that are not implementable at all in higher level languages. Due to the enhancing and evolving out of order structure of modern CPU’s (x86 since may be since 15 years, ARM may be half…) the only way to max out performance in those cases is to create blocks with independant register usage to parallelize the math on a single core and as far as I know high level languages there’s not a single one where you can tell a compiler to assign variables to dedicated cpu registers, or can you ? …without doing that in that case you miss out a performance increase of factor 2 or 3 ! The internal register renaming of the cpu can’t do the optimization by itself…for me it’s important to teach kids the potential, but of course I agree for >99% of app coding it’s irrelevant also. |
Pages: 1 2