diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2021-03-18 10:21:45 -0600 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2021-06-19 08:51:11 -0700 |
commit | 90163900e3c71ed2743cafd27542d941c4e25991 (patch) | |
tree | d2b244283c9407039e7d58dcae3b0fbe356ba170 /tcg/optimize.c | |
parent | 7319d83a735004ba24b439491a9d7727dac2ddbe (diff) |
tcg: Add tcg_call_flags
We're going to change how to look up the call flags from a TCGop,
so extract it as a helper.
Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'tcg/optimize.c')
-rw-r--r-- | tcg/optimize.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tcg/optimize.c b/tcg/optimize.c index 37c902283e..211a4209a0 100644 --- a/tcg/optimize.c +++ b/tcg/optimize.c @@ -25,6 +25,7 @@ #include "qemu/osdep.h" #include "tcg/tcg-op.h" +#include "tcg-internal.h" #define CASE_OP_32_64(x) \ glue(glue(case INDEX_op_, x), _i32): \ @@ -1481,7 +1482,7 @@ void tcg_optimize(TCGContext *s) break; case INDEX_op_call: - if (!(op->args[nb_oargs + nb_iargs + 1] + if (!(tcg_call_flags(op) & (TCG_CALL_NO_READ_GLOBALS | TCG_CALL_NO_WRITE_GLOBALS))) { for (i = 0; i < nb_globals; i++) { if (test_bit(i, temps_used.l)) { |