[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] defining VIXL_DEBUG?
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] defining VIXL_DEBUG? |
Date: |
Mon, 18 Jan 2016 11:04:18 +0000 |
On 18 January 2016 at 10:57, Paolo Bonzini <address@hidden> wrote:
> One issue I have found after posting is that I'm not sure whether bad
> instructions (aka reserved encodings) are handled properly by libvixl.
> See for example this:
>
> case 'A': { // IAddSub.
> VIXL_ASSERT(instr->ShiftAddSub() <= 1);
> int64_t imm = instr->ImmAddSub() << (12 * instr->ShiftAddSub());
> AppendToOutput("#0x%" PRIx64 " (%" PRId64 ")", imm, imm);
> return 7;
> }
>
> where the '1x' encodings of bits 22:23 (marked as reserved in the ARMv8
> ARM) would cause an abort as far as I can see.
Isn't this handled by Decoder::DecodeAddSubImmediate(), which checks
bit 23?
In any case if we're worried it would be easy to set up a trivial
test loop that just feeds all 2^32 integers to the disassembler.
thanks
-- PMM