On Wed, 3 May 2023 at 08:12, Richard Henderson
<[email protected]> wrote:
>
> Emphasize that the constant is signed.
>
> Signed-off-by: Richard Henderson <[email protected]>
> ---
> tcg/sparc64/tcg-target.c.inc | 30 +++++++++++++++---------------
> 1 file changed, 15 insertions(+), 15 deletions(-)
Commit message says we're just doing a rename, but...
> @@ -425,15 +425,15 @@ static void tcg_out_movi_int(TCGContext *s, TCGType
> type, TCGReg ret,
> tcg_target_long hi, lo = (int32_t)arg;
> tcg_target_long test, lsb;
>
> - /* A 32-bit constant, or 32-bit zero-extended to 64-bits. */
> - if (type == TCG_TYPE_I32 || arg == (uint32_t)arg) {
> - tcg_out_movi_imm32(s, ret, arg);
> + /* A 13-bit constant sign-extended to 64-bits. */
> + if (check_fit_tl(arg, 13)) {
> + tcg_out_movi_s13(s, ret, arg);
> return;
> }
>
> - /* A 13-bit constant sign-extended to 64-bits. */
> - if (check_fit_tl(arg, 13)) {
> - tcg_out_movi_imm13(s, ret, arg);
> + /* A 32-bit constant, or 32-bit zero-extended to 64-bits. */
> + if (type == TCG_TYPE_I32 || arg == (uint32_t)arg) {
> + tcg_out_movi_imm32(s, ret, arg);
> return;
> }
...the commit has other code changes. Should these be in some
other patch ?
thanks
-- PMM