[PATCH] D71065: [ARM][MVE] Add intrinsics for immediate shifts.

2019-12-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 233025. simon_tatham added a comment. Changes from previous version: - minor cleanup: removed check of `hasIntegerConstantValue` in `IRBuilderResult::more_prerequisites`, which was causing the generated codegen to perofrm a pointless call to `EmitScala

[PATCH] D71065: [ARM][MVE] Add intrinsics for immediate shifts.

2019-12-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham reopened this revision. simon_tatham added a comment. This revision is now accepted and ready to land. Reopening to review a revised version of this patch. It was reverted yesterday because of a test failure in release builds, which looks like the result of a warning fix that moved

[PATCH] D71065: [ARM][MVE] Add intrinsics for immediate shifts.

2019-12-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added subscribers: rdhindsa, hokein, echristo. simon_tatham added a comment. @hokein , @rdhindsa , @echristo : you all pointed out test failures in the previous version. Any problems I haven't spotted with this one? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D71065: [ARM][MVE] Add intrinsics for immediate shifts.

2019-12-11 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbd0f271c9e55: [ARM][MVE] Add intrinsics for immediate shifts. (reland) (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D71065?vs=233025&id=233287#toc Repository: rG LLVM

[PATCH] D71335: [ARM][MVE] Factor out an IntrinsicMX multiclass.

2019-12-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: MarkMurrayARM, miyuki. Herald added subscribers: cfe-commits, dmgreen, kristof.beyls. Herald added a project: clang. The ACLE intrinsics for MVE contain a lot of pairs of functions with `_m` and `_x` in the name, wrapping a predicat

[PATCH] D71335: [ARM][MVE] Factor out an IntrinsicMX multiclass.

2019-12-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 233297. simon_tatham added a comment. Refactored further to remove the `PredicatedImmediateVectorShift` multiclass completely: the amount of useful content remaining in it now doesn't seem to justify its existence. Repository: rG LLVM Github Monorepo

[PATCH] D71335: [ARM][MVE] Factor out an IntrinsicMX multiclass.

2019-12-11 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd290424731ed: [ARM][MVE] Factor out an IntrinsicMX multiclass. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71335/new/ https://

[PATCH] D71458: [ARM][MVE] Add intrinsics for more immediate shifts.

2019-12-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. This fills in the remaining shift operations that take a single vector inp

[PATCH] D71421: [ARM][MVE][Intrinsics] Add *_x() variants of my *_m() intrinsics.

2019-12-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham accepted this revision. simon_tatham added a comment. This revision is now accepted and ready to land. LGTM. I must admit that I probably didn't manage to take in every single detail of the revised test collection, but the shape of it looks generally nice, and everything I spot-chec

[PATCH] D71458: [ARM][MVE] Add intrinsics for more immediate shifts.

2019-12-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham marked an inline comment as done. simon_tatham added inline comments. Comment at: llvm/lib/Target/ARM/ARMInstrMVE.td:2399 + foreach pred_int = [int_arm_mve_vshll_imm_predicated] in + foreach imm = [inst_imm.immediateType] in { + simon_tatham wrote:

[PATCH] D71458: [ARM][MVE] Add intrinsics for more immediate shifts.

2019-12-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham marked an inline comment as done. simon_tatham added inline comments. Comment at: llvm/lib/Target/ARM/ARMInstrMVE.td:2399 + foreach pred_int = [int_arm_mve_vshll_imm_predicated] in + foreach imm = [inst_imm.immediateType] in { + MarkMurrayARM wrote

[PATCH] D71458: [ARM][MVE] Add intrinsics for more immediate shifts.

2019-12-13 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG25305a9311d4: [ARM][MVE] Add intrinsics for more immediate shifts. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71458/new/ http

[PATCH] D75470: [SVE] Auto-generate builtins and header for svld1.

2020-03-05 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added inline comments. Comment at: clang/include/clang/Basic/arm_sve.td:121 +// Load one vector (scalar base) +def SVLD1 : MInst<"svld1[_{2}]", "dPc", "csilUcUsUiUlhfd", [IsLoad]>; SjoerdMeijer wrote: > sdesmalen wrote: > > SjoerdMeijer wrote: > >

[PATCH] D75843: [ARM,CDE] Implement CDE feature test macros

2020-03-09 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham requested changes to this revision. simon_tatham added inline comments. This revision now requires changes to proceed. Comment at: clang/include/clang/Basic/TargetInfo.h:213 + unsigned ARMCDECorpocMask : 8; + Typo: `Corpoc` → `Coproc`. Lots of tho

[PATCH] D75843: [ARM,CDE] Implement CDE feature test macros

2020-03-09 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added inline comments. Comment at: clang/lib/Basic/Targets/ARM.cpp:492 HW_FP |= HW_FP_SP | HW_FP_HP; +} else if (Feature >= "+cdecp0" && Feature <= "+cdecp7") { + unsigned Coproc = Feature.back() - '0'; As far as I can see, feature na

[PATCH] D75850: [ARM, CDE] Generalize MVE intrinsics infrastructure to support CDE

2020-03-09 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a subscriber: sdesmalen. simon_tatham added a comment. > Renames the 'clang_arm_mve_alias' attribute into 'clang_arm_builtin_alias' > (it will be used with CDE intrinsics as well as MVE intrinsics) You might talk to @sdesmalen, who mentioned introducing an `arm_sve_alias` att

[PATCH] D75850: [ARM, CDE] Generalize MVE intrinsics infrastructure to support CDE

2020-03-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham accepted this revision. simon_tatham added a comment. This revision is now accepted and ready to land. LGTM with a couple of tiny spelling nitpicks. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:642 def err_arm_invalid_specialreg : Error<"invalid sp

[PATCH] D75997: [ARM,MVE] Fix user-namespace violation in arm_mve.h.

2020-03-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: miyuki, MarkMurrayARM, ostannard. Herald added subscribers: cfe-commits, danielkiss, dmgreen, kristof.beyls. Herald added a project: clang. We were generating the declarations of polymorphic intrinsics using `__attribute__((overload

[PATCH] D75998: [ARM,MVE] Add intrinsics and isel for MVE fused multiply-add.

2020-03-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: llvm-commits, cfe-commits, danielkiss, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. simon_tatham updated this revision to Diff 249641. simon_tatha

[PATCH] D75998: [ARM,MVE] Add intrinsics and isel for MVE fused multiply-add.

2020-03-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 249641. simon_tatham added a comment. Update test results following a last-minute correctness fix. (I updated one of the two test files but not the other.) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D759

[PATCH] D75997: [ARM,MVE] Fix user-namespace violation in arm_mve.h.

2020-03-12 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd608fee8399a: [ARM,MVE] Fix user-namespace violation in arm_mve.h. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75997/new/ http

[PATCH] D75998: [ARM,MVE] Add intrinsics and isel for MVE fused multiply-add.

2020-03-12 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3f8e714e2f9f: [ARM,MVE] Add intrinsics and isel for MVE fused multiply-add. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D75998?vs=249641&id=249896#toc Repository: rG

[PATCH] D76123: [ARM,MVE] Add intrinsics for the VQDMLAH family.

2020-03-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: cfe-commits, hiraditya, kristof.beyls. Herald added a project: clang. These are complicated integer multiply+add instructions with extra saturation, taking the hig

[PATCH] D76122: [ARM,MVE] Add intrinsics and isel for MVE integer VMLA.

2020-03-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: cfe-commits, danielkiss, hiraditya, kristof.beyls. Herald added a project: clang. These instructions compute multiply+add in integers, with one of the operands bei

[PATCH] D76122: [ARM,MVE] Add intrinsics and isel for MVE integer VMLA.

2020-03-13 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 250174. simon_tatham added a comment. Fix clang-format warnings. (Is it //really// sensible to require even //test// input files, which are often autogenerated, to be fixed points of clang-format?) Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D76122: [ARM,MVE] Add intrinsics and isel for MVE integer VMLA.

2020-03-16 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham marked an inline comment as done. simon_tatham added inline comments. Comment at: llvm/lib/Target/ARM/ARMISelLowering.cpp:14289-14292 case Intrinsic::arm_neon_vqrshifts: case Intrinsic::arm_neon_vqrshiftu: // No immediate versions of these to check for.

[PATCH] D76122: [ARM,MVE] Add intrinsics and isel for MVE integer VMLA.

2020-03-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. simon_tatham marked an inline comment as done. Closed by commit rG28c5d97beec7: [ARM,MVE] Add intrinsics and isel for MVE integer VMLA. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D76122?

[PATCH] D76123: [ARM,MVE] Add intrinsics for the VQDMLAH family.

2020-03-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG928776de9233: [ARM,MVE] Add intrinsics for the VQDMLAH family. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D76123?vs=250157&id=251032#toc Repository: rG LLVM Github

[PATCH] D76359: [ARM,MVE] Add intrinsics for the VQDMLAD family.

2020-03-18 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: cfe-commits, hiraditya, kristof.beyls. Herald added a project: clang. This is another set of instructions too complicated to be sensibly expressed in IR by anythin

[PATCH] D76359: [ARM,MVE] Add intrinsics for the VQDMLAD family.

2020-03-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGe13d153c1b59: [ARM,MVE] Add intrinsics for the VQDMLAD family. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76359/new/ https://

[PATCH] D76491: [ARM,MVE] Add ACLE intrinsics for the vaddv/vaddlv family.

2020-03-20 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: cfe-commits, danielkiss, hiraditya, kristof.beyls. Herald added a project: clang. I've implemented them as target-specific IR intrinsics rather than using `@llvm.e

[PATCH] D76490: [ARM,MVE] Add ACLE intrinsics for the vminv/vmaxv family.

2020-03-20 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: cfe-commits, hiraditya, kristof.beyls. Herald added a project: clang. I've implemented these as target-specific IR intrinsics, because they're not //quite// enough

[PATCH] D76490: [ARM,MVE] Add ACLE intrinsics for the vminv/vmaxv family.

2020-03-20 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 251626. simon_tatham added a comment. Update tests to fix CI failure (oops). Also added `opt -sroa` to make the incidental half/float argument marshalling a bit less verbose. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://re

[PATCH] D73356: [ARM,MVE] Add intrinsics for vdupq.

2020-02-03 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcf7e98e6f780: [ARM,MVE] Add intrinsics for vdupq. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73356/new/ https://reviews.llvm.

[PATCH] D73357: [ARM,MVE] Add intrinsics for v[id]dupq and v[id]wdupq.

2020-02-03 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf8d4afc49ad2: [ARM,MVE] Add intrinsics for v[id]dupq and v[id]wdupq. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D73357?vs=240207&id=242011#toc Repository: rG LLVM G

[PATCH] D73786: [ARM,MVE] Fix vreinterpretq in big-endian mode.

2020-02-03 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG961530fdc9f7: [ARM,MVE] Fix vreinterpretq in big-endian mode. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D73786?vs=241727&id=242012#toc Repository: rG LLVM Github M

[PATCH] D73906: [ARM] Make ARM::ArchExtKind use 64-bit underlying type, NFCI

2020-02-04 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. I wonder if it's worth temporarily redefining all the existing `AEK_FOO` ids to values that don't fit in 32 bits, and making sure the whole test suite still passes. That should catch any remaining cases where an integer type should have been widened. CHANGES SINC

[PATCH] D74332: [ARM,MVE] Add intrinsics for int <-> float conversion.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: cfe-commits, kristof.beyls. Herald added a project: clang. This adds the unpredicated versions of the family of vcvtq intrinsics that convert between a vector of f

[PATCH] D74334: [ARM,MVE] Add the vrev16q, vrev32q, vrev64q family.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: cfe-commits, kristof.beyls. Herald added a project: clang. These intrinsics just reorder the lanes of a vector, so the natural IR representation is as a shufflevec

[PATCH] D74333: [ARM,MVE] Add intrinsics for FP rounding operations.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. This adds the unpredicated forms of six different MVE intrinsics which all

[PATCH] D74335: [ARM,MVE] Add intrinsics vclzq and vclsq.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. vclzq maps nicely to the existing target-independent @llvm.ctlz IR intrins

[PATCH] D74331: [ARM,MVE] Add intrinsics for abs, neg and not operations.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: cfe-commits, kristof.beyls. Herald added a project: clang. This commit adds the unpredicated intrinsics for the unary operations vabsq (absolute value), vnegq (ari

[PATCH] D74336: [ARM,MVE] Add the vmovlbq,vmovltq intrinsic family.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. These intrinsics take a vector of 2n elements, and return a vector of n wi

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, miyuki, MarkMurrayARM, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. These are in some sense the inverse of vmovl[bt]q: they take a vector of n

[PATCH] D74331: [ARM,MVE] Add intrinsics for abs, neg and not operations.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243788. simon_tatham added a comment. Rebased to current master. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74331/new/ https://reviews.llvm.org/D74331 Files: clang/include/clang/Basic/arm_mve.td cl

[PATCH] D74332: [ARM,MVE] Add intrinsics for int <-> float conversion.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243789. simon_tatham added a comment. Rebased to current master. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74332/new/ https://reviews.llvm.org/D74332 Files: clang/include/clang/Basic/arm_mve.td cl

[PATCH] D74334: [ARM,MVE] Add the vrev16q, vrev32q, vrev64q family.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243791. simon_tatham added a comment. Rebased to current master. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74334/new/ https://reviews.llvm.org/D74334 Files: clang/include/clang/Basic/arm_mve.td cl

[PATCH] D74336: [ARM,MVE] Add the vmovlbq,vmovltq intrinsic family.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243793. simon_tatham added a comment. Spotted a mistake by myself: one of my new isel patterns was generating signed VMOVL where it should have been generating unsigned. Fixed, and updated the llc test that had the wrong expectation in it. Also rebased

[PATCH] D74333: [ARM,MVE] Add intrinsics for FP rounding operations.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243790. simon_tatham added a comment. Rebased to current master. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74333/new/ https://reviews.llvm.org/D74333 Files: clang/include/clang/Basic/arm_mve.td cl

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243794. simon_tatham added a comment. Rebased on top of fixes to previous patches in the stack. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74337/new/ https://reviews.llvm.org/D74337 Files: clang/incl

[PATCH] D74335: [ARM,MVE] Add intrinsics vclzq and vclsq.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 243792. simon_tatham added a comment. Spotted a mistake by myself: I had accidentally implemented the `vclsq` intrinsics for unsigned integer types as well as signed. ACLE only defines them for signed integers. Also rebased to current master. Reposit

[PATCH] D74333: [ARM,MVE] Add intrinsics for FP rounding operations.

2020-02-11 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. In D74333#1869788 , @miyuki wrote: > vrintx is not mentioned anywhere in the patch. Should it say "llvm.rint" > instead? No, I meant what I said: `vrintx` is the MVE machine instruction that `llvm.rint` already instruction

[PATCH] D74336: [ARM,MVE] Add the vmovlbq,vmovltq intrinsic family.

2020-02-12 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 244104. simon_tatham added a comment. Cosmetic tweak: don't put the new `arm_mve.td` section in between the definition and the uses of an unrelated multiclass. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-12 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 244105. simon_tatham added a comment. Cosmetic tweak: don't put the new `arm_mve.td` section in between the definition and the uses of an unrelated multiclass. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D74336: [ARM,MVE] Add the vmovlbq,vmovltq intrinsic family.

2020-02-17 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 244969. simon_tatham added a comment. Made the new isel patterns work in big-endian as well as little. Depends on the extra preparatory patch D74716 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-17 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 244970. simon_tatham added a comment. Added tests to make sure the isel rules work in both big- and little-endian. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74337/new/ https://reviews.llvm.org/D74337

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-17 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham marked an inline comment as done. simon_tatham added inline comments. Comment at: clang/test/CodeGen/arm-mve-intrinsics/vmovn.c:10 +// CHECK-NEXT:[[TMP0:%.*]] = shufflevector <16 x i8> [[A:%.*]], <16 x i8> undef, <16 x i32> +// CHECK-NEXT:[[TMP1:%.*]] = bit

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-17 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 244984. simon_tatham added a comment. Test on the clang side in both endiannesses. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74337/new/ https://reviews.llvm.org/D74337 Files: clang/include/clang/Bas

[PATCH] D74331: [ARM,MVE] Add intrinsics for abs, neg and not operations.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG90dc78bc6278: [ARM,MVE] Add intrinsics for abs, neg and not operations. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74331/new/

[PATCH] D74334: [ARM,MVE] Add the vrev16q, vrev32q, vrev64q family.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGb6236e94799e: [ARM,MVE] Add the vrev16q, vrev32q, vrev64q family. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74334/new/ https

[PATCH] D74332: [ARM,MVE] Add intrinsics for int <-> float conversion.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdf3ed6c0fe31: [ARM,MVE] Add intrinsics for int <-> float conversion. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74332/new/ ht

[PATCH] D74335: [ARM,MVE] Add intrinsics vclzq and vclsq.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG68b49f7ef49e: [ARM,MVE] Add intrinsics vclzq and vclsq. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74335/new/ https://reviews

[PATCH] D74333: [ARM,MVE] Add intrinsics for FP rounding operations.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc8b3196e5430: [ARM,MVE] Add intrinsics for FP rounding operations. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74333/new/ http

[PATCH] D74337: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc32af4447f79: [ARM,MVE] Add the vmovnbq,vmovntq intrinsic family. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74337/new/ https

[PATCH] D74336: [ARM,MVE] Add the vmovlbq,vmovltq intrinsic family.

2020-02-18 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG5e97940cd279: [ARM,MVE] Add the vmovlbq,vmovltq intrinsic family. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74336/new/ https

[PATCH] D67160: [clang, ARM] Default to -fno-lax-vector-conversions in ARM v8.1-M.

2020-01-16 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham abandoned this revision. simon_tatham added a comment. I ended up solving this problem a completely different way, in D72518 . Instead of controlling the behavior I need based on the target architecture, I made it depend on a type attribute on the v

[PATCH] D72830: [ARM][MVE][Intrinsics] Take abs() of VMINNMAQ, VMAXNMAQ intrinsics' first arguments.

2020-01-16 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham accepted this revision. simon_tatham added a comment. This revision is now accepted and ready to land. Hmm. Somewhere in the back of my head is a worry that we may miss an optimization opportunity in cases such as `max(a, abs(b))` where value-range analysis tells us that `a` is know

[PATCH] D72934: [ARM,MVE] Support immediate vbicq,vorrq,vmvnq intrinsics.

2020-01-17 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. Immediate vmvnq is code-generated as a simple vector constant in IR, and l

[PATCH] D72984: [TableGen] Use a table to lookup MVE intrinsic names

2020-01-20 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham accepted this revision. simon_tatham added a comment. This revision is now accepted and ready to land. LGTM, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72984/new/ https://reviews.llvm.org/D72984 __

[PATCH] D72934: [ARM,MVE] Support immediate vbicq,vorrq,vmvnq intrinsics.

2020-01-20 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham marked 2 inline comments as done. simon_tatham added a comment. In D72934#1829331 , @dmgreen wrote: > What is the reason that this can't be lowered in tablegen, in the same way as > the VMOVimm's are? In NEON, immediate VBIC is represented

[PATCH] D72934: [ARM,MVE] Support immediate vbicq,vorrq,vmvnq intrinsics.

2020-01-22 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 239609. simon_tatham marked an inline comment as done. simon_tatham edited the summary of this revision. simon_tatham added a comment. I've revised the MC representations of VBIC and VORR as suggested, but that was a big enough patch that I've done it se

[PATCH] D72934: [ARM,MVE] Support immediate vbicq,vorrq,vmvnq intrinsics.

2020-01-23 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4321c6af28e9: [ARM,MVE] Support immediate vbicq,vorrq,vmvnq intrinsics. (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72934/new/

[PATCH] D73268: [ARM,MVE] Make the MVE intrinsics work in C++!

2020-01-23 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: LukeGeeson, MarkMurrayARM, miyuki, dmgreen. Herald added subscribers: cfe-commits, kristof.beyls. Herald added a project: clang. Apparently nobody has tried this in months of development. It turns out that `FunctionDecl::getBuiltinI

[PATCH] D73268: [ARM,MVE] Make the MVE intrinsics work in C++!

2020-01-23 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG98ea4b30c2c4: [ARM,MVE] Make the MVE intrinsics work in C++! (authored by simon_tatham). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73268/new/ https://re

[PATCH] D73356: [ARM,MVE] Add intrinsics for vdupq.

2020-01-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. The unpredicated case of this is trivial: the clang codegen just makes a v

[PATCH] D73357: [ARM,MVE] Add intrinsics for v[id]dupq and v[id]wdupq.

2020-01-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. These instructions generate a vector of consecutive elements starting from

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-27 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: aaron.ballman, lebedev.ri. Herald added a project: clang. Herald added a subscriber: cfe-commits. The 'z' length modifier, signalling that an integer format specifier takes a `size_t` sized integer, is only supported by the C librar

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-27 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham marked an inline comment as done. simon_tatham added inline comments. Comment at: clang/lib/AST/FormatString.cpp:754 + LO.isMSCompatibilityVersionSpecified() && + !LO.isCompatibleWithMSVC(LangOptions::MSVC2015)) { +// The standard libraries

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-27 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 240626. simon_tatham added a comment. Removed the special case for `MSCompatibilityVersion == 0`. If the default compatibility setting needs to be changed, that's a separate piece of work and should be done by someone who understands more than I do abou

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-28 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGfe0d1b6a8ac5: [Clang] Warn about 'z' printf modifier in old MSVC. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D73457?vs=240626&id=240796#toc Repository: rG LLVM Gith

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-28 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. In D73457#1842605 , @amccarth wrote: > clang will still (by default) use the MS runtime libraries for Windows > builds, in which case it's important for the compatibility version to match > the one for the libraries that are

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-28 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. I wanted this to go in because I'm actually using it – pre-2015 C libraries are useful to link against if you need an application to run on very old versions of Windows, and that means you need the compiler to warn you if you do something those libraries don't supp

[PATCH] D73457: [Clang] Warn about 'z' printf modifier in old MSVC.

2020-01-29 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. I now realise that my previous comment was nonsense: looking at @thakis's link more carefully, there are actually 5 failing tests that are nothing to do with the one I modified, and a lot of them don't even have any obvious `-fms-extension` option in the cc1 comman

[PATCH] D73786: [ARM,MVE] Fix vreinterpretq in big-endian mode.

2020-01-31 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: dmgreen, MarkMurrayARM, miyuki, ostannard. Herald added subscribers: llvm-commits, cfe-commits, hiraditya, kristof.beyls. Herald added projects: clang, LLVM. In big-endian MVE, the simple vector load/store instructions (i.e. both co

[PATCH] D35295: [docs] Add section 'Half-Precision Floating Point'

2017-11-02 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added inline comments. Comment at: docs/LanguageExtensions.rst:462 +``__fp16`` is a ARM C-Language Extension (ACLE) and ``_Float16`` is defined by +the C standards committee, which should help portability between entire +architectures. Also, ``_Float16`` arithmetic a

[PATCH] D35295: [docs] Add section 'Half-Precision Floating Point'

2017-11-02 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham accepted this revision. simon_tatham added a comment. This revision is now accepted and ready to land. LGTM now, thanks! (But other reviewers may still want to comment.) https://reviews.llvm.org/D35295 ___ cfe-commits mailing list cfe-c

[PATCH] D145567: [Driver] Rename multilib flags to tags

2023-03-09 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. But it was useful to have it separate at least for review purposes, since it made it much easier when Michael asked me to proofread the change from 'flags' to 'tags'! Comment at: clang/docs/Multilib.rst:66 ``--target=armv7m-none-eabi`` are eq

[PATCH] D145567: [Driver] Rename multilib flags to tags

2023-03-09 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added inline comments. Comment at: clang/docs/Multilib.rst:71 + arguments into a standard set of simpler "tags". In many cases these tags will look like a command line argument with the leading ``-`` stripped off, + but where a suitable form for the tag doesn

[PATCH] D145781: [AArch64] Don't #define __ARM_FP when there's no FPU.

2023-03-10 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: lenary, tmatheson, DavidSpickett, efriedma. Herald added a subscriber: kristof.beyls. Herald added a project: All. simon_tatham requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits.

[PATCH] D145781: [AArch64] Don't #define __ARM_FP when there's no FPU.

2023-03-13 Thread Simon Tatham via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG5fba4c4d08bd: [AArch64] Don't #define __ARM_FP when there's no FPU. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/

[PATCH] D153292: [Driver][BareMetal] Error if no matching multilib

2023-06-20 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham accepted this revision. simon_tatham added a comment. This revision is now accepted and ready to land. LGTM. One of the thoughts I mentioned offline before this patch was written was that maybe the error would need to be conditional, via a directive inside `multilib.yaml` itself –

[PATCH] D153885: [Clang][Driver] Change missing multilib error to warning

2023-06-27 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added inline comments. Comment at: clang/include/clang/Basic/DiagnosticDriverKinds.td:740 -def err_drv_no_matching_multilib : Error< - "no multilib found matching flags: %0">; +def warn_drv_no_matching_multilib : Warning< + "no multilib found matching flags: %0">

[PATCH] D154043: [CodeGen] -fsanitize={function, kcfi}: ensure align 4 if +strict-align

2023-06-29 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. The details of this approach look good to me, but is this the best place to solve it? Doing it in clang means that //every// language front end that wants to use either of these sanitizers is responsible for doing this same work: tagging every IR function with `ali

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham created this revision. simon_tatham added reviewers: peter.smith, MaskRay, dmgreen. Herald added a subscriber: kristof.beyls. Herald added a project: All. simon_tatham requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Function po

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. I think this began going wrong as a result of D148573 , which enabled `-fsanitize=function` on all targets, where previously it hadn't been running on Arm at all. But I'd rather make it work than turn it off again! Repository:

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 525065. simon_tatham added a comment. (oops, forgot to clang-format) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151308/new/ https://reviews.llvm.org/D151308 Files: clang/lib/CodeGen/CGExpr.cpp clan

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 525084. simon_tatham added a comment. How embarrassing. _Really_ upload the clang-formatted version this time. Sorry for the noise. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151308/new/ https://review

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-24 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham updated this revision to Diff 525111. simon_tatham added a comment. Clarify mask construction as @michaelplatings suggested. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151308/new/ https://reviews.llvm.org/D151308 Files: clang/lib

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-25 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added a comment. > `-fsanitize=kcfi` only supports aarch64 and x86-64 now. riscv64 is on the > plan. > > % fclang -fsanitize=kcfi --traget=armv7-linux-gnueabi -c a.c > clang: error: unsupported option '--traget=armv7-linux-gnueabi' Sorry to contradict, but that error message onl

[PATCH] D151308: -fsanitize=function: fix alignment fault on Arm targets.

2023-05-25 Thread Simon Tatham via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG20d6dee40d50: -fsanitize=function: fix alignment fault on Arm targets. (authored by simon_tatham). Changed prior to commit: https://reviews.llvm.org/D151308?vs=525111&id=525479#toc Repository: rG LLV

<    1   2   3   4   >