DMD Backend: Deciding instructions to use/avoid?

Nick Sabalausky a at a.a
Sat Jun 4 02:36:39 PDT 2011


I'm working with Jacob to try to resolve an issue where D programs compiled 
on his Ubuntu box (in 32-bit/32-bit) error out on my Ubuntu box with 
"Illegal instruction". At first we thought it was because my OS was an older 
version than his. But he tried compiling on an older OS than mine and it 
still didn't work. So now I'm wondering if it may really be just like the 
message seems to imply: an illegal CPU instruction.

So my main question: Does DMD do anything like, say, detecting the CPU at 
compile time and then enabling instructions only available on that CPU and 
up? Or does it do anything like always assuming the target CPU has SSE2? 
Anything like that that could cause differences between our CPUs to result 
in object code that will work on one of the CPUs, but not the other? FWIW, 
the CPU on my linux box is i686, so it's not like I'm on some 
super-ultra-old i586, or anything like that. 




More information about the Digitalmars-d-learn mailing list