[Bug rust/117762] New: libgrust/libproc_macro_internal/tokenstream.cc: 3 * performance issues ?

2024-11-24 Thread dcb314 at hotmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117762

Bug ID: 117762
   Summary: libgrust/libproc_macro_internal/tokenstream.cc: 3 *
performance issues ?
   Product: gcc
   Version: 15.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rust
  Assignee: unassigned at gcc dot gnu.org
  Reporter: dcb314 at hotmail dot com
CC: dkm at gcc dot gnu.org, gcc-rust at gcc dot gnu.org,
pierre-emmanuel.patry at embecosm dot com
  Target Milestone: ---

Static analyser cppcheck says:

trunk/libgrust/libproc_macro_internal/tokenstream.cc:32:55: performance:
Function parameter 'vec' should be passed by const reference. [passedByValue]
trunk/libgrust/libproc_macro_internal/tokenstream.cc:35:13: performance: Range
variable 'tt' should be declared as const reference. [iterateByValue]
trunk/libgrust/libproc_macro_internal/tokenstream.cc:67:30: performance:
Function parameter 'tree' should be passed by const reference. [passedByValue]

Might be worth fixing.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug rust/117762] libgrust/libproc_macro_internal/tokenstream.cc: 3 * performance issues ?

2024-11-24 Thread dcb314 at hotmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117762

--- Comment #1 from David Binderman  ---
Five more little problems in libgrust:

trunk/libgrust/libproc_macro_internal/group.cc:28:32: performance: Function
parameter 'stream' should be passed by const reference. [passedByValue]
trunk/libgrust/libproc_macro_internal/ident.cc:62:32: performance: Function
parameter 'str' should be passed by const reference. [passedByValue]
trunk/libgrust/libproc_macro_internal/tokentree.cc:28:34: performance: Function
parameter 'group' should be passed by const reference. [passedByValue]
trunk/libgrust/libproc_macro_internal/tokentree.cc:36:34: performance: Function
parameter 'ident' should be passed by const reference. [passedByValue]
trunk/libgrust/libproc_macro_internal/tokentree.cc:52:36: performance: Function
parameter 'literal' should be passed by const reference. [passedByValue]

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug rust/117762] libgrust/libproc_macro_internal/tokenstream.cc: 3 * performance issues ?

2024-11-24 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117762

Eric Gallager  changed:

   What|Removed |Added

 Blocks||89863
 CC||egallager at gcc dot gnu.org


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89863
[Bug 89863] [meta-bug] Issues in gcc that other static analyzers (cppcheck,
clang-static-analyzer, PVS-studio) find that gcc misses
-- 
You are receiving this mail because:
You are on the CC list for the bug.