mbox series

[v5,00/57] TCI fixes and cleanups

Message ID 20210311143958.562625-1-richard.henderson@linaro.org
Headers show
Series TCI fixes and cleanups | expand

Message

Richard Henderson March 11, 2021, 2:39 p.m. UTC
Changes since v4:
  * 19 more patches now upstream.

Changes since v3:
  * First patch fixes g2h() breakage.  This shows a hole in our CI,
    in that we only build softmmu with TCI, not linux-user.
  * Tidy-up for the magic qemu_ld/st macros.
  * Fix libffi return value case with ffi_arg.

Changes since v2:
  * 20-something patches are now upstream.
  * Increase testing timeout for tci.
  * Gitlab testing for tci w/ 32-bit host.


r~


Richard Henderson (57):
  tcg/tci: Remove ifdefs for TCG_TARGET_HAS_ext32[us]_i64
  tcg/tci: Rename tci_read_r to tci_read_rval
  tcg/tci: Split out tci_args_rrs
  tcg/tci: Split out tci_args_rr
  tcg/tci: Split out tci_args_rrr
  tcg/tci: Split out tci_args_rrrc
  tcg/tci: Split out tci_args_l
  tcg/tci: Split out tci_args_rrrrrc
  tcg/tci: Split out tci_args_rrcl and tci_args_rrrrcl
  tcg/tci: Split out tci_args_ri and tci_args_rI
  tcg/tci: Reuse tci_args_l for calls.
  tcg/tci: Reuse tci_args_l for exit_tb
  tcg/tci: Reuse tci_args_l for goto_tb
  tcg/tci: Split out tci_args_rrrrrr
  tcg/tci: Split out tci_args_rrrr
  tcg/tci: Clean up deposit operations
  tcg/tci: Reduce qemu_ld/st TCGMemOpIdx operand to 32-bits
  tcg/tci: Split out tci_args_{rrm,rrrm,rrrrm}
  tcg/tci: Hoist op_size checking into tci_args_*
  tcg/tci: Remove tci_disas
  tcg/tci: Implement the disassembler properly
  tcg: Build ffi data structures for helpers
  tcg/tci: Use ffi for calls
  tcg/tci: Improve tcg_target_call_clobber_regs
  tcg/tci: Move call-return regs to end of tcg_target_reg_alloc_order
  tcg/tci: Push opcode emit into each case
  tcg/tci: Split out tcg_out_op_rrs
  tcg/tci: Split out tcg_out_op_l
  tcg/tci: Split out tcg_out_op_p
  tcg/tci: Split out tcg_out_op_rr
  tcg/tci: Split out tcg_out_op_rrr
  tcg/tci: Split out tcg_out_op_rrrc
  tcg/tci: Split out tcg_out_op_rrrrrc
  tcg/tci: Split out tcg_out_op_rrrbb
  tcg/tci: Split out tcg_out_op_rrcl
  tcg/tci: Split out tcg_out_op_rrrrrr
  tcg/tci: Split out tcg_out_op_rrrr
  tcg/tci: Split out tcg_out_op_rrrrcl
  tcg/tci: Split out tcg_out_op_{rrm,rrrm,rrrrm}
  tcg/tci: Split out tcg_out_op_v
  tcg/tci: Split out tcg_out_op_np
  tcg/tci: Split out tcg_out_op_r[iI]
  tcg/tci: Reserve r13 for a temporary
  tcg/tci: Emit setcond before brcond
  tcg/tci: Remove tci_write_reg
  tcg/tci: Change encoding to uint32_t units
  tcg/tci: Implement goto_ptr
  tcg/tci: Implement movcond
  tcg/tci: Implement andc, orc, eqv, nand, nor
  tcg/tci: Implement extract, sextract
  tcg/tci: Implement clz, ctz, ctpop
  tcg/tci: Implement mulu2, muls2
  tcg/tci: Implement add2, sub2
  tcg/tci: Split out tci_qemu_ld, tci_qemu_st
  tests/tcg: Increase timeout for TCI
  gitlab: Rename ACCEL_CONFIGURE_OPTS to EXTRA_CONFIGURE_OPTS
  gitlab: Enable cross-i386 builds of TCI

 configure                                     |    3 +
 meson.build                                   |    9 +-
 include/exec/helper-ffi.h                     |  115 ++
 include/exec/helper-tcg.h                     |   24 +-
 include/tcg/tcg-opc.h                         |    6 +-
 include/tcg/tcg.h                             |    1 +
 target/hppa/helper.h                          |    2 +
 target/i386/ops_sse_header.h                  |    6 +
 target/m68k/helper.h                          |    1 +
 target/ppc/helper.h                           |    3 +
 tcg/tci/tcg-target-con-set.h                  |    2 +-
 tcg/tci/tcg-target.h                          |   81 +-
 disas/tci.c                                   |   61 -
 tcg/tcg.c                                     |   88 +-
 tcg/tci.c                                     | 1517 ++++++++++-------
 tcg/tci/tcg-target.c.inc                      |  704 +++++---
 .gitlab-ci.d/crossbuilds.yml                  |   21 +-
 tcg/tci/README                                |   20 +-
 .../dockerfiles/fedora-i386-cross.docker      |    1 +
 tests/docker/dockerfiles/fedora.docker        |    1 +
 tests/tcg/Makefile.target                     |    6 +-
 21 files changed, 1668 insertions(+), 1004 deletions(-)
 create mode 100644 include/exec/helper-ffi.h
 delete mode 100644 disas/tci.c

-- 
2.25.1

Comments

no-reply@patchew.org March 11, 2021, 3:28 p.m. UTC | #1
Patchew URL: https://patchew.org/QEMU/20210311143958.562625-1-richard.henderson@linaro.org/



Hi,

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

Type: series
Message-id: 20210311143958.562625-1-richard.henderson@linaro.org
Subject: [PATCH v5 00/57] TCI fixes and cleanups

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
From https://github.com/patchew-project/qemu
 * [new tag]         patchew/20210311143958.562625-1-richard.henderson@linaro.org -> patchew/20210311143958.562625-1-richard.henderson@linaro.org
Switched to a new branch 'test'
99c15a6 gitlab: Enable cross-i386 builds of TCI
9681234 gitlab: Rename ACCEL_CONFIGURE_OPTS to EXTRA_CONFIGURE_OPTS
9982365 tests/tcg: Increase timeout for TCI
e9049ee tcg/tci: Split out tci_qemu_ld, tci_qemu_st
e346cc8 tcg/tci: Implement add2, sub2
d2cd749 tcg/tci: Implement mulu2, muls2
9fc40e7 tcg/tci: Implement clz, ctz, ctpop
9242621 tcg/tci: Implement extract, sextract
5e91e61 tcg/tci: Implement andc, orc, eqv, nand, nor
436fde1 tcg/tci: Implement movcond
6f45c0a tcg/tci: Implement goto_ptr
fd62018 tcg/tci: Change encoding to uint32_t units
cb34800 tcg/tci: Remove tci_write_reg
cfcf8b5 tcg/tci: Emit setcond before brcond
1ba97dc tcg/tci: Reserve r13 for a temporary
8c864eb tcg/tci: Split out tcg_out_op_r[iI]
5425ede tcg/tci: Split out tcg_out_op_np
d04350c tcg/tci: Split out tcg_out_op_v
1f222db tcg/tci: Split out tcg_out_op_{rrm,rrrm,rrrrm}
c3fa67b tcg/tci: Split out tcg_out_op_rrrrcl
6509cb6 tcg/tci: Split out tcg_out_op_rrrr
ad382a1b tcg/tci: Split out tcg_out_op_rrrrrr
ac3f95c tcg/tci: Split out tcg_out_op_rrcl
418c425 tcg/tci: Split out tcg_out_op_rrrbb
3a2eb09 tcg/tci: Split out tcg_out_op_rrrrrc
1749219 tcg/tci: Split out tcg_out_op_rrrc
707f50f tcg/tci: Split out tcg_out_op_rrr
9a83aa3 tcg/tci: Split out tcg_out_op_rr
d3a59dc tcg/tci: Split out tcg_out_op_p
afb1645 tcg/tci: Split out tcg_out_op_l
77b7cf1 tcg/tci: Split out tcg_out_op_rrs
44e6265 tcg/tci: Push opcode emit into each case
b3e96e0 tcg/tci: Move call-return regs to end of tcg_target_reg_alloc_order
84b1855 tcg/tci: Improve tcg_target_call_clobber_regs
8026708 tcg/tci: Use ffi for calls
3c5c746 tcg: Build ffi data structures for helpers
7b99cf3 tcg/tci: Implement the disassembler properly
001c0ca tcg/tci: Remove tci_disas
b83b3b5 tcg/tci: Hoist op_size checking into tci_args_*
d3cef88 tcg/tci: Split out tci_args_{rrm,rrrm,rrrrm}
18d840c tcg/tci: Reduce qemu_ld/st TCGMemOpIdx operand to 32-bits
782db77 tcg/tci: Clean up deposit operations
f3ab702 tcg/tci: Split out tci_args_rrrr
a5391ef tcg/tci: Split out tci_args_rrrrrr
a57601f tcg/tci: Reuse tci_args_l for goto_tb
ced6485 tcg/tci: Reuse tci_args_l for exit_tb
a237ff3 tcg/tci: Reuse tci_args_l for calls.
da4452e tcg/tci: Split out tci_args_ri and tci_args_rI
e2dd751 tcg/tci: Split out tci_args_rrcl and tci_args_rrrrcl
9610b85 tcg/tci: Split out tci_args_rrrrrc
18776ef tcg/tci: Split out tci_args_l
0d5460f tcg/tci: Split out tci_args_rrrc
0ff692c tcg/tci: Split out tci_args_rrr
d03b3ba tcg/tci: Split out tci_args_rr
0921430 tcg/tci: Split out tci_args_rrs
fe48d9c tcg/tci: Rename tci_read_r to tci_read_rval
cdae30e tcg/tci: Remove ifdefs for TCG_TARGET_HAS_ext32[us]_i64

=== OUTPUT BEGIN ===
1/57 Checking commit cdae30e4c067 (tcg/tci: Remove ifdefs for TCG_TARGET_HAS_ext32[us]_i64)
2/57 Checking commit fe48d9ce529a (tcg/tci: Rename tci_read_r to tci_read_rval)
3/57 Checking commit 09214305f118 (tcg/tci: Split out tci_args_rrs)
4/57 Checking commit d03b3baa2745 (tcg/tci: Split out tci_args_rr)
5/57 Checking commit 0ff692c10b3a (tcg/tci: Split out tci_args_rrr)
6/57 Checking commit 0d5460f2e7e3 (tcg/tci: Split out tci_args_rrrc)
7/57 Checking commit 18776efcf40e (tcg/tci: Split out tci_args_l)
8/57 Checking commit 9610b85bc835 (tcg/tci: Split out tci_args_rrrrrc)
9/57 Checking commit e2dd7519249f (tcg/tci: Split out tci_args_rrcl and tci_args_rrrrcl)
10/57 Checking commit da4452e08546 (tcg/tci: Split out tci_args_ri and tci_args_rI)
11/57 Checking commit a237ff30a6f8 (tcg/tci: Reuse tci_args_l for calls.)
12/57 Checking commit ced6485030fd (tcg/tci: Reuse tci_args_l for exit_tb)
13/57 Checking commit a57601f2b7c6 (tcg/tci: Reuse tci_args_l for goto_tb)
14/57 Checking commit a5391ef45d8b (tcg/tci: Split out tci_args_rrrrrr)
15/57 Checking commit f3ab7021af46 (tcg/tci: Split out tci_args_rrrr)
16/57 Checking commit 782db77aeeba (tcg/tci: Clean up deposit operations)
17/57 Checking commit 18d840c320ee (tcg/tci: Reduce qemu_ld/st TCGMemOpIdx operand to 32-bits)
18/57 Checking commit d3cef88166b1 (tcg/tci: Split out tci_args_{rrm,rrrm,rrrrm})
19/57 Checking commit b83b3b5cae59 (tcg/tci: Hoist op_size checking into tci_args_*)
20/57 Checking commit 001c0ca7f67c (tcg/tci: Remove tci_disas)
21/57 Checking commit 7b99cf331b99 (tcg/tci: Implement the disassembler properly)
Use of uninitialized value $acpi_testexpected in string eq at ./scripts/checkpatch.pl line 1529.
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#21: 
deleted file mode 100644

total: 0 errors, 1 warnings, 304 lines checked

Patch 21/57 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
22/57 Checking commit 3c5c746b5e79 (tcg: Build ffi data structures for helpers)
Use of uninitialized value $acpi_testexpected in string eq at ./scripts/checkpatch.pl line 1529.
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#25: 
new file mode 100644

ERROR: Macros with complex values should be enclosed in parenthesis
#40: FILE: include/exec/helper-ffi.h:11:
+#define dh_ffitype_i32  &ffi_type_uint32

ERROR: Macros with complex values should be enclosed in parenthesis
#41: FILE: include/exec/helper-ffi.h:12:
+#define dh_ffitype_s32  &ffi_type_sint32

ERROR: Macros with complex values should be enclosed in parenthesis
#43: FILE: include/exec/helper-ffi.h:14:
+#define dh_ffitype_i64  &ffi_type_uint64

ERROR: Macros with complex values should be enclosed in parenthesis
#44: FILE: include/exec/helper-ffi.h:15:
+#define dh_ffitype_s64  &ffi_type_sint64

ERROR: Macros with complex values should be enclosed in parenthesis
#45: FILE: include/exec/helper-ffi.h:16:
+#define dh_ffitype_f16  &ffi_type_uint32

ERROR: Macros with complex values should be enclosed in parenthesis
#46: FILE: include/exec/helper-ffi.h:17:
+#define dh_ffitype_f32  &ffi_type_uint32

ERROR: Macros with complex values should be enclosed in parenthesis
#47: FILE: include/exec/helper-ffi.h:18:
+#define dh_ffitype_f64  &ffi_type_uint64

ERROR: Macros with complex values should be enclosed in parenthesis
#50: FILE: include/exec/helper-ffi.h:21:
+#  define dh_ffitype_tl &ffi_type_uint32

ERROR: Macros with complex values should be enclosed in parenthesis
#52: FILE: include/exec/helper-ffi.h:23:
+#  define dh_ffitype_tl &ffi_type_uint64

ERROR: Macros with complex values should be enclosed in parenthesis
#55: FILE: include/exec/helper-ffi.h:26:
+#define dh_ffitype_ptr  &ffi_type_pointer

ERROR: Macros with complex values should be enclosed in parenthesis
#56: FILE: include/exec/helper-ffi.h:27:
+#define dh_ffitype_cptr &ffi_type_pointer

ERROR: Macros with complex values should be enclosed in parenthesis
#59: FILE: include/exec/helper-ffi.h:30:
+#define dh_ffitype_env  &ffi_type_pointer

ERROR: space required after that ',' (ctx:VxV)
#63: FILE: include/exec/helper-ffi.h:34:
+    static ffi_cif glue(cif_,NAME) = {          \
                             ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#67: FILE: include/exec/helper-ffi.h:38:
+#define DEF_HELPER_FLAGS_1(NAME, FLAGS, ret, t1)                        \
+    static ffi_type *glue(cif_args_,NAME)[1] = { dh_ffitype(t1) };      \
+    static ffi_cif glue(cif_,NAME) = {                                  \
+        .rtype = dh_ffitype(ret), .nargs = 1,                           \
+        .arg_types = glue(cif_args_,NAME),                              \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#68: FILE: include/exec/helper-ffi.h:39:
+    static ffi_type *glue(cif_args_,NAME)[1] = { dh_ffitype(t1) };      \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#68: FILE: include/exec/helper-ffi.h:39:
+    static ffi_type *glue(cif_args_,NAME)[1] = { dh_ffitype(t1) };      \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#69: FILE: include/exec/helper-ffi.h:40:
+    static ffi_cif glue(cif_,NAME) = {                                  \

ERROR: space required after that ',' (ctx:VxV)
#69: FILE: include/exec/helper-ffi.h:40:
+    static ffi_cif glue(cif_,NAME) = {                                  \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#71: FILE: include/exec/helper-ffi.h:42:
+        .arg_types = glue(cif_args_,NAME),                              \
                                    ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#74: FILE: include/exec/helper-ffi.h:45:
+#define DEF_HELPER_FLAGS_2(NAME, FLAGS, ret, t1, t2)    \
+    static ffi_type *glue(cif_args_,NAME)[2] = {        \
+        dh_ffitype(t1), dh_ffitype(t2)                  \
+    };                                                  \
+    static ffi_cif glue(cif_,NAME) = {                  \
+        .rtype = dh_ffitype(ret), .nargs = 2,           \
+        .arg_types = glue(cif_args_,NAME),              \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#75: FILE: include/exec/helper-ffi.h:46:
+    static ffi_type *glue(cif_args_,NAME)[2] = {        \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#75: FILE: include/exec/helper-ffi.h:46:
+    static ffi_type *glue(cif_args_,NAME)[2] = {        \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#78: FILE: include/exec/helper-ffi.h:49:
+    static ffi_cif glue(cif_,NAME) = {                  \

ERROR: space required after that ',' (ctx:VxV)
#78: FILE: include/exec/helper-ffi.h:49:
+    static ffi_cif glue(cif_,NAME) = {                  \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#80: FILE: include/exec/helper-ffi.h:51:
+        .arg_types = glue(cif_args_,NAME),              \
                                    ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#83: FILE: include/exec/helper-ffi.h:54:
+#define DEF_HELPER_FLAGS_3(NAME, FLAGS, ret, t1, t2, t3)        \
+    static ffi_type *glue(cif_args_,NAME)[3] = {                \
+        dh_ffitype(t1), dh_ffitype(t2), dh_ffitype(t3)          \
+    };                                                          \
+    static ffi_cif glue(cif_,NAME) = {                          \
+        .rtype = dh_ffitype(ret), .nargs = 3,                   \
+        .arg_types = glue(cif_args_,NAME),                      \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#84: FILE: include/exec/helper-ffi.h:55:
+    static ffi_type *glue(cif_args_,NAME)[3] = {                \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#84: FILE: include/exec/helper-ffi.h:55:
+    static ffi_type *glue(cif_args_,NAME)[3] = {                \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#87: FILE: include/exec/helper-ffi.h:58:
+    static ffi_cif glue(cif_,NAME) = {                          \

ERROR: space required after that ',' (ctx:VxV)
#87: FILE: include/exec/helper-ffi.h:58:
+    static ffi_cif glue(cif_,NAME) = {                          \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#89: FILE: include/exec/helper-ffi.h:60:
+        .arg_types = glue(cif_args_,NAME),                      \
                                    ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#92: FILE: include/exec/helper-ffi.h:63:
+#define DEF_HELPER_FLAGS_4(NAME, FLAGS, ret, t1, t2, t3, t4)            \
+    static ffi_type *glue(cif_args_,NAME)[4] = {                        \
+        dh_ffitype(t1), dh_ffitype(t2), dh_ffitype(t3), dh_ffitype(t4)  \
+    };                                                                  \
+    static ffi_cif glue(cif_,NAME) = {                                  \
+        .rtype = dh_ffitype(ret), .nargs = 4,                           \
+        .arg_types = glue(cif_args_,NAME),                              \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#93: FILE: include/exec/helper-ffi.h:64:
+    static ffi_type *glue(cif_args_,NAME)[4] = {                        \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#93: FILE: include/exec/helper-ffi.h:64:
+    static ffi_type *glue(cif_args_,NAME)[4] = {                        \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#96: FILE: include/exec/helper-ffi.h:67:
+    static ffi_cif glue(cif_,NAME) = {                                  \

ERROR: space required after that ',' (ctx:VxV)
#96: FILE: include/exec/helper-ffi.h:67:
+    static ffi_cif glue(cif_,NAME) = {                                  \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#98: FILE: include/exec/helper-ffi.h:69:
+        .arg_types = glue(cif_args_,NAME),                              \
                                    ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#101: FILE: include/exec/helper-ffi.h:72:
+#define DEF_HELPER_FLAGS_5(NAME, FLAGS, ret, t1, t2, t3, t4, t5)        \
+    static ffi_type *glue(cif_args_,NAME)[5] = {                        \
+        dh_ffitype(t1), dh_ffitype(t2), dh_ffitype(t3),                 \
+        dh_ffitype(t4), dh_ffitype(t5)                                  \
+    };                                                                  \
+    static ffi_cif glue(cif_,NAME) = {                                  \
+        .rtype = dh_ffitype(ret), .nargs = 5,                           \
+        .arg_types = glue(cif_args_,NAME),                              \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#102: FILE: include/exec/helper-ffi.h:73:
+    static ffi_type *glue(cif_args_,NAME)[5] = {                        \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#102: FILE: include/exec/helper-ffi.h:73:
+    static ffi_type *glue(cif_args_,NAME)[5] = {                        \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#106: FILE: include/exec/helper-ffi.h:77:
+    static ffi_cif glue(cif_,NAME) = {                                  \

ERROR: space required after that ',' (ctx:VxV)
#106: FILE: include/exec/helper-ffi.h:77:
+    static ffi_cif glue(cif_,NAME) = {                                  \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#108: FILE: include/exec/helper-ffi.h:79:
+        .arg_types = glue(cif_args_,NAME),                              \
                                    ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#111: FILE: include/exec/helper-ffi.h:82:
+#define DEF_HELPER_FLAGS_6(NAME, FLAGS, ret, t1, t2, t3, t4, t5, t6)    \
+    static ffi_type *glue(cif_args_,NAME)[6] = {                        \
+        dh_ffitype(t1), dh_ffitype(t2), dh_ffitype(t3),                 \
+        dh_ffitype(t4), dh_ffitype(t5), dh_ffitype(t6)                  \
+    };                                                                  \
+    static ffi_cif glue(cif_,NAME) = {                                  \
+        .rtype = dh_ffitype(ret), .nargs = 6,                           \
+        .arg_types = glue(cif_args_,NAME),                              \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#112: FILE: include/exec/helper-ffi.h:83:
+    static ffi_type *glue(cif_args_,NAME)[6] = {                        \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#112: FILE: include/exec/helper-ffi.h:83:
+    static ffi_type *glue(cif_args_,NAME)[6] = {                        \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#116: FILE: include/exec/helper-ffi.h:87:
+    static ffi_cif glue(cif_,NAME) = {                                  \

ERROR: space required after that ',' (ctx:VxV)
#116: FILE: include/exec/helper-ffi.h:87:
+    static ffi_cif glue(cif_,NAME) = {                                  \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#118: FILE: include/exec/helper-ffi.h:89:
+        .arg_types = glue(cif_args_,NAME),                              \
                                    ^

ERROR: Macros with multiple statements should be enclosed in a do - while loop
#121: FILE: include/exec/helper-ffi.h:92:
+#define DEF_HELPER_FLAGS_7(NAME, FLAGS, ret, t1, t2, t3, t4, t5, t6, t7) \
+    static ffi_type *glue(cif_args_,NAME)[7] = {                        \
+        dh_ffitype(t1), dh_ffitype(t2), dh_ffitype(t3),                 \
+        dh_ffitype(t4), dh_ffitype(t5), dh_ffitype(t6), dh_ffitype(t7)  \
+    };                                                                  \
+    static ffi_cif glue(cif_,NAME) = {                                  \
+        .rtype = dh_ffitype(ret), .nargs = 7,                           \
+        .arg_types = glue(cif_args_,NAME),                              \
+    };

ERROR: spaces required around that '*' (ctx:WxV)
#122: FILE: include/exec/helper-ffi.h:93:
+    static ffi_type *glue(cif_args_,NAME)[7] = {                        \
                     ^

ERROR: space required after that ',' (ctx:VxV)
#122: FILE: include/exec/helper-ffi.h:93:
+    static ffi_type *glue(cif_args_,NAME)[7] = {                        \
                                    ^

ERROR: open brace '{' following function declarations go on the next line
#126: FILE: include/exec/helper-ffi.h:97:
+    static ffi_cif glue(cif_,NAME) = {                                  \

ERROR: space required after that ',' (ctx:VxV)
#126: FILE: include/exec/helper-ffi.h:97:
+    static ffi_cif glue(cif_,NAME) = {                                  \
                             ^

ERROR: space required after that ',' (ctx:VxV)
#128: FILE: include/exec/helper-ffi.h:99:
+        .arg_types = glue(cif_args_,NAME),                              \
                                    ^

total: 55 errors, 1 warnings, 309 lines checked

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

23/57 Checking commit 802670826cd9 (tcg/tci: Use ffi for calls)
ERROR: spaces required around that '+' (ctx:VxV)
#93: FILE: tcg/tcg.c:2085:
+        bool is_64bit = sizemask & (1 << (i+1)*2);
                                            ^

ERROR: spaces required around that '*' (ctx:VxV)
#93: FILE: tcg/tcg.c:2085:
+        bool is_64bit = sizemask & (1 << (i+1)*2);
                                               ^

ERROR: suspect code indent for conditional statements (8, 11)
#122: FILE: tcg/tcg.c:2104:
+        if (TCG_TARGET_REG_BITS < 64 && is_64bit) {
+           /*

total: 3 errors, 0 warnings, 387 lines checked

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

24/57 Checking commit 84b185592ebf (tcg/tci: Improve tcg_target_call_clobber_regs)
25/57 Checking commit b3e96e0a7c30 (tcg/tci: Move call-return regs to end of tcg_target_reg_alloc_order)
26/57 Checking commit 44e6265dd5ab (tcg/tci: Push opcode emit into each case)
27/57 Checking commit 77b7cf1601dd (tcg/tci: Split out tcg_out_op_rrs)
28/57 Checking commit afb16454253a (tcg/tci: Split out tcg_out_op_l)
29/57 Checking commit d3a59dc833f0 (tcg/tci: Split out tcg_out_op_p)
30/57 Checking commit 9a83aa346784 (tcg/tci: Split out tcg_out_op_rr)
31/57 Checking commit 707f50ff45b8 (tcg/tci: Split out tcg_out_op_rrr)
32/57 Checking commit 174921931dcd (tcg/tci: Split out tcg_out_op_rrrc)
33/57 Checking commit 3a2eb0952099 (tcg/tci: Split out tcg_out_op_rrrrrc)
34/57 Checking commit 418c425f5dc5 (tcg/tci: Split out tcg_out_op_rrrbb)
35/57 Checking commit ac3f95c7580d (tcg/tci: Split out tcg_out_op_rrcl)
36/57 Checking commit ad382a1b1c69 (tcg/tci: Split out tcg_out_op_rrrrrr)
37/57 Checking commit 6509cb6f62c2 (tcg/tci: Split out tcg_out_op_rrrr)
38/57 Checking commit c3fa67bd0da1 (tcg/tci: Split out tcg_out_op_rrrrcl)
39/57 Checking commit 1f222db773a0 (tcg/tci: Split out tcg_out_op_{rrm,rrrm,rrrrm})
40/57 Checking commit d04350cb4c07 (tcg/tci: Split out tcg_out_op_v)
41/57 Checking commit 5425edebf0c5 (tcg/tci: Split out tcg_out_op_np)
42/57 Checking commit 8c864ebd94d2 (tcg/tci: Split out tcg_out_op_r[iI])
43/57 Checking commit 1ba97dc02390 (tcg/tci: Reserve r13 for a temporary)
44/57 Checking commit cfcf8b5622ea (tcg/tci: Emit setcond before brcond)
45/57 Checking commit cb3480090c23 (tcg/tci: Remove tci_write_reg)
46/57 Checking commit fd620181ef63 (tcg/tci: Change encoding to uint32_t units)
47/57 Checking commit 6f45c0aa0bc7 (tcg/tci: Implement goto_ptr)
48/57 Checking commit 436fde1db978 (tcg/tci: Implement movcond)
49/57 Checking commit 5e91e61337e0 (tcg/tci: Implement andc, orc, eqv, nand, nor)
50/57 Checking commit 92426213bd8c (tcg/tci: Implement extract, sextract)
51/57 Checking commit 9fc40e7257b5 (tcg/tci: Implement clz, ctz, ctpop)
52/57 Checking commit d2cd749869b3 (tcg/tci: Implement mulu2, muls2)
53/57 Checking commit e346cc8ecc94 (tcg/tci: Implement add2, sub2)
54/57 Checking commit e9049ee12301 (tcg/tci: Split out tci_qemu_ld, tci_qemu_st)
55/57 Checking commit 998236542cc6 (tests/tcg: Increase timeout for TCI)
56/57 Checking commit 96812343e98b (gitlab: Rename ACCEL_CONFIGURE_OPTS to EXTRA_CONFIGURE_OPTS)
57/57 Checking commit 99c15a630909 (gitlab: Enable cross-i386 builds of TCI)
=== OUTPUT END ===

Test command exited with code: 1


The full log is available at
http://patchew.org/logs/20210311143958.562625-1-richard.henderson@linaro.org/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
Philippe Mathieu-Daudé March 17, 2021, 12:23 a.m. UTC | #2
On 3/11/21 3:39 PM, Richard Henderson wrote:
> 

> Richard Henderson (57):

>   tcg/tci: Remove ifdefs for TCG_TARGET_HAS_ext32[us]_i64

>   tcg/tci: Rename tci_read_r to tci_read_rval

>   tcg/tci: Split out tci_args_rrs

>   tcg/tci: Split out tci_args_rr

>   tcg/tci: Split out tci_args_rrr

>   tcg/tci: Split out tci_args_rrrc

>   tcg/tci: Split out tci_args_l

>   tcg/tci: Split out tci_args_rrrrrc

>   tcg/tci: Split out tci_args_rrcl and tci_args_rrrrcl

>   tcg/tci: Split out tci_args_ri and tci_args_rI

>   tcg/tci: Reuse tci_args_l for calls.

>   tcg/tci: Reuse tci_args_l for exit_tb

>   tcg/tci: Reuse tci_args_l for goto_tb

>   tcg/tci: Split out tci_args_rrrrrr

>   tcg/tci: Split out tci_args_rrrr

>   tcg/tci: Clean up deposit operations

>   tcg/tci: Reduce qemu_ld/st TCGMemOpIdx operand to 32-bits

>   tcg/tci: Split out tci_args_{rrm,rrrm,rrrrm}

>   tcg/tci: Hoist op_size checking into tci_args_*

>   tcg/tci: Remove tci_disas

>   tcg/tci: Implement the disassembler properly

>   tcg: Build ffi data structures for helpers

>   tcg/tci: Use ffi for calls

>   tcg/tci: Improve tcg_target_call_clobber_regs

>   tcg/tci: Move call-return regs to end of tcg_target_reg_alloc_order

>   tcg/tci: Push opcode emit into each case

>   tcg/tci: Split out tcg_out_op_rrs

>   tcg/tci: Split out tcg_out_op_l

>   tcg/tci: Split out tcg_out_op_p

>   tcg/tci: Split out tcg_out_op_rr

>   tcg/tci: Split out tcg_out_op_rrr

>   tcg/tci: Split out tcg_out_op_rrrc

>   tcg/tci: Split out tcg_out_op_rrrrrc

>   tcg/tci: Split out tcg_out_op_rrrbb

>   tcg/tci: Split out tcg_out_op_rrcl

>   tcg/tci: Split out tcg_out_op_rrrrrr

>   tcg/tci: Split out tcg_out_op_rrrr

>   tcg/tci: Split out tcg_out_op_rrrrcl

>   tcg/tci: Split out tcg_out_op_{rrm,rrrm,rrrrm}

>   tcg/tci: Split out tcg_out_op_v

>   tcg/tci: Split out tcg_out_op_np

>   tcg/tci: Split out tcg_out_op_r[iI]

>   tcg/tci: Reserve r13 for a temporary

>   tcg/tci: Emit setcond before brcond

>   tcg/tci: Remove tci_write_reg

>   tcg/tci: Change encoding to uint32_t units

>   tcg/tci: Implement goto_ptr

>   tcg/tci: Implement movcond

>   tcg/tci: Implement andc, orc, eqv, nand, nor

>   tcg/tci: Implement extract, sextract

>   tcg/tci: Implement clz, ctz, ctpop

>   tcg/tci: Implement mulu2, muls2

>   tcg/tci: Implement add2, sub2

>   tcg/tci: Split out tci_qemu_ld, tci_qemu_st

>   tests/tcg: Increase timeout for TCI

>   gitlab: Rename ACCEL_CONFIGURE_OPTS to EXTRA_CONFIGURE_OPTS

>   gitlab: Enable cross-i386 builds of TCI

> 

>  configure                                     |    3 +

>  meson.build                                   |    9 +-

>  include/exec/helper-ffi.h                     |  115 ++

>  include/exec/helper-tcg.h                     |   24 +-

>  include/tcg/tcg-opc.h                         |    6 +-

>  include/tcg/tcg.h                             |    1 +

>  target/hppa/helper.h                          |    2 +

>  target/i386/ops_sse_header.h                  |    6 +

>  target/m68k/helper.h                          |    1 +

>  target/ppc/helper.h                           |    3 +

>  tcg/tci/tcg-target-con-set.h                  |    2 +-

>  tcg/tci/tcg-target.h                          |   81 +-

>  disas/tci.c                                   |   61 -

>  tcg/tcg.c                                     |   88 +-

>  tcg/tci.c                                     | 1517 ++++++++++-------

>  tcg/tci/tcg-target.c.inc                      |  704 +++++---

>  .gitlab-ci.d/crossbuilds.yml                  |   21 +-

>  tcg/tci/README                                |   20 +-

>  .../dockerfiles/fedora-i386-cross.docker      |    1 +

>  tests/docker/dockerfiles/fedora.docker        |    1 +


Except the Docker part, tested running SH4 on HPPA, so:
Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>


BTW -d out_asm looks nice ;)
Philippe Mathieu-Daudé March 17, 2021, 12:41 a.m. UTC | #3
On 3/11/21 3:39 PM, Richard Henderson wrote:
> Changes since v4:

>   * 19 more patches now upstream.


I'm done for today. Hope in time so you can squeeze another
batch in 6.0.

Regards,

Phil.