diff options
author | Aurelien Jarno <aurelien@aurel32.net> | 2015-05-18 15:39:59 +0200 |
---|---|---|
committer | Alexander Graf <agraf@suse.de> | 2015-06-05 01:37:57 +0200 |
commit | d30107814c8d02f1896bd57249aef1b5aaed38c9 (patch) | |
tree | 4cc356019145ae017a94c75e5ce4981d470b20a1 /target-s390x/int_helper.c | |
parent | 2aaa1940684a3bf2b381fd2a8ff26c287a05109d (diff) |
target-s390x: optimize (negative-) abs computation
Now that movcond exists, it's easy to write (negative-) absolute value
using TCG code instead of an helper.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'target-s390x/int_helper.c')
-rw-r--r-- | target-s390x/int_helper.c | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/target-s390x/int_helper.c b/target-s390x/int_helper.c index cb8dd98542..f53723dea2 100644 --- a/target-s390x/int_helper.c +++ b/target-s390x/int_helper.c @@ -135,28 +135,6 @@ int32_t HELPER(nabs_i32)(int32_t val) } } -/* absolute value 64-bit */ -uint64_t HELPER(abs_i64)(int64_t val) -{ - HELPER_LOG("%s: val 0x%" PRIx64 "\n", __func__, val); - - if (val < 0) { - return -val; - } else { - return val; - } -} - -/* negative absolute value 64-bit */ -int64_t HELPER(nabs_i64)(int64_t val) -{ - if (val < 0) { - return val; - } else { - return -val; - } -} - /* count leading zeros, for find leftmost one */ uint64_t HELPER(clz)(uint64_t v) { |