[PATCH] AArch64 Neon Scalar Integer Compare Instructions

Tim Northover t.p.northover at gmail.com
Thu Oct 10 12:48:45 PDT 2013


Hi Chad,

I'm going to be away for the next week, but will try to reply to
anything you send tomorrow morning before going out of contact.

>   : Pat<(v1i64 (opnode (v1i64 VPR64:$Rn), (v1i64 (bitconvert (v8i8
> (Neon_movi (i32 0), (i32 timm)))))))

I think you are nearly there, you *should* be able to write something like:

def : Pat<(v1i64 (opnode (v1i64 VPR64:$Rn), (v1i64 (bitconvert (v8i8
(Neon_movi (i32 0), (i32 14))))))),
    (INSTD VPR64:$Rn, 0)>;

(Probably with a comment that a whole-vector constant 0 currently
makes its way through codegen as such a MOVIMM (actually, I'd suggest
a PatFrag or a PatLeaf to abstract it once you've got the basic
outline working in one example)),

The only problem I see there is that one of the NEON_MOVIMM operands
is a Constant and the other is a TargetConstant. Frankly, that's dodgy
anyway. I'd change them both to Constants -- you may need to update
the patterns for the real MOVI instruction so that they can cope with
this.

Hopefully that'll work. As I say, I'll be around briefly tomorrow and
should be able to take another stab at it if not.

Cheers.

Tim.



More information about the llvm-commits mailing list