On 8/22/26 12:08, Matt Turner wrote:
diff --git ./accel/tcg/tcg-all.c ./accel/tcg/tcg-all.c
index 7186c10cf0..c9874a286a 100644
--- ./accel/tcg/tcg-all.c
+++ ./accel/tcg/tcg-all.c
@@ -254,6 +254,7 @@ static void tcg_set_one_insn_per_tb(Object *obj, bool 
value, Error **errp)
      s->one_insn_per_tb = value;
      /* Set the global also: this changes the behaviour */
      qatomic_set(&one_insn_per_tb, value);
+    tcg_update_all_cflags();
  }
...
diff --git ./util/log.c ./util/log.c
index 7cffbc1bf8..3fa46a67fa 100644
--- ./util/log.c
+++ ./util/log.c
@@ -27,6 +27,7 @@
  #include "qemu/thread.h"
  #include "qemu/lockable.h"
  #include "qemu/rcu.h"
+#include "system/tcg.h"
  #ifdef CONFIG_LINUX
  #include <sys/syscall.h>
  #endif
@@ -301,6 +302,9 @@ static bool qemu_set_log_internal(const char *filename, 
bool changed_name,
  #endif
      qemu_loglevel = log_flags;
+ /* CPU_LOG_TB_NOCHAIN feeds into the per-CPU cflags. */
+    tcg_update_all_cflags();

I'm not keen on these placements.  I know they're needed for HMP, but I'd rather have these calls in HMP, after updating state.

+void tcg_update_cflags(CPUState *cpu)
+{
+}
+
Where does this get used outside of tcg itself?  I think only tcg_update_all_cflags() should be stubbed, and indeed the only one visible outside of accel/tcg/.

Phil, is the stub itself better placed in accel/stubs/ or accel/tcg/?  I'm unsure what organization you're working toward.


r~


Reply via email to