On 5/7/25 12:55 AM, Markus Armbruster wrote:
[...]
- First, it's already broken because we rely on ifdef that won't be
there in Rust or Go.
I don't think it's broken. QAPI 'if' translates straightforwardly to C
#if, but that doesn't mean it cannot be translated to conditional
compilation / m
On 5/7/25 4:32 AM, Daniel P. Berrangé wrote:
On Wed, May 07, 2025 at 09:55:13AM +0200, Markus Armbruster wrote:
Pierrick Bouvier writes:
[...]
I don't think we should think too much ahead for languages other than C,
for one, two, and even three reasons :)
I agree that thinking ahea
On 4/29/25 10:40 PM, Thomas Huth wrote:
On 29/04/2025 21.48, Pierrick Bouvier wrote:
...
I'm not keen to have a default target set, but it's a personal opinion based
on fear of "implicit smart choice hurts", so I'll be happy to change my mind
with a good argument fo
On 4/29/25 12:57 PM, Pierrick Bouvier wrote:
On 4/29/25 2:35 AM, Philippe Mathieu-Daudé wrote:
If a distro wants to name a binary 'qemu-kvm' it can drop the
-target option and hard-wire its target_info() to a distro-specific
TargetInfo implementation, or &target_info_x86_64_sys
On 4/29/25 2:35 AM, Philippe Mathieu-Daudé wrote:
If a distro wants to name a binary 'qemu-kvm' it can drop the
-target option and hard-wire its target_info() to a distro-specific
TargetInfo implementation, or &target_info_x86_64_system.
Having updated my Debian stable to next stable (trixie)
On 4/29/25 2:20 AM, Thomas Huth wrote:
On 29/04/2025 10.23, Markus Armbruster wrote:
...
I don't wish to derail this thread, but we've been dancing around the
question of how to best fix the target for some time. I think we should
talk about it for real.
Sure, and no problem about that, that
On 4/29/25 1:37 AM, Daniel P. Berrangé wrote:
On Tue, Apr 29, 2025 at 09:43:24AM +0200, Markus Armbruster wrote:
Pierrick Bouvier writes:
After looking at the introspection code, I don't see any major blocker.
We need to keep some of existing "if", as they are based on c
On 4/29/25 12:43 AM, Markus Armbruster wrote:
Pierrick Bouvier writes:
On 4/25/25 11:21 PM, Markus Armbruster wrote:
Trouble is some uses of the second kind are in QAPI conditionals. I can
see three options:
(1) Drop these conditionals.
(2) Replace them by run-time checks.
(3) Have
On 4/28/25 3:25 AM, Peter Krempa wrote:
On Fri, Apr 25, 2025 at 14:07:34 -0700, Pierrick Bouvier wrote:
On 4/25/25 08:38, Markus Armbruster wrote:
Pierrick Bouvier writes:
Note: This RFC was posted to trigger a discussion around this topic, and it's
not expected to merge it as
On 4/28/25 4:07 AM, Markus Armbruster wrote:
Peter Krempa writes:
So what should libvirt do once multiple targets are supported?
How do we query CPUs for each of the supported targets?
It's kind of a similar question we have to solve now with QEMU code.
What happens when a symbol is duplic
On 4/25/25 11:21 PM, Markus Armbruster wrote:
Trouble is some uses of the second kind are in QAPI conditionals. I can
see three options:
(1) Drop these conditionals.
(2) Replace them by run-time checks.
(3) Have target-specific QAPI-generated code for multiple targets
coexist in the sing
On 4/25/25 14:07, Pierrick Bouvier wrote:
QAPI/QMP introspection has all commands and events, and all types
reachable from them. query-qmp-schema returns an array, where each
array element describes one command, event, or type. When a command,
event, or type is conditional in the schema, the
On 4/25/25 08:38, Markus Armbruster wrote:
Pierrick Bouvier writes:
Note: This RFC was posted to trigger a discussion around this topic, and it's
not expected to merge it as it is.
Context
===
Linaro is working towards heterogeneous emulation, mixing several architectures
in a s
On 6/3/24 05:18, Daniel P. Berrangé wrote:
On Fri, May 31, 2024 at 06:47:45AM +0200, Thomas Huth wrote:
On 30/05/2024 09.45, Philippe Mathieu-Daudé wrote:
We are trying to unify all qemu-system-FOO to a single binary.
In order to do that we need to remove QAPI target specific code.
@dump-skeys
On 10/23/24 01:57, Alex Bennée wrote:
Pierrick Bouvier writes:
On 10/22/24 03:56, Alex Bennée wrote:
From: Pierrick Bouvier
Tried to unify this meson.build with tests/tcg/plugins/meson.build
but
the resulting modules are not output in the right directory.
Originally proposed by Anton
On 10/22/24 03:56, Alex Bennée wrote:
From: Pierrick Bouvier
Tried to unify this meson.build with tests/tcg/plugins/meson.build but
the resulting modules are not output in the right directory.
Originally proposed by Anton Kochkov, thank you!
Solves: https://gitlab.com/qemu-project/qemu
sys.exit(f'{e}. Output:\n\n{e.output}')
+
+found_gdb_archs = re.search(r'Valid arguments are (.*)', gdb_out)
-m = re.search(r"Valid arguments are (.*)",
- gdb_out.decode("utf-8"))
+targets = set()
+if found_gdb_archs:
+gdb_archs = found_gdb_archs.group(1).split(", ")
+mapped_gdb_archs = [arch for arch in gdb_archs if arch in MAP]
-valid_arches = set()
+targets = {target for arch in mapped_gdb_archs for target in MAP[arch]}
-if m.group(1):
-for arch in m.group(1).split(", "):
-if arch in mappings:
-mapping = mappings[arch]
-if isinstance(mapping, str):
-valid_arches.add(mapping)
-else:
-for entry in mapping:
-valid_arches.add(entry)
+# QEMU targets
+return targets
-return valid_arches
def main() -> None:
parser = argparse.ArgumentParser(description='Probe GDB Architectures')
Reviewed-by: Pierrick Bouvier
On 10/22/24 17:16, Ilya Leoshkevich wrote:
On Tue, 2024-10-22 at 13:36 -0700, Pierrick Bouvier wrote:
On 10/22/24 03:56, Alex Bennée wrote:
From: Ilya Leoshkevich
commit f025692c992c ("accel/tcg: Clear PAGE_WRITE before
translation")
fixed cross-modifying code handling, but did
On 10/22/24 03:56, Alex Bennée wrote:
Now gdbstub has gained the ability to extend its command tables we can
allow it to trigger plugin callbacks. This is probably most useful for
QEMU developers debugging plugins themselves but might be useful for
other stuff.
Trigger the callback by sending:
/MAINTAINERS
@@ -3702,6 +3702,7 @@ F: include/tcg/
TCG Plugins
M: Alex Bennée
+T: git https://gitlab.com/stsquad/qemu plugins/next
R: Alexandre Iooss
R: Mahmoud Mandour
R: Pierrick Bouvier
Reviewed-by: Pierrick Bouvier
any big-endian
+#l ibc available the best we can do is a basic Hello World.
+
s/l ibc/ libc/
+AARCH64BE_SRC=$(SRC_PATH)/tests/tcg/aarch64_be
+VPATH += $(AARCH64BE_SRC)
+
+AARCH64BE_TEST_SRCS=$(notdir $(wildcard $(AARCH64BE_SRC)/*.c))
+AARCH64BE_TESTS=$(AARCH64BE_TEST_SRCS:.c=)
+#MULTIARCH_TESTS = $(MULTIARCH_SRCS:.c=)
+
+# We need to specify big-endian cflags
+CFLAGS +=-mbig-endian -ffreestanding
+LDFLAGS +=-nostdlib
+
+TESTS += $(AARCH64BE_TESTS)
Reviewed-by: Pierrick Bouvier
64-mte.xml
TARGET_HAS_BFLT=y
CONFIG_SEMIHOSTING=y
CONFIG_ARM_COMPATIBLE_SEMIHOSTING=y
Reviewed-by: Pierrick Bouvier
AGS+=-pthread
+
test-x86_64: LDFLAGS+=-lm -lc
test-x86_64: test-i386.c test-i386.h test-i386-shift.h test-i386-muldiv.h
$(CC) $(CFLAGS) $< -o $@ $(LDFLAGS)
With this change,
Reviewed-by: Pierrick Bouvier
ecture'] == 'aarch64' or
ansible_facts['architecture'] == 'x86_64'
- name: Install armhf cross-compile packages to build QEMU on AArch64 Ubuntu 22.04
package:
Reviewed-by: Pierrick Bouvier
Do not fetch from the registry.'
@echo 'EXECUTABLE=Include executable in image.'
@echo 'EXTRA_FILES=" [... ]"'
@echo ' Include extra files in image.'
Reviewed-by: Pierrick Bouvier
configure the user (if env is defined)
ARG USER
Reviewed-by: Pierrick Bouvier
ERS: mention my testing/next tree
MAINTAINERS: mention my gdbstub/next tree
config/targets: update aarch64_be-linux-user gdb XML list
tests/tcg: enable basic testing for aarch64_be-linux-user
Ilya Leoshkevich (1):
tests/docker: Fix microblaze atomics
Pierrick Bouvier (3):
meson: hi
sys.exit(1)
+
+# Parse plugin output
+preads, pwrites, seen_all = parse_plugin_output(args.plugin_output, start,
end)
+
+if not seen_all:
+print("Fail: didn't instrument all accesses to test_data.")
+sys.exit(1)
+
+# Compare and report
+if preads == exp_reads and pwrites == exp_writes:
+sys.exit(0)
+else:
+print("Fail: The memory reads and writes count does not match.")
+print(f"Expected Reads: {exp_reads}, Actual Reads: {preads}")
+print(f"Expected Writes: {exp_writes}, Actual Writes: {pwrites}")
+sys.exit(1)
+
+if __name__ == "__main__":
+main()
diff --git a/tests/tcg/s390x/Makefile.softmmu-target
b/tests/tcg/s390x/Makefile.softmmu-target
index be242ba8f1..3227903348 100644
--- a/tests/tcg/s390x/Makefile.softmmu-target
+++ b/tests/tcg/s390x/Makefile.softmmu-target
@@ -47,3 +47,8 @@ $(MULTIARCH_TESTS): $(S390X_MULTIARCH_RUNTIME_OBJS)
$(MULTIARCH_TESTS): LDFLAGS += $(S390X_MULTIARCH_RUNTIME_OBJS)
$(MULTIARCH_TESTS): CFLAGS += $(MINILIB_INC)
memory: CFLAGS += -DCHECK_UNALIGNED=0
+
+# s390x clears the BSS section so we need to account for that
+run-plugin-memory-with-libmem.so: \
+
CHECK_PLUGIN_OUTPUT_COMMAND=$(MULTIARCH_SYSTEM_SRC)/validate-memory-counts.py \
+ --bss-cleared $@.out
Reviewed-by: Pierrick Bouvier
eadline_ns_all(QEMU_CLOCK_VIRTUAL,
+ QEMU_TIMER_ATTR_ALL);
}
qemu_clock_notify(QEMU_CLOCK_VIRTUAL);
Reviewed-by: Pierrick Bouvier
return -1;
+}
+
time_handle = qemu_plugin_request_time_control();
g_assert(time_handle);
Reviewed-by: Pierrick Bouvier
ouv...@linaro.org>
Cc: Gustavo Romero
Cc: Pierrick Bouvier
Signed-off-by: Alex Bennée
Message-Id: <20240311153432.1395190-1-alex.ben...@linaro.org>
---
v2
- only need a single call back
- drop need for INSN_WIDTH
- still don't understand the early exits
v3
- move ini
init_ufns[] = {
+init_test_data_u8,
+init_test_data_u16,
+init_test_data_u32,
+#if __SIZEOF_POINTER__ == 8
+init_test_data_u64
+#endif
+};
int main(void)
{
Reviewed-by: Pierrick Bouvier
st_data_s16(int offset, bool neg_first)
return false;
}
}
-ml_printf("done @ %p\n", ptr);
+ml_printf("done %d @ %p\n", i, ptr);
return true;
}
@@ -431,7 +442,7 @@ static bool read_test_data_s32(int offset, bool neg_first)
return false;
}
}
-ml_printf("done @ %p\n", ptr);
+ml_printf("done %d @ %p\n", i, ptr);
return true;
}
Reviewed-by: Pierrick Bouvier
eson_options"
+}
meson_add_machine_file() {
if test "$cross_compile" = "yes"; then
@@ -1048,8 +1051,12 @@ if test "$static" = "yes" ; then
plugins="no"
fi
if test "$plugins" != "no" && test $host_bits -eq 64; then
- plugins=yes
- subdirs="$subdirs contrib/plugins"
+if has_meson_option "-Dtcg_interpreter=true"; then
+plugins="no"
+else
+plugins=yes
+subdirs="$subdirs contrib/plugins"
+fi
fi
cat > $TMPC << EOF
Reviewed-by: Pierrick Bouvier
software analysis
+benefits from having plenty of host memory it seems reasonable to
+encourage users to use 64 bit builds of QEMU for analysis work
+whatever targets they are instrumenting.
System emulator CPUs
diff --git a/configure b/configure
index 40186d865e..14581c1b9a 100755
--- a/configure
+++ b/configure
@@ -516,6 +516,25 @@ case "$cpu" in
;;
esac
+# Now we have our CPU_CFLAGS we can check if we are targeting a 32 or
+# 64 bit host.
+
+check_64bit_host() {
+cat > $TMPC <
Thanks, it should open the door to be able to build plugins with meson.
Reviewed-by: Pierrick Bouvier
ot;] }},{{
ansible_facts[\"distribution\"]|lower }}_{{ ansible_facts[\"distribution_version\"] }} --description '{{
ansible_facts[\"distribution\"] }} {{ ansible_facts[\"distribution_version\"] }} {{ ansible_facts[\"architecture\"] }} ({{
ansible_facts[\"os_family\"] }})'"
Reviewed-by: Pierrick Bouvier
s a separate set of mappings that work with more
recent versions. These can be found in ``tests/lcitool/mappings.yml``.
Reviewed-by: Pierrick Bouvier
4el-softmmu,mips64el-linux-user"))
-generate_dockerfile("debian-mipsel-cross", "debian-11",
+generate_dockerfile("debian-mipsel-cross", "debian-12",
cross="mipsel",
trailer=cross_build("mipsel-linux-gnu-",
"mipsel-softmmu,mipsel-linux-user"))
Reviewed-by: Pierrick Bouvier
uot;aarch64-softmmu,aarch64-linux-user"))
-# migration to bookworm stalled: https://lists.debian.org/debian-arm/2023/09/msg6.html
-generate_dockerfile("debian-armel-cross", "debian-11",
-cross="armv6l",
-trailer=cross_build("arm-linux-gnueabi-",
-
"arm-softmmu,arm-linux-user,armeb-linux-user"))
-
generate_dockerfile("debian-armhf-cross", "debian-12",
cross="armv7l",
trailer=cross_build("arm-linux-gnueabihf-",
Reviewed-by: Pierrick Bouvier
39 matches
Mail list logo