<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/79703>79703</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            flang/lib/Optimizer/CodeGen/Target.cpp:50: possible performance problem ?
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            flang
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          dcb314
      </td>
    </tr>
</table>

<pre>
    Static analyser cppcheck says:

flang/lib/Optimizer/CodeGen/Target.cpp:50:34: performance: Function parameter 'context' should be passed by const reference. [passedByValue]

Source code is

static void typeTodo(const llvm::fltSemantics *sem, mlir::Location loc,
 std::string context) {


</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJycks-OmzAQh59muFgbkTEEOHBIdkUvlXrIqnf_mRC3Blsesyp9-oqwanPuBWT9RjPzaT7F7MaZqIf6AvVboZZ8D6m3RstjVehg1_6aVXZGqFn5lSkJE6O5k_kpWK0M8gzlG5Sf35tX8wg4eKcBh28xu8n9pgQ4vAZLX2gGHN5VGikfTIwgz3UJ8iwrkGcRKd1CmtRsaHsOy2yyC7OIKqmJMiUB2JgwZ_qVARvB97B4KzSJqJjJCr0KE2bOItGNEs2GDgLqy55e1u_KLwT12_O-17AkQ8IES8Lxc8I79UdwVuQ10nuwAbDdB3j_MW3k8nzz-UqTmrMzLADPTBPgq5i8S3vB12DUA8MHA_i6Nxec7R5zTm4exV-sTkBzed6jsL20nexUQf2xKU-yPcpWFvf-VOuq6dpKVbe2bm9KN2VTdaRKg8Y2RheuxxKr8ojNsa26Sh6kQVWTxaPSpxb1CaqSJuX8YcM5hDQWjnmhvumaUhZeafL88ALx8664KZL6rf5FLyNDVXrHmf91yC576v9PAxEDs9OenlUQMQXtaRIgh2JJvr_nHB_a4QA4jC7fF30wYdrGbWfZfy8xhR9kMuDwgGLA4cH1JwAA__951O-L">