--- Comment #8 from mbligh at mbligh dot org 2006-10-23 21:50 ---
> Initialize the variable and forget about inefficiency. Again this is fixed
> for
> 4.2.0, the warning is only because __builtin_expect gets in the way of
> figuring
> out if the variable is use
--- Comment #6 from mbligh at mbligh dot org 2006-10-23 21:42 ---
Re the non-inlined functions ...
Have been discussing this with Andrew Morton.
what do we do then? Adding dead code to fix the fact that gcc can't see into
other functions is incorrect and inefficient.
Having lo
--- Comment #4 from mbligh at mbligh dot org 2006-10-23 21:19 ---
And indeed, if I remove that unlikely(), it does work.
There's another set of these where the called initializer is not inlined,
ie:
int x;
initializer(&x);
Which it seems totally blind to, even if the initial
--- Comment #3 from mbligh at mbligh dot org 2006-10-23 21:08 ---
Yeah, is builtin_expect ;-(
#define likely(x) __builtin_expect(!!(x), 1)
#define unlikely(x) __builtin_expect(!!(x), 0)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29574
Severity: normal
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: mbligh at mbligh dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29574