[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v9 09/10] target-avr: updating translate.c to us
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH v9 09/10] target-avr: updating translate.c to use instructions translation |
Date: |
Tue, 5 Jul 2016 22:02:17 +0100 |
On 1 July 2016 at 15:47, Michael Rolnik <address@hidden> wrote:
> Signed-off-by: Michael Rolnik <address@hidden>
> ---
> target-avr/Makefile.objs | 4 +-
> target-avr/translate.c | 142
> ++++++++++++++++++++---------------------------
> 2 files changed, 64 insertions(+), 82 deletions(-)
>
> void restore_state_to_opc(CPUAVRState *env, TranslationBlock *tb,
> - target_ulong *data)
> + target_ulong *data)
> {
> env->pc_w = data[0];
> }
>
> void avr_cpu_dump_state(CPUState *cs, FILE *f, fprintf_function cpu_fprintf,
> - int flags)
> + int flags)
> {
> AVRCPU *cpu = AVR_CPU(cs);
> CPUAVRState *env = &cpu->env;
> + int i;
>
> cpu_fprintf(f, "\n");
> cpu_fprintf(f, "PC: %06x\n", env->pc_w);
> @@ -272,7 +252,7 @@ void avr_cpu_dump_state(CPUState *cs, FILE *f,
> fprintf_function cpu_fprintf,
> env->sregC ? 'I' : '-');
>
> cpu_fprintf(f, "\n");
> - for (int i = 0; i < ARRAY_SIZE(env->r); i++) {
> + for (i = 0; i < ARRAY_SIZE(env->r); i++) {
> cpu_fprintf(f, "R[%02d]: %02x ", i, env->r[i]);
>
> if ((i % 8) == 7) {
> @@ -281,7 +261,7 @@ void avr_cpu_dump_state(CPUState *cs, FILE *f,
> fprintf_function cpu_fprintf,
> }
>
> cpu_fprintf(f, "\n");
> - for (int i = 0; i < ARRAY_SIZE(env->io); i++) {
> + for (i = 0; i < ARRAY_SIZE(env->io); i++) {
> cpu_fprintf(f, "IO[%02d]: %02x ", i, env->io[i]);
>
> if ((i % 8) == 7) {
Later patches in the series shouldn't be randomly changing
stuff like this. Get it right in the first patch, please.
thanks
-- PMM
- [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 03/10] target-avr: adding a sample AVR board, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 01/10] target-avr: AVR cores support is added. 1. basic CPU structure 2. registers 3. no instructions 4. saving sreg, rampD, rampX, rampY, rampD, eind in HW representation saving cpu features, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 05/10] target-avr: adding AVR interrupt handling, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 02/10] target-avr: adding AVR CPU features/flavors, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 04/10] target-avr: adding instructions encodings, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 06/10] target-avr: adding helpers for IN, OUT, SLEEP, WBR & unsupported instructions, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 07/10] target-avr: adding instruction decoder, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 09/10] target-avr: updating translate.c to use instructions translation, Michael Rolnik, 2016/07/01
- Re: [Qemu-devel] [PATCH v9 09/10] target-avr: updating translate.c to use instructions translation,
Peter Maydell <=
- [Qemu-devel] [PATCH v9 10/10] target-avr: decoder generator. currently not used by the build, can be used manually, Michael Rolnik, 2016/07/01
- [Qemu-devel] [PATCH v9 08/10] target-avr: adding instruction translation, Michael Rolnik, 2016/07/01
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Richard Henderson, 2016/07/01
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Michael Rolnik, 2016/07/02
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Michael Rolnik, 2016/07/02
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Michael Rolnik, 2016/07/05
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Peter Maydell, 2016/07/05
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Michael Rolnik, 2016/07/05
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Peter Maydell, 2016/07/05
- Re: [Qemu-devel] [PATCH v9 00/10] 8bit AVR cores, Michael Rolnik, 2016/07/05