Bug#173513: [Bug tree-optimization/3713] Pointers to functions or member functions are not folded or inlined
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-07-04 21:54 -------
Actually the testcase above is not really valid.
The below testcase is more correct as A::p cannot be inlined as it has its address taken (stupid bug in
the C++ front-end really).
But here is a better testcase:
struct A
{
void foo()
{
}
};
int main()
{
void (A::* const p)() = & A::foo;
A a;
(a.*p)();
}
---- cut ---
D.1749 = (int) foo;
if ((D.1749 & 1) != 0) goto <L0>; else goto <L5>;
hmm, we need to know the alignment of a function, which is weird. Why is the C++ front-end
producing code like this, oh well.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3713
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
Reply to: