Inline helper functions of label

Setting an explicit return type for the functions and additionally inlining them should speed up the labeling.