[Bug c++/89257] Bad optimisation at -O3 with vector of pairs

2019-02-08 Thread matt at ookypooky dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89257 --- Comment #1 from Matt A --- Apologies, I should have clarified this is on x86_64: $ g++ -v Using built-in specs. COLLECT_GCC=/software/thirdparty/gcc/7.2.0-0.el7_64/bin/g++ COLLECT_LTO_WRAPPER=/software/thirdparty/gcc/7.2.0-0.el7_64/libexec/g

[Bug c++/89257] New: Bad optimisation at -O3 with vector of pairs

2019-02-08 Thread matt at ookypooky dot com
++ Assignee: unassigned at gcc dot gnu.org Reporter: matt at ookypooky dot com Target Milestone: --- Code as follows: -- #include #include struct Foo { Foo () = default; Foo (Foo &&f) : x (f.x) , y (f.y) { f.y = 0; } int

[Bug c++/89220] Inconsistent behaviour of class template type deduction

2019-02-06 Thread matt at ookypooky dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89220 --- Comment #1 from Matt A --- // ... but this compiles again auto z = ((Foo(123)))(0);

[Bug c++/89220] New: Inconsistent behaviour of class template type deduction

2019-02-06 Thread matt at ookypooky dot com
Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: matt at ookypooky dot com Target Milestone: --- Demonstrated by the following code: template struct Foo { Foo (T) {} auto operator () (int) { return 0; } }; // this compiles

[Bug c++/83331] New: Compile time evaluation of cbrt does not match library evaluation

2017-12-08 Thread matt at ookypooky dot com
Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: matt at ookypooky dot com Target Milestone: --- The following code: -- #include #include int main () { double x = 123.456; std::cout << std::cbrt (x) - std::cbrt (1

[Bug c++/57510] New: initializer_list memory leak

2013-06-03 Thread matt at ookypooky dot com
++ Assignee: unassigned at gcc dot gnu.org Reporter: matt at ookypooky dot com Created attachment 30247 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30247&action=edit Code demonstrating the problem It looks as though initializer_list can suffer from memory leaks - if during construc