Richard Henderson
b765e427b0
target/tricore: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
f36aaa53c6
target/sparc: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
e7977326cd
target/sh4: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
3479783b39
target/s390x: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
5439d7a68c
target/rx: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
ad1e84f504
target/riscv: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
61bd1d2942
target/ppc: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
3eb2c184bf
target/openrisc: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
fbd5bd4ebc
target/nios2: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
3766855c9b
target/mips: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
52b8d9a630
target/microblaze: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
584fd3422f
target/m68k: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
ab27940f8e
target/loongarch: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
434382e640
target/i386: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
e9cc3aca11
target/hppa: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
9015781416
target/hexagon: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
4060474284
target/cris: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
f06c1ad4c6
target/avr: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
56c6c98df8
target/arm: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
c0cd068f32
target/alpha: Convert to tcg_ops restore_state_to_opc
...
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
8269c01417
accel/tcg: Simplify page_get/alloc_target_data
...
Since the only user, Arm MTE, always requires allocation,
merge the get and alloc functions to always produce a
non-null result. Also assume that the user has already
checked page validity.
Reviewed-by: Alex Bennée <alex.bennee@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Richard Henderson
50d4c8c1d4
accel/tcg: Make page_alloc_target_data allocation constant
...
Use a constant target data allocation size for all pages.
This will be necessary to reduce overhead of page tracking.
Since TARGET_PAGE_DATA_SIZE is now required, we can use this
to omit data tracking for targets that don't require it.
Reviewed-by: Alex Bennée <alex.bennee@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2022-10-26 11:11:28 +10:00
Stefan Hajnoczi
79fc2fb685
Merge tag 'trivial-branch-for-7.2-pull-request' of https://gitlab.com/laurent_vivier/qemu into staging
...
Pull request
# -----BEGIN PGP SIGNATURE-----
#
# iQJGBAABCAAwFiEEzS913cjjpNwuT1Fz8ww4vT8vvjwFAmNXleQSHGxhdXJlbnRA
# dml2aWVyLmV1AAoJEPMMOL0/L748TIsP/1gulTFpYAs3Kao6IZonsuCzrjQrJWqv
# 5SD7cVb7isOWdOSNK3glE4dG54Q38PaS9GHaCvzIndjHxlWddCCUuwiw6p1Wdo70
# fjNfcCOEPoalQbkZvLejhs5n2rlfTvS5JUnLKVD9+ton7hjnTyKGDDYao5mYhtzv
# Kn9NpCD3m+K3orzG2Jj7jR1UAumg4cW4YQEpT8ItDT4Y5UAxjL6TZQ6CE220DQDq
# YwDrHEgDYr/UKlTbIC/JwlKOLr0sh+UB1VV8GZS6e6pU9u5WpDDHlQZpU8W2tLLg
# cG5m8tLG2avFxRMUFrPNZ8Lx2xKO8wL1PtgAO9w7qFK+r0soZvv+Zh4ev/t5zGLf
# ciliItqf97yPYNIc3su75jqdQHed7lmZc3m9LBHg8VXN6rAatt8vWUbG90sAZuTU
# tWBZHvQmG0s2MK4UYqeQ59tc21v9T2+VCiiv/1vjgEUr8tBhXS562jrDt/bNEqKa
# eRzT4h4ffbP6BJRnyakxkFkQ7nd2OdlLNKUAr9Tk6T2fYuarfEdbYx//0950agqD
# AAtdQ/AJm6Pq1Px0/RuMKK5WsL818BoAkfr6n7qXleunytJ1W5hjW9EmFIPZWPTR
# ce/lSFHA0+MCpg6C8zAa4iNBg/Pk0p3GRrTeWyHK1FjV+Gep1QtE/a1vk/qiPzTM
# qZVfPxa8cXXe
# =caiq
# -----END PGP SIGNATURE-----
# gpg: Signature made Tue 25 Oct 2022 03:53:08 EDT
# gpg: using RSA key CD2F75DDC8E3A4DC2E4F5173F30C38BD3F2FBE3C
# gpg: issuer "laurent@vivier.eu "
# gpg: Good signature from "Laurent Vivier <lvivier@redhat.com >" [full]
# gpg: aka "Laurent Vivier <laurent@vivier.eu >" [full]
# gpg: aka "Laurent Vivier (Red Hat) <lvivier@redhat.com >" [full]
# Primary key fingerprint: CD2F 75DD C8E3 A4DC 2E4F 5173 F30C 38BD 3F2F BE3C
* tag 'trivial-branch-for-7.2-pull-request' of https://gitlab.com/laurent_vivier/qemu :
accel/tcg/tcg-accel-ops-rr: fix trivial typo
ui: remove useless typecasts
treewide: Remove the unnecessary space before semicolon
include/hw/scsi/scsi.h: Remove unused scsi_legacy_handle_cmdline() prototype
vmstate-static-checker:remove this redundant return
tests/qtest: vhost-user-test: Fix [-Werror=format-overflow=] build warning
tests/qtest: migration-test: Fix [-Werror=format-overflow=] build warning
Drop useless casts from g_malloc() & friends to pointer
elf2dmp: free memory in failure
hw/core: Tidy up unnecessary casting away of const
.gitignore: add multiple items to .gitignore
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com >
2022-10-25 11:37:17 -04:00
Stefan Hajnoczi
e52d57c8c5
Merge tag 'for-upstream' of https://gitlab.com/bonzini/qemu into staging
...
* target/i386: new decoder bugfix
* target/i386: complete x86-v3 support for TCG
# -----BEGIN PGP SIGNATURE-----
#
# iQFHBAABCAAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmNTlqQUHHBib256aW5p
# QHJlZGhhdC5jb20ACgkQv/vSX3jHroOQNQf430MHbrtN9WKKiXv3684XxmcnoRqg
# PHmaGg2SKp7UB+hI2FMYgCZWOl5s3cGTHtwX8byFCttmE4kI7HJR7IouW6znm57j
# 7QVx2TJXIZgqSYcfYzfLu46yS6pNqJUA+mBv5In3Vqt4ZQT2szefVBg6BzmuF6lT
# HXbu/llc3iVfW4SNLJOABXzKNbPacmmpmLjoporfwOHwHjv4iikuXNUOZ84FFL11
# 2tkdcff282q00IRgHm1lSyiRiqh+kAxzSDanMjOZbphBiE9gNJjLGoV5F2X63e1O
# DQGg4wqBWP68O/r8Fj8tOUMCTW212DwWyv1+d/lQB+wwpJK+P4O14dCW
# =Fd+y
# -----END PGP SIGNATURE-----
# gpg: Signature made Sat 22 Oct 2022 03:07:16 EDT
# gpg: using RSA key F13338574B662389866C7682BFFBD25F78C7AE83
# gpg: issuer "pbonzini@redhat.com "
# gpg: Good signature from "Paolo Bonzini <bonzini@gnu.org >" [full]
# gpg: aka "Paolo Bonzini <pbonzini@redhat.com >" [full]
# Primary key fingerprint: 46F5 9FBD 57D6 12E7 BFD4 E2F7 7E15 100C CD36 69B1
# Subkey fingerprint: F133 3857 4B66 2389 866C 7682 BFFB D25F 78C7 AE83
* tag 'for-upstream' of https://gitlab.com/bonzini/qemu :
target/i386: implement FMA instructions
target/i386: implement F16C instructions
target/i386: introduce function to set rounding mode from FPCW or MXCSR bits
target/i386: decode-new: avoid out-of-bounds access to xmm_regs[-1]
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com >
2022-10-24 14:27:06 -04:00
Bin Meng
c1dadb8462
treewide: Remove the unnecessary space before semicolon
...
%s/return ;/return;
Signed-off-by: Bin Meng <bmeng@tinylab.org >
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Reviewed-by: Christian Schoenebeck <qemu_oss@crudebyte.com >
Message-Id: <20221024072802.457832-1-bmeng@tinylab.org >
Signed-off-by: Laurent Vivier <laurent@vivier.eu >
2022-10-24 13:41:10 +02:00
Markus Armbruster
0a553c12c7
Drop useless casts from g_malloc() & friends to pointer
...
These memory allocation functions return void *, and casting to
another pointer type is useless clutter. Drop these casts.
If you really want another pointer type, consider g_new().
Signed-off-by: Markus Armbruster <armbru@redhat.com >
Reviewed-by: Laurent Vivier <laurent@vivier.eu >
Message-Id: <20220923120025.448759-3-armbru@redhat.com >
Signed-off-by: Laurent Vivier <laurent@vivier.eu >
2022-10-22 23:15:40 +02:00
Paolo Bonzini
2872b0f390
target/i386: implement FMA instructions
...
The only issue with FMA instructions is that there are _a lot_ of them (30
opcodes, each of which comes in up to 4 versions depending on VEX.W and
VEX.L; a total of 96 possibilities). However, they can be implement with
only 6 helpers, two for scalar operations and four for packed operations.
(Scalar versions do not do any merging; they only affect the bottom 32
or 64 bits of the output operand. Therefore, there is no separate XMM
and YMM of the scalar helpers).
First, we can reduce the number of helpers to one third by passing four
operands (one output and three inputs); the reordering of which operands
go to the multiply and which go to the add is done in emit.c.
Second, the different instructions also dispatch to the same softfloat
function, so the flags for float32_muladd and float64_muladd are passed
in the helper as int arguments, with a little extra complication to
handle FMADDSUB and FMSUBADD.
Reviewed-by: Richard Henderson <richard.henderson@linaro.org >
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com >
2022-10-22 09:05:54 +02:00
Paolo Bonzini
cf5ec6641e
target/i386: implement F16C instructions
...
F16C only consists of two instructions, which are a bit peculiar
nevertheless.
First, they access only the low half of an YMM or XMM register for the
packed-half operand; the exact size still depends on the VEX.L flag.
This is similar to the existing avx_movx flag, but not exactly because
avx_movx is hardcoded to affect operand 2. To this end I added a "ph"
format name; it's possible to reuse this approach for the VPMOVSX and
VPMOVZX instructions, though that would also require adding two more
formats for the low-quarter and low-eighth of an operand.
Second, VCVTPS2PH is somewhat weird because it *stores* the result of
the instruction into memory rather than loading it.
Reviewed-by: Richard Henderson <richard.henderson@linaro.org >
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com >
2022-10-20 15:16:18 +02:00
Paolo Bonzini
314d3eff66
target/i386: introduce function to set rounding mode from FPCW or MXCSR bits
...
VROUND, FSTCW and STMXCSR all have to perform the same conversion from
x86 rounding modes to softfloat constants. Since the ISA is consistent
on the meaning of the two-bit rounding modes, extract the common code
into a wrapper for set_float_rounding_mode.
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Reviewed-by: Richard Henderson <richard.henderson@linaro.org >
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com >
2022-10-20 15:16:13 +02:00
Paolo Bonzini
0d4bcac3ca
target/i386: decode-new: avoid out-of-bounds access to xmm_regs[-1]
...
If the destination is a memory register, op->n is -1. Going through
tcg_gen_gvec_dup_imm path is both useless (the value has been stored
by the gen_* function already) and wrong because of the out-of-bounds
access.
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org >
Reviewed-by: Richard Henderson <richard.henderson@linaro.org >
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com >
2022-10-20 15:15:50 +02:00
Richard Henderson
abb80995d7
target/arm: Enable TARGET_TB_PCREL
...
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-10-richard.henderson@linaro.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:28:29 +01:00
Richard Henderson
35dbeb8177
target/arm: Introduce gen_pc_plus_diff for aarch32
...
In preparation for TARGET_TB_PCREL, reduce reliance on absolute values.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-9-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
19f6b76baa
target/arm: Introduce gen_pc_plus_diff for aarch64
...
In preparation for TARGET_TB_PCREL, reduce reliance on absolute values.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-8-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
bb0356170a
target/arm: Change gen_jmp* to work on displacements
...
In preparation for TARGET_TB_PCREL, reduce reliance on absolute values.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-7-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
b4f8d987f6
target/arm: Remove gen_exception_internal_insn pc argument
...
In preparation for TARGET_TB_PCREL, reduce reliance on absolute values.
Since we always pass dc->pc_curr, fold the arithmetic to zero displacement.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-6-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
55086e628f
target/arm: Change gen_exception_insn* to work on displacements
...
In preparation for TARGET_TB_PCREL, reduce reliance on absolute values.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-5-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
c44c8b8b99
target/arm: Change gen_*set_pc_im to gen_*update_pc
...
In preparation for TARGET_TB_PCREL, reduce reliance on
absolute values by passing in pc difference.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-4-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
168122419e
target/arm: Change gen_goto_tb to work on displacements
...
In preparation for TARGET_TB_PCREL, reduce reliance on absolute values.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-3-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
8df8727973
target/arm: Introduce curr_insn_len
...
A simple helper to retrieve the length of the current insn.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221020030641.2066807-2-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:52 +01:00
Richard Henderson
6b72c5424a
target/arm: Use bool consistently for get_phys_addr subroutines
...
The return type of the functions is already bool, but in a few
instances we used an integer type with the return statement.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-13-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
3f5a74c543
target/arm: Split out get_phys_addr_twostage
...
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-12-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
f3639a64f6
target/arm: Use softmmu tlbs for page table walking
...
So far, limit the change to S1_ptw_translate, arm_ldl_ptw, and
arm_ldq_ptw. Use probe_access_full to find the host address,
and if so use a host load. If the probe fails, we've got our
fault info already. On the off chance that page tables are not
in RAM, continue to use the address_space_ld* functions.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-11-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
4e7a2c9860
target/arm: Move be test for regime into S1TranslateResult
...
Hoist this test out of arm_ld[lq]_ptw into S1_ptw_translate.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-10-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
4a35855682
target/arm: Plumb debug into S1Translate
...
Before using softmmu page tables for the ptw, plumb down
a debug parameter so that we can query page table entries
from gdbstub without modifying cpu state.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-9-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
6d2654ffac
target/arm: Split out S1Translate type
...
Consolidate most of the inputs and outputs of S1_ptw_translate
into a single structure. Plumb this through arm_ld*_ptw from
the controlling get_phys_addr_* routine.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Message-id: 20221011031911.2408754-8-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
00b20ee42e
target/arm: Restrict tlb flush from vttbr_write to vmid change
...
Compare only the VMID field when considering whether we need to flush.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Message-id: 20221011031911.2408754-7-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
575a94af3c
target/arm: Move ARMMMUIdx_Stage2 to a real tlb mmu_idx
...
We had been marking this ARM_MMU_IDX_NOTLB, move it to a real tlb.
Flush the tlb when invalidating stage 1+2 translations. Re-use
alle1_tlbmask() for other instances of EL1&0 + Stage2.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Message-id: 20221011031911.2408754-6-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
a1ce3084c5
target/arm: Add ARMMMUIdx_Phys_{S,NS}
...
Not yet used, but add mmu indexes for 1-1 mapping
to physical addresses.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-5-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
937f224559
target/arm: Use probe_access_full for BTI
...
Add a field to TARGET_PAGE_ENTRY_EXTRA to hold the guarded bit.
In is_guarded_page, use probe_access_full instead of just guessing
that the tlb entry is still present. Also handles the FIXME about
executing from device memory.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-4-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00
Richard Henderson
b8967ddf39
target/arm: Use probe_access_full for MTE
...
The CPUTLBEntryFull structure now stores the original pte attributes, as
well as the physical address. Therefore, we no longer need a separate
bit in MemTxAttrs, nor do we need to walk the tree of memory regions.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Message-id: 20221011031911.2408754-3-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2022-10-20 11:27:49 +01:00