Tested with a Radeon HD 7970 on Windows 7 64 bits. Driver updated to Catalyst 12.10
The relevant code:
#define PIXELS 20
If I change the seventh line for the equivalent:
The generated IL changes a lot from register renaming with the first version having a few more instructions. Worse still, after the change results are completely wrong. The code works fine either way on a variety of Nvidia platforms. I'm afraid I can't provide the full code without an NDA but I'd be happy to help in any other way.