qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 0/5] tcg: Reorg 128-bit atomic operations
@ 2018-08-16  2:54 Richard Henderson
  2018-08-16  2:54 ` [Qemu-devel] [PATCH 1/5] tcg: Split CONFIG_ATOMIC128 Richard Henderson
                   ` (8 more replies)
  0 siblings, 9 replies; 18+ messages in thread
From: Richard Henderson @ 2018-08-16  2:54 UTC (permalink / raw)
  To: qemu-devel; +Cc: cota, pbonzini

The other day Emilio noticed that we weren't setting CONFIG_ATOMIC128
for x86_64, despite forcing -mcx16 on the command-line.  It seems that
gcc has changed behaviour with version 7.

There's a rather long discussion about this:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80878

It does not appear that gcc will ever quite align with our needs here.
I have added a second configure test, and have split the test to be 
used by the rest of QEMU into two compile-time constants.  This lets
us refactor the code a bit and remove some conditional compilation.

In addition, no version of gcc supports __sync_compare_and_swap_16
for aarch64.  Inline some asm for that case.

I've also checked power8, which does support CONFIG_ATOMIC128.

Comments?


r~


Richard Henderson (5):
  tcg: Split CONFIG_ATOMIC128
  target/i386: Convert to HAVE_CMPXCHG128
  target/s390x: Convert to HAVE_CMPXCHG128 and HAVE_ATOMIC128
  target/arm: Convert to HAVE_CMPXCHG128
  target/ppc: Convert to HAVE_CMPXCHG128 and HAVE_ATOMIC128

 accel/tcg/atomic_template.h |  22 ++-
 include/qemu/atomic128.h    | 162 ++++++++++++++++++++++
 target/ppc/helper.h         |   2 +-
 tcg/tcg.h                   |  29 ++--
 accel/tcg/cputlb.c          |   3 +-
 accel/tcg/user-exec.c       |   5 +-
 target/arm/helper-a64.c     | 259 ++++++++++++++++++------------------
 target/i386/mem_helper.c    |   9 +-
 target/ppc/mem_helper.c     |  33 ++++-
 target/ppc/translate.c      | 115 ++++++++--------
 target/s390x/mem_helper.c   |  87 ++++++------
 configure                   |  19 +++
 12 files changed, 481 insertions(+), 264 deletions(-)
 create mode 100644 include/qemu/atomic128.h

-- 
2.17.1

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2018-08-20 20:34 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-16  2:54 [Qemu-devel] [PATCH 0/5] tcg: Reorg 128-bit atomic operations Richard Henderson
2018-08-16  2:54 ` [Qemu-devel] [PATCH 1/5] tcg: Split CONFIG_ATOMIC128 Richard Henderson
2018-08-17 16:42   ` Emilio G. Cota
2018-08-20 19:26     ` Richard Henderson
2018-08-18 20:36   ` Emilio G. Cota
2018-08-16  2:54 ` [Qemu-devel] [PATCH 2/5] target/i386: Convert to HAVE_CMPXCHG128 Richard Henderson
2018-08-17 16:44   ` Emilio G. Cota
2018-08-16  2:54 ` [Qemu-devel] [PATCH 3/5] target/s390x: Convert to HAVE_CMPXCHG128 and HAVE_ATOMIC128 Richard Henderson
2018-08-17 17:03   ` Emilio G. Cota
2018-08-20 20:34     ` Richard Henderson
2018-08-16  2:54 ` [Qemu-devel] [PATCH 4/5] target/arm: Convert to HAVE_CMPXCHG128 Richard Henderson
2018-08-17 17:10   ` Emilio G. Cota
2018-08-16  2:54 ` [Qemu-devel] [PATCH 5/5] target/ppc: Convert to HAVE_CMPXCHG128 and HAVE_ATOMIC128 Richard Henderson
2018-08-17 17:20   ` Emilio G. Cota
2018-08-17  5:12 ` [Qemu-devel] [PATCH 0/5] tcg: Reorg 128-bit atomic operations no-reply
2018-08-17  5:17 ` no-reply
2018-08-18 12:51 ` no-reply
2018-08-18 12:58 ` no-reply

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).