在 2022/1/8 上午4:54, Richard Henderson 写道:
On 1/7/22 3:27 AM, Weiwei Li wrote:
+#define REQUIRE_EVEN(ctx, reg) do { \
+    if (ctx->ext_zdinx && (get_xl(ctx) == MXL_RV32) && \
+        (reg & 0x1)) { \
+        return false; \
+    } \
+} while (0)

Parenthesis around reg.

+    REQUIRE_EVEN(ctx, a->rd);
+    REQUIRE_EVEN(ctx, a->rs1);
+    REQUIRE_EVEN(ctx, a->rs2);
+    REQUIRE_EVEN(ctx, a->rs3);

I think these could all be combined:

    REQUIRE_EVEN(ctx, a->rd | a->rs1 | a->rs2 | a->rs3);
Yeah, That's true. I'll update this.

etc.

Otherwise,
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


r~


Reply via email to