Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 210cbd4910ae9e41e0a1785b96890ea2c291b381
      
https://github.com/qemu/qemu/commit/210cbd4910ae9e41e0a1785b96890ea2c291b381
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: implement float16_squash_input_denormal

This will be required when expanding the MINMAX() macro for 16
bit/half-precision operations.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: a9579fff616563ca34977af68c9646c8f7be1120
      
https://github.com/qemu/qemu/commit/a9579fff616563ca34977af68c9646c8f7be1120
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M include/fpu/softfloat.h

  Log Message:
  -----------
  include/fpu/softfloat: remove USE_SOFTFLOAT_STRUCT_TYPES

It's not actively built and when enabled things fail to compile. I'm
not sure the type-checking is really helping here. Seeing as we "own"
our softfloat now lets remove the cruft.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: cfd88fc6f2722def193f5ef271381d8f6e2a2526
      
https://github.com/qemu/qemu/commit/cfd88fc6f2722def193f5ef271381d8f6e2a2526
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    A include/fpu/softfloat-types.h
    M include/fpu/softfloat.h
    M include/qemu/bswap.h

  Log Message:
  -----------
  fpu/softfloat-types: new header to prevent excessive re-builds

The main culprit here is bswap.h which pulled in softfloat.h so it
could use the types in its CPU_Float* and ldfl/stfql functions. As
bswap.h is very widely included this added a compile dependency every
time we touch softfloat.h. Move the typedefs for each float type into
their own file so we don't re-build the world every time we tweak the
main softfloat.h header.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: 24f91e81b65fcdd0552d1f0fcb0ea7cfe3829c19
      
https://github.com/qemu/qemu/commit/24f91e81b65fcdd0552d1f0fcb0ea7cfe3829c19
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M include/fpu/softfloat-types.h
    M include/fpu/softfloat.h
    M target/alpha/cpu.h
    M target/arm/cpu.c
    M target/arm/cpu.h
    M target/arm/helper-a64.c
    M target/arm/helper.c
    M target/arm/neon_helper.c
    M target/hppa/cpu.c
    M target/hppa/cpu.h
    M target/hppa/op_helper.c
    M target/i386/cpu.h
    M target/i386/fpu_helper.c
    M target/m68k/cpu.c
    M target/m68k/cpu.h
    M target/m68k/fpu_helper.c
    M target/m68k/helper.c
    M target/m68k/translate.c
    M target/microblaze/cpu.c
    M target/microblaze/cpu.h
    M target/microblaze/op_helper.c
    M target/moxie/cpu.h
    M target/nios2/cpu.h
    M target/openrisc/cpu.h
    M target/openrisc/fpu_helper.c
    M target/ppc/cpu.h
    M target/ppc/fpu_helper.c
    M target/ppc/int_helper.c
    M target/ppc/translate_init.c
    M target/s390x/cpu.c
    M target/s390x/cpu.h
    M target/s390x/fpu_helper.c
    M target/sh4/cpu.c
    M target/sh4/cpu.h
    M target/sh4/op_helper.c
    M target/sparc/cpu.h
    M target/sparc/fop_helper.c
    M target/tricore/cpu.h
    M target/tricore/fpu_helper.c
    M target/tricore/helper.c
    M target/unicore32/cpu.c
    M target/unicore32/cpu.h
    M target/unicore32/ucf64_helper.c
    M target/xtensa/cpu.h
    M target/xtensa/op_helper.c

  Log Message:
  -----------
  target/*/cpu.h: remove softfloat.h

As cpu.h is another typically widely included file which doesn't need
full access to the softfloat API we can remove the includes from here
as well. Where they do need types it's typically for float_status and
the rounding modes so we move that to softfloat-types.h as well.

As a result of not having softfloat in every cpu.h call we now need to
add it to various helpers that do need the full softfloat.h
definitions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
[For PPC parts]
Acked-by: David Gibson <da...@gibson.dropbear.id.au>


  Commit: 28136775cd99c628f7d7c642b04eb87f062efef8
      
https://github.com/qemu/qemu/commit/28136775cd99c628f7d7c642b04eb87f062efef8
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M include/fpu/softfloat.h

  Log Message:
  -----------
  include/fpu/softfloat: implement float16_abs helper

This will be required when expanding the MINMAX() macro for 16
bit/half-precision operations.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: 5f10aef521427b3909c24a0c7a82839b43f876e2
      
https://github.com/qemu/qemu/commit/5f10aef521427b3909c24a0c7a82839b43f876e2
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M include/fpu/softfloat.h

  Log Message:
  -----------
  include/fpu/softfloat: implement float16_chs helper

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: 78b5a3e653c90b56ba650f54c07fc18f7b7bd905
      
https://github.com/qemu/qemu/commit/78b5a3e653c90b56ba650f54c07fc18f7b7bd905
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M include/fpu/softfloat.h

  Log Message:
  -----------
  include/fpu/softfloat: implement float16_set_sign helper

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: efd4829edfa036c5506a16d05c91268faa1f6332
      
https://github.com/qemu/qemu/commit/efd4829edfa036c5506a16d05c91268faa1f6332
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M include/fpu/softfloat.h

  Log Message:
  -----------
  include/fpu/softfloat: add some float16 constants

This defines the same set of common constants for float 16 as defined
for 32 and 64 bit floats. These are often used by target helper
functions. I've also removed constants that are not used by anybody.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: 13894527f522caab4ec74334191ef29af975e521
      
https://github.com/qemu/qemu/commit/13894527f522caab4ec74334191ef29af975e521
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat-specialize.h

  Log Message:
  -----------
  fpu/softfloat: improve comments on ARM NaN propagation

Mention the pseudo-code fragment from which this is based.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: d97544c94a37371347402bcbee19dd3748d70e48
      
https://github.com/qemu/qemu/commit/d97544c94a37371347402bcbee19dd3748d70e48
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c

  Log Message:
  -----------
  fpu/softfloat: move the extract functions to the top of the file

This is pure code-motion during re-factoring as the helpers will be
needed earlier.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: a90119b5a2c174250601be6503b91e5c9df6e83b
      
https://github.com/qemu/qemu/commit/a90119b5a2c174250601be6503b91e5c9df6e83b
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c

  Log Message:
  -----------
  fpu/softfloat: define decompose structures

These structures pave the way for generic softfloat helper routines
that will operate on fully decomposed numbers.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>


  Commit: 6fff216769cf7eaa3961c85dee7a72838696d365
      
https://github.com/qemu/qemu/commit/6fff216769cf7eaa3961c85dee7a72838696d365
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor add/sub

We can now add float16_add/sub and use the common decompose and
canonicalize functions to have a single implementation for
float16/32/64 add and sub functions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>


  Commit: 74d707e2cc1e406068acad8e5559cd2584b1073a
      
https://github.com/qemu/qemu/commit/74d707e2cc1e406068acad8e5559cd2584b1073a
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor mul

We can now add float16_mul and use the common decompose and
canonicalize functions to have a single implementation for
float16/32/64 versions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: cf07323d494f4bc225e405688c2e455c3423cc40
      
https://github.com/qemu/qemu/commit/cf07323d494f4bc225e405688c2e455c3423cc40
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat-macros.h
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor div

We can now add float16_div and use the common decompose and
canonicalize functions to have a single implementation for
float16/32/64 versions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: d446830a3aac33e7221e361dad3ab1e1892646cb
      
https://github.com/qemu/qemu/commit/d446830a3aac33e7221e361dad3ab1e1892646cb
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat-specialize.h
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor muladd

We can now add float16_muladd and use the common decompose and
canonicalize functions to have a single implementation for
float16/32/64 muladd functions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: dbe4d53a590f5689772b683984588b3cf6df163e
      
https://github.com/qemu/qemu/commit/dbe4d53a590f5689772b683984588b3cf6df163e
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor round_to_int

We can now add float16_round_to_int and use the common round_decomposed and
canonicalize functions to have a single implementation for
float16/32/64 round_to_int functions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>


  Commit: ab52f973a504f8de0c5df64631ba4caea70a7d9e
      
https://github.com/qemu/qemu/commit/ab52f973a504f8de0c5df64631ba4caea70a7d9e
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor float to int/uint

We share the common int64/uint64_pack_decomposed function across all
the helpers and simply limit the final result depending on the final
size.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: c02e1fb80b553d47420f7492de4bc590c2461a86
      
https://github.com/qemu/qemu/commit/c02e1fb80b553d47420f7492de4bc590c2461a86
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor int/uint to float

These are considerably simpler as the lower order integers can just
use the higher order conversion function. As the decomposed fractional
part is a full 64 bit rounding and inexact handling comes from the
pack functions.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: 0bfc9f195209593e91a98cf2233753f56a2e5c02
      
https://github.com/qemu/qemu/commit/0bfc9f195209593e91a98cf2233753f56a2e5c02
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor scalbn

This is one of the simpler manipulations you could make to a floating
point number.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: 89360067071b1844bf745682e18db7dde74cdb8d
      
https://github.com/qemu/qemu/commit/89360067071b1844bf745682e18db7dde74cdb8d
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor minmax

Let's do the same re-factor treatment for minmax functions. I still
use the MACRO trick to expand but now all the checking code is common.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: 0c4c90929143a530730e2879204a55a30bf63758
      
https://github.com/qemu/qemu/commit/0c4c90929143a530730e2879204a55a30bf63758
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor compare

The compare function was already expanded from a macro. I keep the
macro expansion but move most of the logic into a compare_decomposed.

Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: c13bb2da9eedfbc5886c8048df1bc1114b285fb0
      
https://github.com/qemu/qemu/commit/c13bb2da9eedfbc5886c8048df1bc1114b285fb0
  Author: Alex Bennée <alex.ben...@linaro.org>
  Date:   2018-02-21 (Wed, 21 Feb 2018)

  Changed paths:
    M fpu/softfloat.c
    M include/fpu/softfloat.h

  Log Message:
  -----------
  fpu/softfloat: re-factor sqrt

This is a little bit of a departure from softfloat's original approach
as we skip the estimate step in favour of a straight iteration. There
is a minor optimisation to avoid calculating more bits of precision
than we need however this still brings a performance drop, especially
for float64 operations.

Suggested-by: Richard Henderson <richard.hender...@linaro.org>
Signed-off-by: Alex Bennée <alex.ben...@linaro.org>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


  Commit: 2b78551f8dafa644128d34e2cc884a8523efa225
      
https://github.com/qemu/qemu/commit/2b78551f8dafa644128d34e2cc884a8523efa225
  Author: Peter Maydell <peter.mayd...@linaro.org>
  Date:   2018-02-22 (Thu, 22 Feb 2018)

  Changed paths:
    M fpu/softfloat-macros.h
    M fpu/softfloat-specialize.h
    M fpu/softfloat.c
    A include/fpu/softfloat-types.h
    M include/fpu/softfloat.h
    M include/qemu/bswap.h
    M target/alpha/cpu.h
    M target/arm/cpu.c
    M target/arm/cpu.h
    M target/arm/helper-a64.c
    M target/arm/helper.c
    M target/arm/neon_helper.c
    M target/hppa/cpu.c
    M target/hppa/cpu.h
    M target/hppa/op_helper.c
    M target/i386/cpu.h
    M target/i386/fpu_helper.c
    M target/m68k/cpu.c
    M target/m68k/cpu.h
    M target/m68k/fpu_helper.c
    M target/m68k/helper.c
    M target/m68k/translate.c
    M target/microblaze/cpu.c
    M target/microblaze/cpu.h
    M target/microblaze/op_helper.c
    M target/moxie/cpu.h
    M target/nios2/cpu.h
    M target/openrisc/cpu.h
    M target/openrisc/fpu_helper.c
    M target/ppc/cpu.h
    M target/ppc/fpu_helper.c
    M target/ppc/int_helper.c
    M target/ppc/translate_init.c
    M target/s390x/cpu.c
    M target/s390x/cpu.h
    M target/s390x/fpu_helper.c
    M target/sh4/cpu.c
    M target/sh4/cpu.h
    M target/sh4/op_helper.c
    M target/sparc/cpu.h
    M target/sparc/fop_helper.c
    M target/tricore/cpu.h
    M target/tricore/fpu_helper.c
    M target/tricore/helper.c
    M target/unicore32/cpu.c
    M target/unicore32/cpu.h
    M target/unicore32/ucf64_helper.c
    M target/xtensa/cpu.h
    M target/xtensa/op_helper.c

  Log Message:
  -----------
  Merge remote-tracking branch 
'remotes/stsquad/tags/pull-softfloat-refactor-210218-1' into staging

This is the re-factor of softfloat:

  - shared common code path float16/32/64
  - well commented and easy to follow code
  - added a bunch of float16 support

While some operations are slower the key ones exercised by the
floating point dbt-bench are the same: https://i.imgur.com/oXNJNql.png

# gpg: Signature made Wed 21 Feb 2018 10:44:14 GMT
# gpg:                using RSA key FBD0DB095A9E2A44
# gpg: Good signature from "Alex Bennée (Master Work Key) 
<alex.ben...@linaro.org>"
# Primary key fingerprint: 6685 AE99 E751 67BC AFC8  DF35 FBD0 DB09 5A9E 2A44

* remotes/stsquad/tags/pull-softfloat-refactor-210218-1: (22 commits)
  fpu/softfloat: re-factor sqrt
  fpu/softfloat: re-factor compare
  fpu/softfloat: re-factor minmax
  fpu/softfloat: re-factor scalbn
  fpu/softfloat: re-factor int/uint to float
  fpu/softfloat: re-factor float to int/uint
  fpu/softfloat: re-factor round_to_int
  fpu/softfloat: re-factor muladd
  fpu/softfloat: re-factor div
  fpu/softfloat: re-factor mul
  fpu/softfloat: re-factor add/sub
  fpu/softfloat: define decompose structures
  fpu/softfloat: move the extract functions to the top of the file
  fpu/softfloat: improve comments on ARM NaN propagation
  include/fpu/softfloat: add some float16 constants
  include/fpu/softfloat: implement float16_set_sign helper
  include/fpu/softfloat: implement float16_chs helper
  include/fpu/softfloat: implement float16_abs helper
  target/*/cpu.h: remove softfloat.h
  fpu/softfloat-types: new header to prevent excessive re-builds
  ...

Signed-off-by: Peter Maydell <peter.mayd...@linaro.org>


Compare: https://github.com/qemu/qemu/compare/a6e0344fa0e0...2b78551f8daf

Reply via email to