[llvm-dev] Adding pragma related metadata to only one loop
Nitish Srivastava via llvm-dev
llvm-dev at lists.llvm.org
Wed Sep 13 11:23:29 PDT 2017
I wanted to assign a new pragma for loops in clang. Let's call it
"#pragma XXX" which can be applied to any loop in the entire loop
hierarchy. I added the support for my pragma by following the same steps as
were being used in the default implementation of "unroll" pragma.
But now, when I compile any program using clang to llvm IR it attaches
the pragma related metadata to the loop as well as to all the loops nested
inside it. I just want to add the metadata to that particular loop and not
all the loops nested inside it. Can someone suggest what would be the right
way of doing this? or rather what files should I look into.
So far I have made changes in the following files:
Any help would be appreciated.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev