Can I determine the pixel geometry programmatically?
It appears that Microsoft has punted on this in Windows 7:



This is the method available in the control panel for selecting what layout ClearType uses.

Additionally, it seems that iOS and the Windows modern UI style de-emphasize subpixel antialiasing heavily, due to the prevalence of animations and screen rotations. As a result I expect the OS vendors to not spend a lot of effort trying to figure out the subpixel layout of every screen.