Avoid having an opaque and transparent variant of each pixel shader
You can use a threshold set through a constant buffer to clip pixels (ie an alpha test):

float threshold; // in constant buffer

float4 color = myTexture.Sample(...);
if (color.a &lt; threshold)
    discard;


Set threshold to 1.0 to discard all transparent fragments; set it to 0.0 to discard nothing. There will be some minor inefficency in the latter case compared to having a separate pixel shader with the alpha test removed entirely, but it shouldn't be a big deal on most GPUs nowadays.