[PATCH] [NVPTX] Emit .pragma "nounroll" for loops marked with nounroll

Jingyue Wu jingyue at google.com
Fri Jan 30 19:36:27 PST 2015


Hi Justin,

Do you have time to take a look at this patch?

On Fri, Jan 30, 2015 at 7:35 PM, Jingyue Wu <jingyue at google.com> wrote:

> ================
> Comment at: lib/Target/NVPTX/NVPTXAsmPrinter.cpp:426
> @@ +425,3 @@
> +// TODO(jingyue): consider "#pragma unroll 1" which is equivalent to
> "#pragma
> +// nounroll".
> +bool NVPTXAsmPrinter::isLoopHeaderOfNoUnroll(
> ----------------
> meheff wrote:
> > FYI the loop unrolling pass should replace instances of
> "llvm.loop.unroll.count 1" from "#pragma unroll 1" with
> llvm.loop.unroll.disable.
> Ack'ed.
>
> ================
> Comment at: lib/Transforms/Scalar/LoopUnrollPass.cpp:237
> @@ -236,3 +236,3 @@
>  // returned.
>  static const MDNode *GetUnrollMetadata(const Loop *L, StringRef Name) {
>    MDNode *LoopID = L->getLoopID();
> ----------------
> meheff wrote:
> > How about calling this function GetUnrollMetadataForLoop to avoid
> colliding with the new function you added?
> Done.
>
> http://reviews.llvm.org/D7041
>
> EMAIL PREFERENCES
>   http://reviews.llvm.org/settings/panel/emailpreferences/
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150130/27fe5fd0/attachment.html>


More information about the llvm-commits mailing list