Localized a bunch of frequent time-critical calls
Deleted unnecessary pattern matching