[Bug analyzer/112655] analyzer/infinite-loop.cc:75: Possible performance problem ?

2023-12-14 Thread dmalcolm at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112655

David Malcolm  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|ASSIGNED|RESOLVED

--- Comment #3 from David Malcolm  ---
Should be fixed by the above patch.

[Bug analyzer/112655] analyzer/infinite-loop.cc:75: Possible performance problem ?

2023-12-14 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112655

--- Comment #2 from GCC Commits  ---
The master branch has been updated by David Malcolm :

https://gcc.gnu.org/g:8cf5afba5dc482fe7063654720bfb0c45354998c

commit r14-6549-g8cf5afba5dc482fe7063654720bfb0c45354998c
Author: David Malcolm 
Date:   Thu Dec 14 09:10:10 2023 -0500

analyzer: cleanups [PR112655]

Avoid copying eedges in infinite_loop::infinite_loop.

Use initializer lists in the various places reported in
PR analyzer/112655 (apart from coord_test's ctor, which
would require nontrivial refactoring).

gcc/analyzer/ChangeLog:
PR analyzer/112655
* infinite-loop.cc (infinite_loop::infinite_loop): Pass eedges
via rvalue reference rather than by value.
(starts_infinite_loop_p): Move eedges when constructing an
infinite_loop instance.
* sm-file.cc (fileptr_state_machine::fileptr_state_machine): Use
initializer list for states.
* sm-sensitive.cc
(sensitive_state_machine::sensitive_state_machine): Likewise.
* sm-signal.cc (signal_state_machine::signal_state_machine):
Likewise.
* sm-taint.cc (taint_state_machine::taint_state_machine):
Likewise.
* varargs.cc (va_list_state_machine::va_list_state_machine):
Likewise.

Signed-off-by: David Malcolm 

[Bug analyzer/112655] analyzer/infinite-loop.cc:75: Possible performance problem ?

2023-12-12 Thread dmalcolm at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112655

David Malcolm  changed:

   What|Removed |Added

 Ever confirmed|0   |1
 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2023-12-12

--- Comment #1 from David Malcolm  ---
Thanks!  Am working on a fix.