qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 00/27] Replace TARGET_TB_PCREL with CF_PCREL


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH v2 00/27] Replace TARGET_TB_PCREL with CF_PCREL
Date: Tue, 21 Feb 2023 23:39:11 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.8.0

On 21/2/23 23:17, Anton Johansson wrote:
This patchset entirely replaces the macro TARGET_TB_PCREL with
a field in TranslationBlock.cflags called CF_PCREL, and is a
first step towards removing target-specific assumptions from
non-target/ directories.

The grand goal is to allow for heterogeneous QEMU binaries
consisting of multiple frontends.

RFC: https://lists.nongnu.org/archive/html/qemu-devel/2022-12/msg04518.html

Changes in v2:
   * Setting of CF_PCREL (previously patch 3) was split in two and moved
     up front (to patch 2 and 3);

   * Replacing of TARGET_TB_PCREL (previously patch 2) was split into
     four patches (patches [4,7]), one for each affected submodule;

   * Removal of TARGET_TB_PCREL (previously patch 3) was moved into
     separate patches, one for each submodule (patches [8,10]);

   * Patch 11 was introduced in response to feedback, and removes
     CF_PCREL checks in functions in tb-jmp-cache.h, these functions were
     always called in a context where CF_PCREL was already being checked.
     These tb-jmp-cache.h functions were then removed in favour of manual
     inlining;

   * Patches [12,26] replaces calls to tb_pc() with a member access
     tb->pc, the motivation being that tb_pc() was (almost) always called
     in a context where CF_PCREL was already being checked;

   * Finally patch 27 removes tb_pc() which is no longer used.

Since changes are spread across multiple submodules we ended up with a
lot of patches. Patches [11,27] still need review.

Anton Johansson (27):
   include/exec: Introduce `CF_PCREL`
   target/i386: set `CF_PCREL` in `x86_cpu_realizefn`
   target/arm: set `CF_PCREL` in `arm_cpu_realizefn`
   accel/tcg: Replace `TARGET_TB_PCREL` with `CF_PCREL`
   include/exec: Replace `TARGET_TB_PCREL` with `CF_PCREL`
   target/arm: Replace `TARGET_TB_PCREL` with `CF_PCREL`
   target/i386: Replace `TARGET_TB_PCREL` with `CF_PCREL`
   include/exec: Remove `TARGET_TB_PCREL` define
   target/arm: Remove `TARGET_TB_PCREL` define
   target/i386: Remove `TARGET_TB_PCREL` define
   accel/tcg: Move jmp-cache `CF_PCREL` checks to caller
   accel/tcg: Replace `tb_pc()` with `tb->pc`
   target/tricore: Replace `tb_pc()` with `tb->pc`
   target/sparc: Replace `tb_pc()` with `tb->pc`
   target/sh4: Replace `tb_pc()` with `tb->pc`
   target/rx: Replace `tb_pc()` with `tb->pc`
   target/riscv: Replace `tb_pc()` with `tb->pc`
   target/openrisc: Replace `tb_pc()` with `tb->pc`
   target/mips: Replace `tb_pc()` with `tb->pc`
   target/microblaze: Replace `tb_pc()` with `tb->pc`
   target/loongarch: Replace `tb_pc()` with `tb->pc`
   target/i386: Replace `tb_pc()` with `tb->pc`
   target/hppa: Replace `tb_pc()` with `tb->pc`
   target/hexagon: Replace `tb_pc()` with `tb->pc`
   target/avr: Replace `tb_pc()` with `tb->pc`
   target/arm: Replace `tb_pc()` with `tb->pc`
   include/exec: Remove `tb_pc()`

Series:
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]