Skip to contentSkip to conversation

softmmu: Add missing trace-events file

PATCH Applied Philippe Mathieu-Daudé 5 participants 10 messages Aug 5, 2020 – Aug 12, 2020 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 softmmu: Add missing trace-events file

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

---
 Makefile.objs        |  1 +
 softmmu/balloon.c    |  2 +-
 softmmu/ioport.c     |  2 +-
 softmmu/memory.c     |  2 +-
 softmmu/vl.c         |  2 +-
 softmmu/trace-events | 28 ++++++++++++++++++++++++++++
 trace-events         | 27 ---------------------------
 7 files changed, 33 insertions(+), 31 deletions(-)
 create mode 100644 softmmu/trace-events
Makefile.objs +1 -0
index d22b3b45d7..61c1ad3c3b 100644
@@ -190,6 +190,7 @@ trace-events-subdirs += hw/gpio
 trace-events-subdirs += hw/riscv
 trace-events-subdirs += migration
 trace-events-subdirs += net
+trace-events-subdirs += softmmu
 trace-events-subdirs += ui
 endif
 trace-events-subdirs += hw/core
softmmu/balloon.c +1 -1
index 354408c6ea..23452295cd 100644
@@ -28,10 +28,10 @@
 #include "qemu/atomic.h"
 #include "sysemu/kvm.h"
 #include "sysemu/balloon.h"
-#include "trace-root.h"
 #include "qapi/error.h"
 #include "qapi/qapi-commands-misc.h"
 #include "qapi/qmp/qerror.h"
+#include "trace.h"
 
 static QEMUBalloonEvent *balloon_event_fn;
 static QEMUBalloonStatus *balloon_stat_fn;
softmmu/ioport.c +1 -1
index 04e360e79a..cb8adb0b93 100644
@@ -28,9 +28,9 @@
 #include "qemu/osdep.h"
 #include "cpu.h"
 #include "exec/ioport.h"
-#include "trace-root.h"
 #include "exec/memory.h"
 #include "exec/address-spaces.h"
+#include "trace.h"
 
 typedef struct MemoryRegionPortioList {
     MemoryRegion mr;
softmmu/memory.c +1 -1
index af25987518..d030eb6f7c 100644
@@ -24,7 +24,7 @@
 #include "qemu/main-loop.h"
 #include "qemu/qemu-print.h"
 #include "qom/object.h"
-#include "trace-root.h"
+#include "trace.h"
 
 #include "exec/memory-internal.h"
 #include "exec/ram_addr.h"
softmmu/vl.c +1 -1
index 4eb9d1f7fd..f7b103467c 100644
@@ -90,7 +90,7 @@
 
 #include "disas/disas.h"
 
-#include "trace-root.h"
+#include "trace.h"
 #include "trace/control.h"
 #include "qemu/plugin.h"
 #include "qemu/queue.h"
softmmu/trace-events new file +28 -0
new file mode 100644
index 0000000000..b80ca042e1
@@ -0,0 +1,28 @@
+# See docs/devel/tracing.txt for syntax documentation.
+
+# balloon.c
+# Since requests are raised via monitor, not many tracepoints are needed.
+balloon_event(void *opaque, unsigned long addr) "opaque %p addr %lu"
+
+# ioport.c
+cpu_in(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
+cpu_out(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
+
+# memory.c
+memory_region_ops_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ops_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_subpage_read(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_subpage_write(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ram_device_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ram_device_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+flatview_new(void *view, void *root) "%p (root %p)"
+flatview_destroy(void *view, void *root) "%p (root %p)"
+flatview_destroy_rcu(void *view, void *root) "%p (root %p)"
+
+# vl.c
+vm_state_notify(int running, int reason, const char *reason_str) "running %d reason %d (%s)"
+load_file(const char *name, const char *path) "name %s location %s"
+runstate_set(int current_state, const char *current_state_str, int new_state, const char *new_state_str) "current_run_state %d (%s) new_state %d (%s)"
+system_wakeup_request(int reason) "reason=%d"
+qemu_system_shutdown_request(int reason) "reason=%d"
+qemu_system_powerdown_request(void) ""
trace-events +0 -27
index 42107ebc69..5882c2d5fc 100644
@@ -25,22 +25,6 @@
 #
 # The <format-string> should be a sprintf()-compatible format string.
 
-# ioport.c
-cpu_in(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
-cpu_out(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
-
-# balloon.c
-# Since requests are raised via monitor, not many tracepoints are needed.
-balloon_event(void *opaque, unsigned long addr) "opaque %p addr %lu"
-
-# vl.c
-vm_state_notify(int running, int reason, const char *reason_str) "running %d reason %d (%s)"
-load_file(const char *name, const char *path) "name %s location %s"
-runstate_set(int current_state, const char *current_state_str, int new_state, const char *new_state_str) "current_run_state %d (%s) new_state %d (%s)"
-system_wakeup_request(int reason) "reason=%d"
-qemu_system_shutdown_request(int reason) "reason=%d"
-qemu_system_powerdown_request(void) ""
-
 # dma-helpers.c
 dma_blk_io(void *dbs, void *bs, int64_t offset, bool to_dev) "dbs=%p bs=%p offset=%" PRId64 " to_dev=%d"
 dma_aio_cancel(void *dbs) "dbs=%p"
@@ -55,17 +39,6 @@ ram_block_discard_range(const char *rbname, void *hva, size_t length, bool need_
 memory_notdirty_write_access(uint64_t vaddr, uint64_t ram_addr, unsigned size) "0x%" PRIx64 " ram_addr 0x%" PRIx64 " size %u"
 memory_notdirty_set_dirty(uint64_t vaddr) "0x%" PRIx64
 
-# memory.c
-memory_region_ops_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ops_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_subpage_read(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_subpage_write(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ram_device_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ram_device_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-flatview_new(void *view, void *root) "%p (root %p)"
-flatview_destroy(void *view, void *root) "%p (root %p)"
-flatview_destroy_rcu(void *view, void *root) "%p (root %p)"
-
 # gdbstub.c
 gdbstub_op_start(const char *device) "Starting gdbstub using device %s"
 gdbstub_op_exiting(uint8_t code) "notifying exit with code=0x%02x"
Signature · 1 line
2.21.3
#1 lore raw
Quoted 4 lines · Philippe Mathieu-Daudé

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Dang! I'd like to have this in 5.1 if at all possible.

Quoted 150 lines
---
 Makefile.objs        |  1 +
 softmmu/balloon.c    |  2 +-
 softmmu/ioport.c     |  2 +-
 softmmu/memory.c     |  2 +-
 softmmu/vl.c         |  2 +-
 softmmu/trace-events | 28 ++++++++++++++++++++++++++++
 trace-events         | 27 ---------------------------
 7 files changed, 33 insertions(+), 31 deletions(-)
 create mode 100644 softmmu/trace-events
Makefile.objs +1 -0
index d22b3b45d7..61c1ad3c3b 100644
@@ -190,6 +190,7 @@ trace-events-subdirs += hw/gpio
 trace-events-subdirs += hw/riscv
 trace-events-subdirs += migration
 trace-events-subdirs += net
+trace-events-subdirs += softmmu
 trace-events-subdirs += ui
 endif
 trace-events-subdirs += hw/core
softmmu/balloon.c +1 -1
index 354408c6ea..23452295cd 100644
@@ -28,10 +28,10 @@
 #include "qemu/atomic.h"
 #include "sysemu/kvm.h"
 #include "sysemu/balloon.h"
-#include "trace-root.h"
 #include "qapi/error.h"
 #include "qapi/qapi-commands-misc.h"
 #include "qapi/qmp/qerror.h"
+#include "trace.h"
 
 static QEMUBalloonEvent *balloon_event_fn;
 static QEMUBalloonStatus *balloon_stat_fn;
softmmu/ioport.c +1 -1
index 04e360e79a..cb8adb0b93 100644
@@ -28,9 +28,9 @@
 #include "qemu/osdep.h"
 #include "cpu.h"
 #include "exec/ioport.h"
-#include "trace-root.h"
 #include "exec/memory.h"
 #include "exec/address-spaces.h"
+#include "trace.h"
 
 typedef struct MemoryRegionPortioList {
     MemoryRegion mr;
softmmu/memory.c +1 -1
index af25987518..d030eb6f7c 100644
@@ -24,7 +24,7 @@
 #include "qemu/main-loop.h"
 #include "qemu/qemu-print.h"
 #include "qom/object.h"
-#include "trace-root.h"
+#include "trace.h"
 
 #include "exec/memory-internal.h"
 #include "exec/ram_addr.h"
softmmu/vl.c +1 -1
index 4eb9d1f7fd..f7b103467c 100644
@@ -90,7 +90,7 @@
 
 #include "disas/disas.h"
 
-#include "trace-root.h"
+#include "trace.h"
 #include "trace/control.h"
 #include "qemu/plugin.h"
 #include "qemu/queue.h"
softmmu/trace-events new file +28 -0
new file mode 100644
index 0000000000..b80ca042e1
@@ -0,0 +1,28 @@
+# See docs/devel/tracing.txt for syntax documentation.
+
+# balloon.c
+# Since requests are raised via monitor, not many tracepoints are needed.
+balloon_event(void *opaque, unsigned long addr) "opaque %p addr %lu"
+
+# ioport.c
+cpu_in(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
+cpu_out(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
+
+# memory.c
+memory_region_ops_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ops_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_subpage_read(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_subpage_write(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ram_device_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ram_device_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+flatview_new(void *view, void *root) "%p (root %p)"
+flatview_destroy(void *view, void *root) "%p (root %p)"
+flatview_destroy_rcu(void *view, void *root) "%p (root %p)"
+
+# vl.c
+vm_state_notify(int running, int reason, const char *reason_str) "running %d reason %d (%s)"
+load_file(const char *name, const char *path) "name %s location %s"
+runstate_set(int current_state, const char *current_state_str, int new_state, const char *new_state_str) "current_run_state %d (%s) new_state %d (%s)"
+system_wakeup_request(int reason) "reason=%d"
+qemu_system_shutdown_request(int reason) "reason=%d"
+qemu_system_powerdown_request(void) ""
trace-events +0 -20
index 42107ebc69..5882c2d5fc 100644
@@ -25,22 +25,6 @@
 #
 # The <format-string> should be a sprintf()-compatible format string.
 
-# ioport.c
-cpu_in(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
-cpu_out(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
-
-# balloon.c
-# Since requests are raised via monitor, not many tracepoints are needed.
-balloon_event(void *opaque, unsigned long addr) "opaque %p addr %lu"
-
-# vl.c
-vm_state_notify(int running, int reason, const char *reason_str) "running %d reason %d (%s)"
-load_file(const char *name, const char *path) "name %s location %s"
-runstate_set(int current_state, const char *current_state_str, int new_state, const char *new_state_str) "current_run_state %d (%s) new_state %d (%s)"
-system_wakeup_request(int reason) "reason=%d"
-qemu_system_shutdown_request(int reason) "reason=%d"
-qemu_system_powerdown_request(void) ""
-
 # dma-helpers.c
 dma_blk_io(void *dbs, void *bs, int64_t offset, bool to_dev) "dbs=%p bs=%p offset=%" PRId64 " to_dev=%d"
 dma_aio_cancel(void *dbs) "dbs=%p"
@@ -55,17 +39,6 @@ ram_block_discard_range(const char *rbname, void *hva, size_t length, bool need_
 memory_notdirty_write_access(uint64_t vaddr, uint64_t ram_addr, unsigned size) "0x%" PRIx64 " ram_addr 0x%" PRIx64 " size %u"
 memory_notdirty_set_dirty(uint64_t vaddr) "0x%" PRIx64
 
-# memory.c
-memory_region_ops_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ops_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_subpage_read(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"

trace-events ram_block_discard_range(const char *rbname, void *hva, size_t length, bool need_ · line 44

Quoted 10 lines
trace-events +0 -7
-memory_region_subpage_write(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ram_device_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ram_device_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-flatview_new(void *view, void *root) "%p (root %p)"
-flatview_destroy(void *view, void *root) "%p (root %p)"
-flatview_destroy_rcu(void *view, void *root) "%p (root %p)"
-
 # gdbstub.c
 gdbstub_op_start(const char *device) "Starting gdbstub using device %s"
 gdbstub_op_exiting(uint8_t code) "notifying exit with code=0x%02x"

scripts/cleanup-trace-events.pl finds these (and corrects them in-place, which is not what we want here). It finds a few more. I'll look more closely and report back.

#2 lore raw
Quoted 9 lines · Markus Armbruster
Quoted 4 lines · Philippe Mathieu-Daudé

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Dang! I'd like to have this in 5.1 if at all possible.

[...]

Quoted 4 lines

scripts/cleanup-trace-events.pl finds these (and corrects them in-place, which is not what we want here). It finds a few more. I'll look more closely and report back.

Congratulation, you just found the first job you'll add to our GitLab CI =)

#3 lore raw
Quoted 10 lines · Philippe Mathieu-Daudé
Quoted 9 lines · Markus Armbruster
Quoted 4 lines · Philippe Mathieu-Daudé

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Dang! I'd like to have this in 5.1 if at all possible.

Quoted 8 lines

[...]

Quoted 4 lines

scripts/cleanup-trace-events.pl finds these (and corrects them in-place, which is not what we want here). It finds a few more. I'll look more closely and report back.

Congratulation, you just found the first job you'll add to our GitLab CI =)

cleanup-trace-events.pl is not fit for use in CI; see the list of funnies in "[PATCH 4/4] trace-events: Fix attribution of trace points to source". Perhaps it could be sufficiently improved.

#4 lore raw
In reply to Markus Armbruster
Quoted 6 lines · Markus Armbruster
Quoted 4 lines

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Dang! I'd like to have this in 5.1 if at all possible.

Does this matter at all for usage of tracepoints?

Paolo

#5 lore raw
Quoted 5 lines · Paolo Bonzini
Quoted 4 lines · Markus Armbruster
Quoted 4 lines

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Quoted 8 lines
Quoted 2 lines

Dang! I'd like to have this in 5.1 if at all possible.

Does this matter at all for usage of tracepoints?

Paolo

Hi Paolo, I tested both with and without the fix,
the events seem to be generated anyway.

Using simple trace backend, simple smoke test tracing the memory_region_ops_read from softmmu/memory.c

Thanks,

Claudio

#6 lore raw
Quoted 10 lines · Claudio Fontana
Quoted 9 lines · Paolo Bonzini
Quoted 6 lines · Markus Armbruster
Quoted 4 lines

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Dang! I'd like to have this in 5.1 if at all possible.

Does this matter at all for usage of tracepoints?

Markus said on IRC it is a false alarm, can wait 5.2 :)

Quoted 14 lines
Quoted 4 lines

Paolo

Hi Paolo, I tested both with and without the fix,
the events seem to be generated anyway.

Using simple trace backend, simple smoke test tracing the memory_region_ops_read from softmmu/memory.c

Thanks,

Claudio

#7 lore raw
In reply to Paolo Bonzini
Quoted 9 lines · Paolo Bonzini
Quoted 6 lines · Markus Armbruster
Quoted 4 lines

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Dang! I'd like to have this in 5.1 if at all possible.

Does this matter at all for usage of tracepoints?

I retracted quickly on IRC, but neglected to post. This can wait for 5.2.

Tested-by Reviewed-by on v1 1/1
#8 lore raw
In reply to Philippe Mathieu-Daudé
Quoted 6 lines · Philippe Mathieu-Daudé

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

missed, sorry.

I wonder if checkpatch could emit a warning when moving files around directories when they use tracing.. will take a look.

Ciao,

Claudio

Quoted 160 lines
---
 Makefile.objs        |  1 +
 softmmu/balloon.c    |  2 +-
 softmmu/ioport.c     |  2 +-
 softmmu/memory.c     |  2 +-
 softmmu/vl.c         |  2 +-
 softmmu/trace-events | 28 ++++++++++++++++++++++++++++
 trace-events         | 27 ---------------------------
 7 files changed, 33 insertions(+), 31 deletions(-)
 create mode 100644 softmmu/trace-events
Makefile.objs +1 -0
index d22b3b45d7..61c1ad3c3b 100644
@@ -190,6 +190,7 @@ trace-events-subdirs += hw/gpio
 trace-events-subdirs += hw/riscv
 trace-events-subdirs += migration
 trace-events-subdirs += net
+trace-events-subdirs += softmmu
 trace-events-subdirs += ui
 endif
 trace-events-subdirs += hw/core
softmmu/balloon.c +1 -1
index 354408c6ea..23452295cd 100644
@@ -28,10 +28,10 @@
 #include "qemu/atomic.h"
 #include "sysemu/kvm.h"
 #include "sysemu/balloon.h"
-#include "trace-root.h"
 #include "qapi/error.h"
 #include "qapi/qapi-commands-misc.h"
 #include "qapi/qmp/qerror.h"
+#include "trace.h"
 
 static QEMUBalloonEvent *balloon_event_fn;
 static QEMUBalloonStatus *balloon_stat_fn;
softmmu/ioport.c +1 -1
index 04e360e79a..cb8adb0b93 100644
@@ -28,9 +28,9 @@
 #include "qemu/osdep.h"
 #include "cpu.h"
 #include "exec/ioport.h"
-#include "trace-root.h"
 #include "exec/memory.h"
 #include "exec/address-spaces.h"
+#include "trace.h"
 
 typedef struct MemoryRegionPortioList {
     MemoryRegion mr;
softmmu/memory.c +1 -1
index af25987518..d030eb6f7c 100644
@@ -24,7 +24,7 @@
 #include "qemu/main-loop.h"
 #include "qemu/qemu-print.h"
 #include "qom/object.h"
-#include "trace-root.h"
+#include "trace.h"
 
 #include "exec/memory-internal.h"
 #include "exec/ram_addr.h"
softmmu/vl.c +1 -1
index 4eb9d1f7fd..f7b103467c 100644
@@ -90,7 +90,7 @@
 
 #include "disas/disas.h"
 
-#include "trace-root.h"
+#include "trace.h"
 #include "trace/control.h"
 #include "qemu/plugin.h"
 #include "qemu/queue.h"
softmmu/trace-events new file +28 -0
new file mode 100644
index 0000000000..b80ca042e1
@@ -0,0 +1,28 @@
+# See docs/devel/tracing.txt for syntax documentation.
+
+# balloon.c
+# Since requests are raised via monitor, not many tracepoints are needed.
+balloon_event(void *opaque, unsigned long addr) "opaque %p addr %lu"
+
+# ioport.c
+cpu_in(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
+cpu_out(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
+
+# memory.c
+memory_region_ops_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ops_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_subpage_read(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_subpage_write(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ram_device_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+memory_region_ram_device_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
+flatview_new(void *view, void *root) "%p (root %p)"
+flatview_destroy(void *view, void *root) "%p (root %p)"
+flatview_destroy_rcu(void *view, void *root) "%p (root %p)"
+
+# vl.c
+vm_state_notify(int running, int reason, const char *reason_str) "running %d reason %d (%s)"
+load_file(const char *name, const char *path) "name %s location %s"
+runstate_set(int current_state, const char *current_state_str, int new_state, const char *new_state_str) "current_run_state %d (%s) new_state %d (%s)"
+system_wakeup_request(int reason) "reason=%d"
+qemu_system_shutdown_request(int reason) "reason=%d"
+qemu_system_powerdown_request(void) ""
trace-events +0 -27
index 42107ebc69..5882c2d5fc 100644
@@ -25,22 +25,6 @@
 #
 # The <format-string> should be a sprintf()-compatible format string.
 
-# ioport.c
-cpu_in(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
-cpu_out(unsigned int addr, char size, unsigned int val) "addr 0x%x(%c) value %u"
-
-# balloon.c
-# Since requests are raised via monitor, not many tracepoints are needed.
-balloon_event(void *opaque, unsigned long addr) "opaque %p addr %lu"
-
-# vl.c
-vm_state_notify(int running, int reason, const char *reason_str) "running %d reason %d (%s)"
-load_file(const char *name, const char *path) "name %s location %s"
-runstate_set(int current_state, const char *current_state_str, int new_state, const char *new_state_str) "current_run_state %d (%s) new_state %d (%s)"
-system_wakeup_request(int reason) "reason=%d"
-qemu_system_shutdown_request(int reason) "reason=%d"
-qemu_system_powerdown_request(void) ""
-
 # dma-helpers.c
 dma_blk_io(void *dbs, void *bs, int64_t offset, bool to_dev) "dbs=%p bs=%p offset=%" PRId64 " to_dev=%d"
 dma_aio_cancel(void *dbs) "dbs=%p"
@@ -55,17 +39,6 @@ ram_block_discard_range(const char *rbname, void *hva, size_t length, bool need_
 memory_notdirty_write_access(uint64_t vaddr, uint64_t ram_addr, unsigned size) "0x%" PRIx64 " ram_addr 0x%" PRIx64 " size %u"
 memory_notdirty_set_dirty(uint64_t vaddr) "0x%" PRIx64
 
-# memory.c
-memory_region_ops_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ops_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_subpage_read(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_subpage_write(int cpu_index, void *mr, uint64_t offset, uint64_t value, unsigned size) "cpu %d mr %p offset 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ram_device_read(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-memory_region_ram_device_write(int cpu_index, void *mr, uint64_t addr, uint64_t value, unsigned size) "cpu %d mr %p addr 0x%"PRIx64" value 0x%"PRIx64" size %u"
-flatview_new(void *view, void *root) "%p (root %p)"
-flatview_destroy(void *view, void *root) "%p (root %p)"
-flatview_destroy_rcu(void *view, void *root) "%p (root %p)"
-
 # gdbstub.c
 gdbstub_op_start(const char *device) "Starting gdbstub using device %s"
 gdbstub_op_exiting(uint8_t code) "notifying exit with code=0x%02x"
#9 lore raw
In reply to Philippe Mathieu-Daudé
Quoted 6 lines · Philippe Mathieu-Daudé

Commit c7f419f584 moved softmmu-only files out of the root directory, but forgot to move the trace events, which should no longer be generated to "trace-root.h". Fix that by adding softmmu/trace-events.

Quoted 10 lines
---
 Makefile.objs        |  1 +
 softmmu/balloon.c    |  2 +-
 softmmu/ioport.c     |  2 +-
 softmmu/memory.c     |  2 +-
 softmmu/vl.c         |  2 +-
 softmmu/trace-events | 28 ++++++++++++++++++++++++++++
 trace-events         | 27 ---------------------------
 7 files changed, 33 insertions(+), 31 deletions(-)
 create mode 100644 softmmu/trace-events

Thanks, applied to my tracing-next tree:
https://github.com/stefanha/qemu/commits/tracing-next

Stefan