Correct function checking
Prepare basic test data
Apply a couple of code simplifications
Split Buffer and SlowBuffer paths
Speed up NaN detection