[llvm-dev] RFC/bikeshedding: Separation of instruction and pattern definitions in LLVM backends
Jacques Pienaar via llvm-dev
llvm-dev at lists.llvm.org
Fri Aug 18 07:24:43 PDT 2017
The 2nd approach does seem nicer: separates concerns, makes it easier to
extend (especially important given RISC-V's modular ISA). Although, as
David said, both seem pretty clean. One thing I would add is not too worry
about the conciseness too much initially: I have been "too clever" before
when trying to write concise tablegen definitions, only to find that it
needlessly complicated making changes and made it difficult to follow.
Refactoring it to be more concise from a clear base is easier than the
opposite IMHO.
Best,
Jacques
On Fri, Aug 18, 2017 at 6:11 AM Alex Bradbury <asb at asbradbury.org> wrote:
> On 18 August 2017 at 13:02, John Leidel <john.leidel at gmail.com> wrote:
> > I agree with David's sentiment. The second method appears to be easier
> to
> > follow. IMHO, this would be easier for external users that desire to
> modify
> > the backend for their own custom extensions/instructions.
>
> Hi David and John, thanks for the feedback. I realise I didn't express
> my view in the original email - I also feel that the second approach
> works out as cleaner. As you say, it seems plausible that the
> separation will make it easier to add new custom
> extensions/instructions and we expect that to be a common activity.
> The main reason I'm sharing for wider feedback is to ensure there
> aren't further options that haven't been considered, as it's not going
> to be painful to introduce such refactorings further down the line.
>
> Best,
>
> Alex
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170818/88993406/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4847 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170818/88993406/attachment-0001.bin>
More information about the llvm-dev
mailing list