Skip to contentSkip to conversation

docs: Deprecate Arm OABI and NWFPE support

PATCH In review Peter Maydell 4 participants 5 messages Apr 13

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 docs: Deprecate Arm OABI and NWFPE support

Linux for 32-bit Arm has had two major ABIs: the original OABI and the more modern EABI. OABI support was marked as obsolete in GCC 4.7 and dropped in GCC 4.8. In the Linux kernel, compatibility handling for OABI (OABI_COMPAT) is not generally enabled by default and is not compatible with building a Thumb2 kernel. Distros dropped OABI support fifteen years or more ago.

NWFPE floating-point emulation handles the ancient FPA11 coprocessor, which is only needed/supported with OABI. Our implementation is old, untested and not thread-safe.

Mark OABI and NWFPE support as deprecated so we can remove it in a future release. Our main motivation here is to be able to drop the 2500+ lines of NWFPE emulation code.

---
This just came up today; it's tempting to squeeze the deprecation notice into 11.0 so we don't have an extra three months before we can delete it, but we could just deprecate in 11.1 instead.

 docs/about/deprecated.rst | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)
docs/about/deprecated.rst +25 -0
index a6d6a71326..10de10dc23 100644
@@ -452,6 +452,31 @@ It was implemented as a no-op instruction in TCG up to QEMU 9.0, but
 only with ``-cpu max`` (which does not guarantee migration compatibility
 across versions).
 
+linux-user mode CPUs
+--------------------
+
+OABI and NWFPE support for Arm CPUs
+'''''''''''''''''''''''''''''''''''
+
+Linux for 32-bit Arm has had two major ABIs: the original OABI and the
+more modern EABI. OABI support was marked as obsolete in GCC 4.7 and
+dropped in GCC 4.8 (released in 2013). In the Linux kernel,
+compatibility handling for OABI (OABI_COMPAT) is not generally enabled
+by default and is not compatible with building a Thumb2
+kernel. Distros dropped OABI support fifteen years or more ago.
+
+The original floating-point coprocessor for 32-bit Arm was the
+FPA11. This was not present in many CPUs but did get baked into the
+OABI for how to pass floating point arguments, and so the Linux kernel
+has support for emulating it via the config option FPE_NWFPE; QEMU
+follows that. FPA11 support was also removed from GCC in GCC 4.8.
+
+QEMU's NWFPE code is old and untested and not thread-safe; the OABI
+ABI is long-obsolete. We are therefore deprecating both OABI support
+and NWFPE emulation, and they will be removed in a future QEMU
+release.
+
+
 Backwards compatibility
 -----------------------
 
Signature · 1 line
2.43.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 15 lines · Peter Maydell

Linux for 32-bit Arm has had two major ABIs: the original OABI and the more modern EABI. OABI support was marked as obsolete in GCC 4.7 and dropped in GCC 4.8. In the Linux kernel, compatibility handling for OABI (OABI_COMPAT) is not generally enabled by default and is not compatible with building a Thumb2 kernel. Distros dropped OABI support fifteen years or more ago.

NWFPE floating-point emulation handles the ancient FPA11 coprocessor, which is only needed/supported with OABI. Our implementation is old, untested and not thread-safe.

Quoted 5 lines

Mark OABI and NWFPE support as deprecated so we can remove it in a future release. Our main motivation here is to be able to drop the 2500+ lines of NWFPE emulation code.

Hi,

Especially that this has ISA emulation code inside of linux-user (!)

If this is (unlikely) to continue to exist, it ought to be moved to common code for system emulation...

Quoted 50 lines

---
This just came up today; it's tempting to squeeze the deprecation notice into 11.0 so we don't have an extra three months before we can delete it, but we could just deprecate in 11.1 instead.

docs/about/deprecated.rst | 25 +++++++++++++++++++++++++

1 file changed, 25 insertions(+)
docs/about/deprecated.rst +0 -0
index a6d6a71326..10de10dc23 100644
@@ -452,6 +452,31 @@ It was implemented as a no-op instruction in TCG up to QEMU 9.0, but

only with ``-cpu max`` (which does not guarantee migration compatibility across versions).

docs/about/deprecated.rst +25 -0
+linux-user mode CPUs
+--------------------
+
+OABI and NWFPE support for Arm CPUs
+'''''''''''''''''''''''''''''''''''
+
+Linux for 32-bit Arm has had two major ABIs: the original OABI and the
+more modern EABI. OABI support was marked as obsolete in GCC 4.7 and
+dropped in GCC 4.8 (released in 2013). In the Linux kernel,
+compatibility handling for OABI (OABI_COMPAT) is not generally enabled
+by default and is not compatible with building a Thumb2
+kernel. Distros dropped OABI support fifteen years or more ago.
+
+The original floating-point coprocessor for 32-bit Arm was the
+FPA11. This was not present in many CPUs but did get baked into the
+OABI for how to pass floating point arguments, and so the Linux kernel
+has support for emulating it via the config option FPE_NWFPE; QEMU
+follows that. FPA11 support was also removed from GCC in GCC 4.8.
+
+QEMU's NWFPE code is old and untested and not thread-safe; the OABI
+ABI is long-obsolete. We are therefore deprecating both OABI support
+and NWFPE emulation, and they will be removed in a future QEMU
+release.
+
+

Backwards compatibility
-----------------------

Signature · 1 line
2.43.0
#2 lore raw
Quoted 9 lines · Mohamed Mediouni
Quoted 4 lines · Peter Maydell

NWFPE floating-point emulation handles the ancient FPA11 coprocessor, which is only needed/supported with OABI. Our implementation is old, untested and not thread-safe.

Especially that this has ISA emulation code inside of linux-user (!)

If this is (unlikely) to continue to exist, it ought to be moved to common code for system emulation...

No, because no CPU we emulate has an FPA11. What we're emulating here is the Linux kernel's emulation support. You can look at it as a set of syscalls with a very funny ABI and very specific behaviour :-)

-- PMM

Reviewed-by on v1 1/1
#3 lore raw
In reply to Peter Maydell
Quoted 11 lines · Peter Maydell

Linux for 32-bit Arm has had two major ABIs: the original OABI and the more modern EABI. OABI support was marked as obsolete in GCC 4.7 and dropped in GCC 4.8. In the Linux kernel, compatibility handling for OABI (OABI_COMPAT) is not generally enabled by default and is not compatible with building a Thumb2 kernel. Distros dropped OABI support fifteen years or more ago.

NWFPE floating-point emulation handles the ancient FPA11 coprocessor, which is only needed/supported with OABI. Our implementation is old, untested and not thread-safe.

Quoted 5 lines

Mark OABI and NWFPE support as deprecated so we can remove it in a future release. Our main motivation here is to be able to drop the 2500+ lines of NWFPE emulation code.

Quoted 4 lines

---
This just came up today; it's tempting to squeeze the deprecation notice into 11.0 so we don't have an extra three months before we can delete it, but we could just deprecate in 11.1 instead.

Seems reasonable to me.

Quoted 39 lines
 docs/about/deprecated.rst | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)
docs/about/deprecated.rst +25 -0
index a6d6a71326..10de10dc23 100644
@@ -452,6 +452,31 @@ It was implemented as a no-op instruction in TCG up to QEMU 9.0, but
 only with ``-cpu max`` (which does not guarantee migration compatibility
 across versions).
 
+linux-user mode CPUs
+--------------------
+
+OABI and NWFPE support for Arm CPUs
+'''''''''''''''''''''''''''''''''''
+
+Linux for 32-bit Arm has had two major ABIs: the original OABI and the
+more modern EABI. OABI support was marked as obsolete in GCC 4.7 and
+dropped in GCC 4.8 (released in 2013). In the Linux kernel,
+compatibility handling for OABI (OABI_COMPAT) is not generally enabled
+by default and is not compatible with building a Thumb2
+kernel. Distros dropped OABI support fifteen years or more ago.
+
+The original floating-point coprocessor for 32-bit Arm was the
+FPA11. This was not present in many CPUs but did get baked into the
+OABI for how to pass floating point arguments, and so the Linux kernel
+has support for emulating it via the config option FPE_NWFPE; QEMU
+follows that. FPA11 support was also removed from GCC in GCC 4.8.
+
+QEMU's NWFPE code is old and untested and not thread-safe; the OABI
+ABI is long-obsolete. We are therefore deprecating both OABI support
+and NWFPE emulation, and they will be removed in a future QEMU
+release.
+
+
 Backwards compatibility
 -----------------------
Signature · 2 lines
Alex Bennée
Virtualisation Tech Lead @ Linaro
Reviewed-by on v1 1/1
#4 lore raw
In reply to Peter Maydell
Quoted 15 lines · Peter Maydell

Linux for 32-bit Arm has had two major ABIs: the original OABI and the more modern EABI. OABI support was marked as obsolete in GCC 4.7 and dropped in GCC 4.8. In the Linux kernel, compatibility handling for OABI (OABI_COMPAT) is not generally enabled by default and is not compatible with building a Thumb2 kernel. Distros dropped OABI support fifteen years or more ago.

NWFPE floating-point emulation handles the ancient FPA11 coprocessor, which is only needed/supported with OABI. Our implementation is old, untested and not thread-safe.

Mark OABI and NWFPE support as deprecated so we can remove it in a future release. Our main motivation here is to be able to drop the 2500+ lines of NWFPE emulation code.

Quoted 8 lines

---
This just came up today; it's tempting to squeeze the deprecation notice into 11.0 so we don't have an extra three months before we can delete it, but we could just deprecate in 11.1 instead.

  docs/about/deprecated.rst | 25 +++++++++++++++++++++++++
  1 file changed, 25 insertions(+)

Thank you. This is better worded and more complete than what I just posted. I look forward to removing env->eabi as well. :-)

r~