Writing a program is exactly the same thing as proving a mathematical statement. This is an extremely cool and deep result. Start with the Church-Turing thesis and go from there.
It's worse than that. The processor might support VT-d, but your motherboard chipset also has to support it. Even then, you might get a BIOS that doesn't expose the necessary information. All of these things are subject to market segmentation and other such unpleasantness.
In the end, unless you can coerce a DMAR table out of the machine, I'm not sure how you can tell if the thing actually supports VT-d.