diff options
| author | David Gibson | 2018-12-19 02:26:20 +0100 |
|---|---|---|
| committer | David Gibson | 2018-12-20 23:24:23 +0100 |
| commit | 6187ec05edc240204935fdf0d89cded563fdeab4 (patch) | |
| tree | c497c6bfedbce4d4500aa1d6e380726d97e4c61f /target | |
| parent | target/ppc: fix the PPC_BIT definitions (diff) | |
| download | qemu-6187ec05edc240204935fdf0d89cded563fdeab4.tar.gz qemu-6187ec05edc240204935fdf0d89cded563fdeab4.tar.xz qemu-6187ec05edc240204935fdf0d89cded563fdeab4.zip | |
target/ppc: Remove silly GETFIELD/SETFIELD/MASK_TO_LSH macros
The (only) obvious use for these macros is constructing and parsing guest
visible register fields. But the way they're constructed, they're only
valid when used on a *host* long, whose size shouldn't be visible to the
guest at all.
They also have no current users, so just get rid of them.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'target')
| -rw-r--r-- | target/ppc/cpu.h | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/target/ppc/cpu.h b/target/ppc/cpu.h index 527181c0f0..d5f99f1fc7 100644 --- a/target/ppc/cpu.h +++ b/target/ppc/cpu.h @@ -78,18 +78,6 @@ PPC_BIT32(bs)) #define PPC_BITMASK8(bs, be) ((PPC_BIT8(bs) - PPC_BIT8(be)) | PPC_BIT8(bs)) -#if HOST_LONG_BITS == 32 -# define MASK_TO_LSH(m) (__builtin_ffsll(m) - 1) -#elif HOST_LONG_BITS == 64 -# define MASK_TO_LSH(m) (__builtin_ffsl(m) - 1) -#else -# error Unknown sizeof long -#endif - -#define GETFIELD(m, v) (((v) & (m)) >> MASK_TO_LSH(m)) -#define SETFIELD(m, v, val) \ - (((v) & ~(m)) | ((((typeof(v))(val)) << MASK_TO_LSH(m)) & (m))) - /*****************************************************************************/ /* Exception vectors definitions */ enum { |
