[PATCH] tcg: Fix documentation for tcg_constant_* vs tcg_temp_free_*

Richard Henderson posted 1 patch 2 days, 5 hours ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/next-importer-push tags/patchew/20210610164111.233902-1-richard.henderson@linaro.org
Maintainers: Richard Henderson <richard.henderson@linaro.org>
include/tcg/tcg.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

[PATCH] tcg: Fix documentation for tcg_constant_* vs tcg_temp_free_*

Posted by Richard Henderson 2 days, 5 hours ago
At some point during the development of tcg_constant_*, I changed
my mind about whether such temps should be able to be passed to
tcg_temp_free_*.  The final version committed allows this, but the
commentary was not updated to match.

Fixes: c0522136adf
Reported-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
 include/tcg/tcg.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/include/tcg/tcg.h b/include/tcg/tcg.h
index 1d056ed0ed..064dab383b 100644
--- a/include/tcg/tcg.h
+++ b/include/tcg/tcg.h
@@ -1095,7 +1095,8 @@ TCGv_vec tcg_const_ones_vec_matching(TCGv_vec);
 
 /*
  * Locate or create a read-only temporary that is a constant.
- * This kind of temporary need not and should not be freed.
+ * This kind of temporary need not be freed, but for convenience
+ * will be silently ignored by tcg_temp_free_*.
  */
 TCGTemp *tcg_constant_internal(TCGType type, int64_t val);
 
-- 
2.25.1


Re: [PATCH] tcg: Fix documentation for tcg_constant_* vs tcg_temp_free_*

Posted by Alex Bennée 1 day, 11 hours ago
Richard Henderson <richard.henderson@linaro.org> writes:

> At some point during the development of tcg_constant_*, I changed
> my mind about whether such temps should be able to be passed to
> tcg_temp_free_*.  The final version committed allows this, but the
> commentary was not updated to match.
>
> Fixes: c0522136adf
> Reported-by: Peter Maydell <peter.maydell@linaro.org>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>

-- 
Alex Bennée

RE: [PATCH] tcg: Fix documentation for tcg_constant_* vs tcg_temp_free_*

Posted by Luis Fernando Fujita Pires 2 days, 4 hours ago
From: Richard Henderson <richard.henderson@linaro.org>
> At some point during the development of tcg_constant_*, I changed my mind
> about whether such temps should be able to be passed to tcg_temp_free_*.
> The final version committed allows this, but the commentary was not updated
> to match.
> 
> Fixes: c0522136adf
> Reported-by: Peter Maydell <peter.maydell@linaro.org>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
>  include/tcg/tcg.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Reviewed-by: Luis Pires <luis.pires@eldorado.org.br>

--
Luis Pires
Instituto de Pesquisas ELDORADO
Aviso Legal - Disclaimer <https://www.eldorado.org.br/disclaimer.html>