qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v1 00/14] fp-test + hostfloat


From: no-reply
Subject: Re: [Qemu-devel] [PATCH v1 00/14] fp-test + hostfloat
Date: Wed, 21 Mar 2018 22:02:14 -0700 (PDT)

Hi,

This series seems to have some coding style problems. See output below for
more information:

Type: series
Message-id: address@hidden
Subject: [Qemu-devel] [PATCH v1 00/14] fp-test + hostfloat

=== TEST SCRIPT BEGIN ===
#!/bin/bash

BASE=base
n=1
total=$(git log --oneline $BASE.. | wc -l)
failed=0

git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram

commits="$(git log --format=%H --reverse $BASE..)"
for c in $commits; do
    echo "Checking PATCH $n/$total: $(git log -n 1 --format=%s $c)..."
    if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then
        failed=1
        echo
    fi
    n=$((n+1))
done

exit $failed
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
Switched to a new branch 'test'
2776883619 hostfloat: support float32_to_float64
dbb0c2a60b hostfloat: support float32/64 comparison
b21bd8b75d hostfloat: support float32/64 square root
40b1723ab1 hostfloat: support float32/64 fused multiply-add
d1ff4b2bcd hostfloat: support float32/64 division
6622d46dfe hostfloat: support float32/64 multiplication
a2e1f5e4c7 hostfloat: support float32/64 addition and subtraction
d25f954555 fpu: introduce hostfloat
4356927b54 softfloat: add float32_is_denormal and float64_is_denormal
4ceef15bf5 softfloat: add float32_is_normal and float64_is_normal
30f0f71fd2 fp-test: add muladd variants
ac7bd8e7f7 softfloat: fix {min, max}nummag for same-abs-value inputs
72f8541c7c tests: add fp-test, a floating point test suite
5718f9fdf4 tests: add fp-bench, a collection of simple floating-point 
microbenchmarks

=== OUTPUT BEGIN ===
Checking PATCH 1/14: tests: add fp-bench, a collection of simple floating-point 
microbenchmarks...
ERROR: braces {} are necessary for all arms of this statement
#165: FILE: tests/fp-bench.c:114:
+    } while (!u32_is_normal(r));
[...]

ERROR: braces {} are necessary for all arms of this statement
#177: FILE: tests/fp-bench.c:126:
+    } while (!u64_is_normal(r));
[...]

ERROR: spaces required around that '*' (ctx:WxV)
#187: FILE: tests/fp-bench.c:136:
+    static void NAME(volatile PRECISION *res)                           \
                                         ^

ERROR: Use of volatile is usually wrong, please add a comment
#187: FILE: tests/fp-bench.c:136:
+    static void NAME(volatile PRECISION *res)                           \

ERROR: Use of volatile is usually wrong, please add a comment
#193: FILE: tests/fp-bench.c:142:
+            volatile PRECISION a = glue(get_random_, PRECISION)(&ra);   \

ERROR: Use of volatile is usually wrong, please add a comment
#206: FILE: tests/fp-bench.c:155:
+    static void NAME(volatile PRECISION *res)                           \

ERROR: Use of volatile is usually wrong, please add a comment
#213: FILE: tests/fp-bench.c:162:
+            volatile PRECISION a = glue(get_random_, PRECISION)(&ra);   \

ERROR: Use of volatile is usually wrong, please add a comment
#214: FILE: tests/fp-bench.c:163:
+            volatile PRECISION b = glue(get_random_, PRECISION)(&rb);   \

ERROR: Use of volatile is usually wrong, please add a comment
#233: FILE: tests/fp-bench.c:182:
+    static void NAME(volatile PRECISION *res)                           \

ERROR: Use of volatile is usually wrong, please add a comment
#241: FILE: tests/fp-bench.c:190:
+            volatile PRECISION a = glue(get_random_, PRECISION)(&ra);   \

ERROR: Use of volatile is usually wrong, please add a comment
#242: FILE: tests/fp-bench.c:191:
+            volatile PRECISION b = glue(get_random_, PRECISION)(&rb);   \

ERROR: Use of volatile is usually wrong, please add a comment
#243: FILE: tests/fp-bench.c:192:
+            volatile PRECISION c = glue(get_random_, PRECISION)(&rc);   \

ERROR: braces {} are necessary for all arms of this statement
#315: FILE: tests/fp-bench.c:264:
+    } while (0)
[...]

total: 13 errors, 0 warnings, 312 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 2/14: tests: add fp-test, a floating point test suite...
ERROR: Macros with complex values should be enclosed in parenthesis
#378: FILE: tests/fp-test/fp-test.c:220:
+#define PR_EXCEPTIONS(x)                                \
+        ((x) & STANDARD_EXCEPTIONS ? "" : "none"),      \
+        (((x) & float_flag_inexact)   ? "x" : ""),      \
+        (((x) & float_flag_underflow) ? "u" : ""),      \
+        (((x) & float_flag_overflow)  ? "o" : ""),      \
+        (((x) & float_flag_divbyzero) ? "z" : ""),      \
+        (((x) & float_flag_invalid)   ? "i" : "")

ERROR: consider using qemu_strtoul in preference to strtoul
#839: FILE: tests/fp-test/fp-test.c:681:
+            significand = strtoul(&p[3], &pos, 16);

ERROR: consider using qemu_strtol in preference to strtol
#844: FILE: tests/fp-test/fp-test.c:686:
+            exponent = strtol(pos, &pos, 10) + 127;

ERROR: consider using qemu_strtoul in preference to strtoul
#869: FILE: tests/fp-test/fp-test.c:711:
+            significand = strtoul(&p[3], &pos, 16);

ERROR: consider using qemu_strtol in preference to strtol
#874: FILE: tests/fp-test/fp-test.c:716:
+            exponent = strtol(pos, &pos, 10) + 1023;

ERROR: consider using qemu_strtof in preference to strtof
#893: FILE: tests/fp-test/fp-test.c:735:
+            float f = strtof(p, &pos);

total: 6 errors, 0 warnings, 1216 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 3/14: softfloat: fix {min, max}nummag for same-abs-value 
inputs...
Checking PATCH 4/14: fp-test: add muladd variants...
Checking PATCH 5/14: softfloat: add float32_is_normal and float64_is_normal...
Checking PATCH 6/14: softfloat: add float32_is_denormal and 
float64_is_denormal...
Checking PATCH 7/14: fpu: introduce hostfloat...
ERROR: spaces required around that '*' (ctx:WxV)
#103: FILE: fpu/hostfloat.c:54:
+    soft_t ## _input_flush__nocheck(soft_t *a, float_status *s)         \
                                                             ^

ERROR: spaces required around that '*' (ctx:WxV)
#113: FILE: fpu/hostfloat.c:64:
+    soft_t ## _input_flush1(soft_t *a, float_status *s)                 \
                                                     ^

ERROR: spaces required around that '*' (ctx:WxV)
#122: FILE: fpu/hostfloat.c:73:
+    soft_t ## _input_flush2(soft_t *a, soft_t *b, float_status *s)      \
                                                                ^

ERROR: spaces required around that '*' (ctx:WxV)
#133: FILE: fpu/hostfloat.c:84:
+                            float_status *s)                            \
                                          ^

total: 4 errors, 0 warnings, 139 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 8/14: hostfloat: support float32/64 addition and subtraction...
ERROR: spaces required around that '*' (ctx:WxV)
#38: FILE: fpu/hostfloat.c:102:
+                              float_status *s)                          \
                                            ^

total: 1 errors, 0 warnings, 123 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 9/14: hostfloat: support float32/64 multiplication...
ERROR: spaces required around that '*' (ctx:WxV)
#33: FILE: fpu/hostfloat.c:149:
+    soft_t name(soft_t a, soft_t b, float_status *s)                    \
                                                  ^

total: 1 errors, 0 warnings, 83 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 10/14: hostfloat: support float32/64 division...
ERROR: spaces required around that '*' (ctx:WxV)
#30: FILE: fpu/hostfloat.c:183:
+    soft_t name(soft_t a, soft_t b, float_status *s)                    \
                                                  ^

total: 1 errors, 0 warnings, 74 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 11/14: hostfloat: support float32/64 fused multiply-add...
ERROR: spaces required around that '*' (ctx:WxV)
#37: FILE: fpu/hostfloat.c:215:
+    soft_t name(soft_t a, soft_t b, soft_t c, int flags, float_status *s) \
                                                                       ^

total: 1 errors, 0 warnings, 117 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 12/14: hostfloat: support float32/64 square root...
ERROR: spaces required around that '*' (ctx:WxV)
#34: FILE: fpu/hostfloat.c:275:
+    soft_t name(soft_t a, float_status *s)                              \
                                        ^

total: 1 errors, 0 warnings, 70 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 13/14: hostfloat: support float32/64 comparison...
ERROR: spaces required around that '*' (ctx:WxV)
#22: FILE: fpu/hostfloat.c:296:
+    fpu_ ## name(soft_t a, soft_t b, bool is_quiet, float_status *s)    \
                                                                  ^

ERROR: storage class should be at the beginning of the declaration
#87: FILE: fpu/softfloat.c:1861:
+COMPARE(static, 16)

total: 2 errors, 0 warnings, 120 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 14/14: hostfloat: support float32_to_float64...
ERROR: spaces required around that '*' (ctx:WxV)
#114: FILE: fpu/hostfloat.c:330:
+float64 float32_to_float64(float32 a, float_status *status)
                                                    ^

total: 1 errors, 0 warnings, 39 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

=== OUTPUT END ===

Test command exited with code: 1


---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]