Computer programming used to be applied maths. You followed the correct lemmas in the language and if you didn't make any errors you had a correct program.
Now there are so many layers of indirection between you and the world (huge complex APIS, graphics drivers, optimizing compilers, hyperthreading, cache, etc) that the actual behaviour of a program - especially in high performance, real time world - is no longer possible to calculate from the published specs.
It becomes experimental science, you adjust various parameters and measure the result. Certainly to get performance but sometimes just to get APIs to work together.