All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/5] qom: prepare a TypeBucket for same-name target variants
@ 2026-11-05 19:03 Yonggang Luo
  2026-11-05 19:03 ` [PATCH 1/5] qom: store registration targets on TypeImpl Yonggang Luo
                   ` (5 more replies)
  0 siblings, 6 replies; 14+ messages in thread
From: Yonggang Luo @ 2026-11-05 19:03 UTC (permalink / raw)
  To: qemu-devel
  Cc: Pierrick Bouvier, Philippe Mathieu-Daudé, Paolo Bonzini,
	Daniel P. Berrangé, Philippe Mathieu-Daude

This series prepares QOM to hold more than one TypeImpl under the same name, one
per target, so a multi-target binary can register same-name types without
renaming them. Nothing uses it yet.

type_table maps each name to a TypeBucket, which holds the variants and the
union of their QEMU_ARCH_* masks. Registration still aborts when masks overlap,
and a name lookup returns the one variant left for the selected target.
type_register_targets() registers a variant for a target mask.
type_register_static() is unchanged, so binaries keep one TypeImpl per name.

The change stays in qom and target-info and does not conflict with the virt QOM
name or is_available series.

Daniel asked what a TypeBucket means. This is that prototype, based on the
bucket idea from Pierrick.

Daniel: what a TypeBucket means:
Link: https://lore.kernel.org/qemu-devel/auyP09mbwuefulBL@redhat.com/

Pierrick: register types per target bucket:
Link: https://lore.kernel.org/qemu-devel/d754acaa-0811-4185-a78f-1a352ec8bbab@oss.qualcomm.com/

Pierrick: the bucket work can proceed in parallel:
Link: https://lore.kernel.org/qemu-devel/CAE2XoE-iOCdGxPtg7MqydmahpnOTFM_15dR0eJKGMrQKxrgeQQ@mail.gmail.com/

Yonggang Luo (5):
  qom: store registration targets on TypeImpl
  target-info: add target_mask_selected()
  qom: add target_mask_filter()
  qom: filter type lookup with TypeBucket
  qom: add type_register_targets()

 include/qemu/target-info-init.h |  15 ++-
 include/qemu/target-info.h      |   9 ++
 include/qom/object.h            |  12 +++
 qom/object.c                    | 168 ++++++++++++++++++++++++++------
 stubs/meson.build               |   1 +
 stubs/target-mask-selected.c    |  13 +++
 target-info-def.c               |   3 +
 target-info-qom.c               |  10 ++
 8 files changed, 197 insertions(+), 34 deletions(-)
 create mode 100644 stubs/target-mask-selected.c

-- 
2.55.0.windows.3



^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2026-11-12 13:54 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-05 19:03 [PATCH 0/5] qom: prepare a TypeBucket for same-name target variants Yonggang Luo
2026-11-05 19:03 ` [PATCH 1/5] qom: store registration targets on TypeImpl Yonggang Luo
2026-11-05 19:03 ` [PATCH 2/5] target-info: add target_mask_selected() Yonggang Luo
2026-11-06 15:45   ` Daniel P. Berrangé
2026-11-06 16:17     ` Yonggang Luo
2026-11-06 17:44   ` Pierrick Bouvier
2026-11-06 17:46     ` Yonggang Luo
2026-11-06 17:47       ` Pierrick Bouvier
2026-11-06 19:52         ` Yonggang Luo
2026-11-06 20:19           ` Pierrick Bouvier
2026-11-05 19:03 ` [PATCH 3/5] qom: add target_mask_filter() Yonggang Luo
2026-11-05 19:03 ` [PATCH 4/5] qom: filter type lookup with TypeBucket Yonggang Luo
2026-11-05 19:03 ` [PATCH 5/5] qom: add type_register_targets() Yonggang Luo
2026-11-12 13:53 ` [PATCH 0/5] qom: prepare a TypeBucket for same-name target variants Daniel P. Berrangé

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.