On Fri, Mar 30, 2012 at 7:42 PM, Richard Henderson <r...@twiddle.net> wrote: > On 03/29/2012 11:17 PM, Jia Liu wrote: >> This is MIPS ASE DSP instructions support for QEMU. These instructions >> are grouped according to "Chapter 4. MIPS DSP ASE Instruction Summary" >> in MIPS ASE DSP manual [1]. >> >> [1] MIPS32® Architecture for Programmers VolumeIV-e: The MIPS® DSP >> Application-Specific Extension to the MIPS32®Architecture >> >> http://www.mips.com/products/product-materials/processor/mips-architecture/ > > Any plans to support the mips64 version? > > It also occurred to me to actually try this code, which shows you haven't > thought about mips64 at all. Configure with --enable-debug: >
I planed when mips32dsp is OK, I'll working on mips64dsp, so I'm not think about mips64 too much yet. > >> CC mips64-softmmu/translate.o >> /home/rth/work/qemu/qemu/target-mips/translate.c: In function >> 'gen_compute_branch': >> /home/rth/work/qemu/qemu/target-mips/translate.c:2989:9: error: incompatible >> type for argument 1 of 'tcg_gen_andi_i32' >> /home/rth/work/qemu/qemu/tcg/tcg-op.h:521:20: note: expected 'TCGv_i32' but >> argument is of type 'TCGv_i64' >> /home/rth/work/qemu/qemu/target-mips/translate.c:2989:9: error: incompatible >> type for argument 2 of 'tcg_gen_andi_i32' >> /home/rth/work/qemu/qemu/tcg/tcg-op.h:521:20: note: expected 'TCGv_i32' but >> argument is of type 'TCGv_i64' > > > All of your helpers, whereever they receive or return a register value, need > to use > type target_ulong and the DEF_HELPER lines need to use "tl". All of the > mips32 > helpers you've written so far that return values need to make sure to > sign-extend > their results from 32-bits. I'll check the return values. And, do you mean replace all "i32" "int" in DEF_HELPER with "tl", all "uint32_t" "int" in dsp_hlper.c with "target_ulong"? > > With that, the compilation errors should go away, and you should produce > correct > results for the subset of the mips64 dsp ase that overlaps with the mips32 > dsp ase. > Thanks, I'll make sure the subset of the mips64dsp that overlaps with the mips32dsp get correct results. > > r~ Regards, Jia.