Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Matheus K. Ferst
On 30/04/2021 15:43, Richard Henderson wrote: On 4/30/21 11:02 AM, Matheus K. Ferst wrote: But in this case ADDI probably doesn't use PLS_D. You could use static bool trans_PADDI(DisasContext *ctx, arg_PLS_D *a) { arg_D d; if (!resolve_PLS_D(ctx, , a)) { return false; } return

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Richard Henderson
On 4/30/21 1:32 PM, Luis Fernando Fujita Pires wrote: From: Richard Henderson On 4/30/21 11:45 AM, Luis Fernando Fujita Pires wrote: I think we can already pass multiple files to decodetree.py and it will handle them correctly. I just didn't find a way to do that from the meson build files,

RE: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Luis Fernando Fujita Pires
From: Richard Henderson > On 4/30/21 11:45 AM, Luis Fernando Fujita Pires wrote: > > I think we can already pass multiple files to decodetree.py and it will > > handle > them correctly. I just didn't find a way to do that from the meson build > files, > which assume decodetree will always use a

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Richard Henderson
On 4/30/21 11:45 AM, Luis Fernando Fujita Pires wrote: I think we can already pass multiple files to decodetree.py and it will handle them correctly. I just didn't find a way to do that from the meson build files, which assume decodetree will always use a single input file. Oh, riscv does

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Richard Henderson
On 4/30/21 11:02 AM, Matheus K. Ferst wrote: But in this case ADDI probably doesn't use PLS_D.  You could use static bool trans_PADDI(DisasContext *ctx, arg_PLS_D *a) { arg_D d; if (!resolve_PLS_D(ctx, , a)) { return false; } return trans_ADDI(ctx, ); } making sure

RE: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Luis Fernando Fujita Pires
From: Richard Henderson > On 4/30/21 4:23 AM, Luis Fernando Fujita Pires wrote: > > I think we should reconsider using the same .decode file for both 32- > > and 64-bit instructions, to avoid duplicating argument set > > definitions, and to keep the prefixed instructions close to their > >

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Matheus K. Ferst
On 30/04/2021 11:31, Richard Henderson wrote: On 4/30/21 7:05 AM, Matheus K. Ferst wrote: +ADDI    01 10 0--.-- .. \ +    001110 . . @PLS_D I'm not sure about this. It's a bit surprising to find ADDI here, and the

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Richard Henderson
On 4/30/21 7:05 AM, Matheus K. Ferst wrote: +ADDI    01 10 0--.-- .. \ +    001110 . . @PLS_D I'm not sure about this. It's a bit surprising to find ADDI here, and the comment that explains why is likely to be ignored

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Richard Henderson
On 4/30/21 4:23 AM, Luis Fernando Fujita Pires wrote: I think we should reconsider using the same .decode file for both 32- and 64-bit instructions, to avoid duplicating argument set definitions, and to keep the prefixed instructions close to their non-prefixed counterparts. varinsnwidth assumes

Re: [PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-30 Thread Matheus K. Ferst
On 29/04/2021 22:15, Richard Henderson wrote: Signed-off-by: Richard Henderson --- target/ppc/insn32.decode | 12 +++ target/ppc/insn64.decode | 15 + target/ppc/translate.c | 29

[PATCH v3 25/30] target/ppc: Move ADDI, ADDIS to decodetree, implement PADDI

2021-04-29 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/ppc/insn32.decode | 12 +++ target/ppc/insn64.decode | 15 + target/ppc/translate.c | 29 target/ppc/translate/fixedpoint-impl.c.inc | 39 ++ 4