Local variable anavailable

Hello everyone.

In my FilterSendNetBufferList function of NDIS filter driver I have these lines:

while (pNB) { 
 ............
 ............
 int nSend = pFilter->TailIrpSend & MASKA;

 PUCHAR BUFFER = MmGetSystemAddressForMdlSafe (
    pFilter->pIrpSend[nSend]->MdlAddress, NormalPagePriority);
  ...........
  ...........
}

Very rarely, windows is crushes in MmGetSystemAddressForMdlSafe, and WinDbg shows that nSend is unavailable.

What it means. Why local variable is unavailable?

anavailable     int nSend = value anavailable

I want to point again, that this happens very rarely.

And second question:

Can a filter module function like FilterSendNetBufferList be called more than once concurrently on behalf of one or more processors? And why is there no information about the behavior of the ndis filter on multiprocessor systems?

I need for that information for optimally organizing lock operetions.

Stack position where it locates is unavailable due to crush or compiler optimization turn it to register variable.

When optimizations are on, that value will be stored in a register. If the function doesn’t need the value after the call, then it will not have been saved anywhere. So, the value is literally unavailable.

Filter calls are not synchronized. If your filter needs to modify shared state, then you need to protect it.

I’m not sure why non-native speakers tend to use “crush” for a system failure, but it seems common. The correct word is “crash”.

Thank you very much.