<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/90289>90289</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
llvm/tools/llvm-exegesis/lib/SubprocessMemory.cpp:146: Poor choice of range variable type ?
</td>
</tr>
<tr>
<th>Labels</th>
<td>
tools:llvm-exegesis,
code-quality
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
dcb314
</td>
</tr>
</table>
<pre>
Static analyser cppcheck says:
llvm/tools/llvm-exegesis/lib/SubprocessMemory.cpp:146:20: performance: Range variable 'SharedMemoryName' should be declared as const reference. [iterateByValue]
Source code is
for (std::string SharedMemoryName : SharedMemoryNames) {
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJykUkGPnDwM_TXmYu2IODBZDhyYb8Ttq6qO1HsIBtIGQpOwKv--gt2q2732YunZED-_93SMdlyYayhvUN4zvaXJh7o3nRRF1vl-rx9JJ2tQL9rtkQOadTUTm-8Y9R5BNpDfIX-rzr3MQG3y3kWg9oBP_JNHjvbEtgNqH1u3Bm84xv959mG_mHUF2YjiCrKhHGSDK4fBh1kvhg_4RS8j44sOVneOEUg9Jh24f_3_k54ZSGGc_OZ67Bh7Nu6Yo45o_BITBh448GL4glDebOKgE9_2r9ptDOX9_Q0PvwXDaHzPaOP7CQ4-INBzTP1xt2xiCnYZ8SMZPDh_bEagCkHd3j_4WrO-ln0lK51xLZQohBKyrLKpVloUlRHl0AtWeX-VWouiYyWNyoVQJrM15VTkBV2JCpLVhZUahq7I5VWXpaQKipxnbd3lcOLiw5jZGDeuq5yeq8zpjl08rSd69Uw2HzwjoP-A6FDj6cemnU370SzvWajPT7ttjFDkzsYU_6xJNjmu_z0O-Nn7gGby1jD6AcPfSUj7eqjdZltw9ZTSegaSWqB2tGnauovx89vm3wTW4L-xSUDtqcVB5JTjVwAAAP__dd35gw">