On 8/23/23 02:39, Jordan Niethe wrote:
    +static void tcg_out_addpcis(TCGContext *s, TCGReg dst, intptr_t imm)
    +{
    +    int d0, d1, d2;
    +
    +    tcg_debug_assert((imm & 0xffff) == 0);
    +    tcg_debug_assert(imm == (int32_t)imm);
    +


I think you need imm >>= 16 here.
Without that the next patch in the series crashes.

    +    d2 = imm & 1;
    +    d1 = (imm >> 1) & 0x1f;
    +    d0 = (imm >> 6) & 0x3ff;

Yes indeed.  Silly error.  I wonder what went wrong in my testing...


r~

Reply via email to