(un)likely: use __builtin_expect to inform expected path

Remove also unnecessary comparison in getdata nth_field().

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2012-11-11 23:29:07 +00:00
parent 6f179db03d
commit acba2e265e
4 changed files with 25 additions and 3 deletions

View file

@ -55,7 +55,7 @@ int
int i;
/* two spaces are very common in lease file, after them
* nearly everything differs */
if (a[2] != b[2]) {
if (likely(a[2] != b[2])) {
return false;
}
/* " binding state " == 16 chars, this will skip right