[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 33/48] accel: build tcg modular
From: |
Paolo Bonzini |
Subject: |
[PULL 33/48] accel: build tcg modular |
Date: |
Thu, 8 Jul 2021 17:17:33 +0200 |
From: Gerd Hoffmann <kraxel@redhat.com>
Build tcg accel ops as module.
Which is only a small fraction of tcg.
Also only x86 for now.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Jose R. Ziviani <jziviani@suse.de>
Message-Id: <20210624103836.2382472-30-kraxel@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
accel/tcg/meson.build | 5 ++++-
meson.build | 14 +++++++++++++-
2 files changed, 17 insertions(+), 2 deletions(-)
diff --git a/accel/tcg/meson.build b/accel/tcg/meson.build
index 1236ac7b91..0ae9180282 100644
--- a/accel/tcg/meson.build
+++ b/accel/tcg/meson.build
@@ -15,8 +15,11 @@ specific_ss.add_all(when: 'CONFIG_TCG', if_true: tcg_ss)
specific_ss.add(when: ['CONFIG_SOFTMMU', 'CONFIG_TCG'], if_true: files(
'cputlb.c',
+))
+
+tcg_module_ss.add(when: ['CONFIG_SOFTMMU', 'CONFIG_TCG'], if_true: files(
'tcg-accel-ops.c',
'tcg-accel-ops-mttcg.c',
'tcg-accel-ops-icount.c',
- 'tcg-accel-ops-rr.c'
+ 'tcg-accel-ops-rr.c',
))
diff --git a/meson.build b/meson.build
index c943e44975..d9aa2d7820 100644
--- a/meson.build
+++ b/meson.build
@@ -92,6 +92,8 @@ if cpu in ['x86', 'x86_64']
}
endif
+modular_tcg = ['i386-softmmu', 'x86_64-softmmu']
+
edk2_targets = [ 'arm-softmmu', 'aarch64-softmmu', 'i386-softmmu',
'x86_64-softmmu' ]
install_edk2_blobs = false
if get_option('install_blobs')
@@ -1531,6 +1533,11 @@ foreach target : target_dirs
elif sym == 'CONFIG_XEN' and have_xen_pci_passthrough
config_target += { 'CONFIG_XEN_PCI_PASSTHROUGH': 'y' }
endif
+ if target in modular_tcg
+ config_target += { 'CONFIG_TCG_MODULAR': 'y' }
+ else
+ config_target += { 'CONFIG_TCG_BUILTIN': 'y' }
+ endif
accel_kconfig += [ sym + '=y' ]
endif
endforeach
@@ -2002,6 +2009,7 @@ util_ss = ss.source_set()
# accel modules
qtest_module_ss = ss.source_set()
+tcg_module_ss = ss.source_set()
modules = {}
target_modules = {}
@@ -2242,7 +2250,11 @@ subdir('tests/qtest/libqos')
subdir('tests/qtest/fuzz')
# accel modules
-target_modules += { 'accel' : { 'qtest': qtest_module_ss }}
+tcg_real_module_ss = ss.source_set()
+tcg_real_module_ss.add_all(when: 'CONFIG_TCG_MODULAR', if_true: tcg_module_ss)
+specific_ss.add_all(when: 'CONFIG_TCG_BUILTIN', if_true: tcg_module_ss)
+target_modules += { 'accel' : { 'qtest': qtest_module_ss,
+ 'tcg': tcg_real_module_ss }}
########################
# Library dependencies #
--
2.31.1
- [PULL 25/48] modules: add documentation for module sourcesets, (continued)
- [PULL 25/48] modules: add documentation for module sourcesets, Paolo Bonzini, 2021/07/08
- [PULL 21/48] modules: add tracepoints, Paolo Bonzini, 2021/07/08
- [PULL 22/48] modules: check arch and block load on mismatch, Paolo Bonzini, 2021/07/08
- [PULL 29/48] accel: autoload modules, Paolo Bonzini, 2021/07/08
- [PULL 28/48] modules: hook up modules.h to docs build, Paolo Bonzini, 2021/07/08
- [PULL 30/48] accel: add qtest module annotations, Paolo Bonzini, 2021/07/08
- [PULL 32/48] accel: add tcg module annotations, Paolo Bonzini, 2021/07/08
- [PULL 35/48] usb: drop usb_host_dev_is_scsi_storage hook, Paolo Bonzini, 2021/07/08
- [PULL 37/48] usb: build usb-host as module, Paolo Bonzini, 2021/07/08
- [PULL 34/48] monitor: allow register hmp commands, Paolo Bonzini, 2021/07/08
- [PULL 33/48] accel: build tcg modular,
Paolo Bonzini <=
- [PULL 26/48] modules: add module_obj() note to QOM docs, Paolo Bonzini, 2021/07/08
- [PULL 39/48] target/i386: Added MSRPM and IOPM size check, Paolo Bonzini, 2021/07/08
- [PULL 40/48] target/i386: Added DR6 and DR7 consistency checks, Paolo Bonzini, 2021/07/08
- [PULL 36/48] monitor/usb: register 'info usbhost' dynamically, Paolo Bonzini, 2021/07/08
- [PULL 38/48] monitor/tcg: move tcg hmp commands to accel/tcg, register them dynamically, Paolo Bonzini, 2021/07/08
- [PULL 45/48] hw/arm: add dependency on OR_IRQ for XLNX_VERSAL, Paolo Bonzini, 2021/07/08
- [PULL 48/48] configure: allow the selection of alternate config in the build, Paolo Bonzini, 2021/07/08
- [PULL 31/48] accel: build qtest modular, Paolo Bonzini, 2021/07/08
- [PULL 41/48] target/i386: fix exceptions for MOV to DR, Paolo Bonzini, 2021/07/08
- [PULL 43/48] meson: switch function tests from compilation to linking, Paolo Bonzini, 2021/07/08