Number of instruction in shader?

Is there a way to know the number of instructions the shader compiled too? Not the lines of code but the accrual assembly instructions.

This is very useful to know if one is going overboard. I also want to make a shader that i can enable to see the number of instructions as the scene is rendered with green being low number and red being a high number.

Some thing like this: