Compiler behavior - Shaders, .fx, .fxh

I would like to ask what´s the deal about samplers because this is getting extremely frustrating. First let me state that I already come on terms with extremely aggressive compiler, but sampler order dependency is insanity, let me explain:

texture PanTexture;

SamplerState PanSampler
{
    Texture = (PanTexture);   
    Filter = Linear;  
    AddressU = Wrap;
    AddressV = Wrap;
};

texture EmissionTexture;

SamplerState EmissionSampler
{
    Texture = (EmissionTexture);   
    Filter = Linear;
    AddressU = Clamp;
    AddressV = Clamp;
};

....

float4 main(float4 Position : SV_Position0, float4 color : COLOR0, float2 texCoord : TEXCOORD0) : COLOR0
{
  float4 texTop = tex2D(PanSampler, DisplacementScroll + texCoord/1);                  
  float4 texMask = tex2D(EmissionSampler, texCoord );

  ...
}

This will produce correct results, but second you switch allocation like this:

  float4 texMask = tex2D(EmissionSampler, texCoord );
  float4 texTop = tex2D(PanSampler, DisplacementScroll + texCoord/1);          

Result will be wrong, it makes writing some sort of shaders bit impractical (screen space reflections for example), but I could deal with it so far.

Fatal issue and reason for this post came while working with noise shader that uses .fxh and requires permutation tables in form of textures. I´ve made standard XNA to Mono changes but results are… hell I don´t even know how to describe it. Fxh is included in Fx file, Fxh is obviously not complied, just copied through pipeline. Fxh include functions for 4d noise which I dont use right now, still I set all permutation tables and noticed null exceptions, that means compiler once again remove samplers for 4D p.tables while not used even if included through fxh.

Since shader worked without issues in XNA, was converted to mono in same manner as other shaders I got working and there is no way how to debug step by step 3D GPU noise shader I am getting bit desperate. I am 99% sure that it is mono / compiler doing something insane but can´t point finger on what, my bet would be samplers once again.