[Bug lto/84044] New: Spurious -Wodr warning with -flto

2018-01-25 Thread geoffrey at allott dot email
Assignee: unassigned at gcc dot gnu.org Reporter: geoffrey at allott dot email CC: marxin at gcc dot gnu.org Target Milestone: --- a.cpp = struct A { virtual ~A(); }; A::~A() {} b.cpp = struct A { virtual ~A(); }; struct B { A a; A get

[Bug lto/84044] Spurious -Wodr warning with -flto

2018-01-25 Thread geoffrey at allott dot email
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84044 --- Comment #1 from Geoffrey Allott --- I discovered that in b.cpp a free function A get() { return A(); } also triggers the error. Struct B is not necessary.

[Bug lto/84044] Spurious -Wodr warning with -flto

2018-01-25 Thread geoffrey at allott dot email
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84044 --- Comment #2 from Geoffrey Allott --- Or even simply A a;

[Bug tree-optimization/81834] New: Simple loop with single variable is not optimized out

2017-08-12 Thread geoffrey at allott dot email
Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: geoffrey at allott dot email Target Milestone: --- The following code: int main() { for(int i=0; i += i < 1000, i < 1000;); } optimizes on x86_64 to the following code: main: .LFB0:

[Bug tree-optimization/81834] loop with increment conditional on IV is not optimized out

2017-08-16 Thread geoffrey at allott dot email
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81834 --- Comment #2 from Geoffrey Allott --- Hi Richard, I agree that this seems quite 'arcane' at first glance; I should explain that I found it when an empty for loop failed to optimize out in rust - the reduced test case failed to optimize in clang