Can a compiler generate an output directly to the microprogramming level instead of the instruction set level?

StackOverflow https://stackoverflow.com/questions/21369957

Pergunta

I was wondering whether any given compiler can generate an output directly to the micro architecture level instead of the ISA level. I understand that the microprogramming level is not being used usually these days and the hardware executes instructions directly at the ISA level. But is it possible? And why is it not done so much these days? Thank you.

Foi útil?

Solução

CPUs don't generally expose an interface that lets you access the microprogramming instructions directly - indeed there's no binary format for those instructions. So there'd be no way a compiler could target them and no point in it doing so as noone would be able to use the resulting binary.

Even if it were possible, it wouldn't be a great idea - the ISA is the standard that is guaranteed to remain backwards compatible, whereas the internal microcode is available for the processor vendor to change whenever it is convenient. It is also likely to be a lot less compressed than the ISA, so binaries would be bigger and you'd lose out on performance in the instruction cache.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top