From 019357d23488c773cdef1dd077cc8915b6012d52 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Tue, 6 Jun 2000 21:35:37 +0000 Subject: Add __builtin_expect in many places. --- iconvdata/iso646.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'iconvdata/iso646.c') diff --git a/iconvdata/iso646.c b/iconvdata/iso646.c index ba0addcd78..ea36ebc5cd 100644 --- a/iconvdata/iso646.c +++ b/iconvdata/iso646.c @@ -145,7 +145,7 @@ gconv_init (struct __gconv_step *step) } result = __GCONV_NOCONV; - if (dir != illegal_dir) + if (__builtin_expect (dir, from_iso646) != illegal_dir) { new_data = (struct iso646_data *) malloc (sizeof (struct iso646_data)); @@ -404,7 +404,7 @@ gconv_end (struct __gconv_step *data) \ /* Hopefully gcc can recognize that the following `if' is only true \ when we reach the default case in the `switch' statement. */ \ - if (failure == __GCONV_ILLEGAL_INPUT) \ + if (__builtin_expect (failure, __GCONV_OK) == __GCONV_ILLEGAL_INPUT) \ { \ if (! ignore_errors_p ()) \ { \ @@ -881,7 +881,7 @@ gconv_end (struct __gconv_step *data) break; \ } \ \ - if (failure == __GCONV_ILLEGAL_INPUT) \ + if (__builtin_expect (failure, __GCONV_OK) == __GCONV_ILLEGAL_INPUT) \ { \ if (! ignore_errors_p ()) \ { \ -- cgit v1.2.3