similar to: handle pragma with variable before variable declaration

Displaying 20 results from an estimated 100000 matches similar to: "handle pragma with variable before variable declaration"

2017 Sep 13
1
Adding pragma related metadata to only one loop
Hi everyone, 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
2016 Dec 12
0
[RFC] Enable "#pragma omp declare simd" in the LoopVectorizer
Hi Xinmin, I have updated the clang patch using the standard name mangling you suggested - I was not fully aware of the C++ mangling convention “_ZVG”. I am using “D” for 64-bit NEON and “Q” for 128-bit NEON, which makes NEON vector symbols look as follows: _ZVGQN2v__Z1fd _ZVGDN2v__Z1ff _ZVGQN4v__Z1ff Here “Q” means -> NEON 128-bit, “D” means -> NEON 64-bit Please notice that although
2016 Dec 08
6
[RFC] Enable "#pragma omp declare simd" in the LoopVectorizer
Hi Francesco, a bit more information. GCC veclib is implemented based on GCC VectorABI for declare simd as well. For name mangling, we have to follow certain rules of C/C++ (e.g. prefix needs to _ZVG ....). David Majnemer who is the owner and stakeholder for approval for Clang and LLVM. Also, we need to pay attention to GCC compatibility. I would suggest you look into how GCC VectorABI can
2017 Mar 14
2
[cfe-dev] proposal - pragma section directive in clang
Hi Reid, Unfortunately yes, it is. > If we do go with approach 3, I'd recommend adding a single metadata attachment that controls all sections a global could possibly live in (text, data, rdata, bss). I agree with this, although I think using metadata here wouldn't be right - don't we need to use attributes when dropping metadata would cause miscompiles? I was considering adding
2017 Mar 14
2
[cfe-dev] proposal - pragma section directive in clang
Thanks Reid/Jonathon for your replies. Reid, An important case against module level flags is that it wont allow changing or resetting section names e.g. int a; #pragma clang section bss = "xyz" int b; In case above, users would like to see only 'b' placed in 'xyz' and not 'a' as well. Link pointed to by Jonathon seems to require same behavior.
2018 Sep 20
2
Vectorization width not correct using #pragma clang loop vectorize_width
Hello, I m trying to set vector width using #pragma clang loop vectorize_width(32) but i m getting width 8 for the following kernel; #define M 128 #define N 128 #define SQRT_FUN(x) sqrtf(x) int main(int argc, char** argv) { /* Variable declaration/allocation. */ double float_n = (double)N; double data[N*M]; double corr[M*M]; double mean[M]; double stddev[M]; uint32_t
2010 Jun 02
1
[LLVMdev] Support for per-loop pragma
On Wed, Jun 2, 2010 at 11:08 AM, Junjie Gu <jgu222 at gmail.com> wrote: > Thanks for comments/suggestions. > > Yes, attaching metadata to instructions will be good choices for many > cases. But for loops, > attaching metadata to back-edges requires that the front end to build > loops, which is an > additional task for the front end. And this task is really a
2017 Mar 10
3
[cfe-dev] proposal - pragma section directive in clang
+llvm-dev properly this time. On Fri, 10 Mar 2017 at 09:42 James Molloy <james at jamesmolloy.co.uk> wrote: > Hi Reid, all, > > +llvm-dev as this RFC involves changes in Clang and LLVM. > > This RFC has stagnated and I think that's partially because the proposal > isn't particularly elegant and is light on details. We've been having a > rethink and have a
2016 Oct 25
0
[Help] Add custom pragma
> Yes. I checked that file, but I wasn't sure whether that is right one to look at. It seems promising. I imagine you'd want something like the LoopHint attr. > What is *.td extension btw? The llvm project uses that extension to identify TableGen inputs (http://llvm.org/docs/TableGen/). vedant > On Oct 25, 2016, at 4:12 PM, Sunghyun Park <sunggg at umich.edu> wrote:
2016 Oct 25
2
[Help] Add custom pragma
Hi, all. I want to give programmer ability to tell LLVM that certain region of code is expected to get specialized optimization. So, I'm trying to make custom pragma to mark certain region of code and pass this information to LLVM, in the similar way that '#pragma clang loop unroll_count(N)' works. By tracking the framework of loop unroll pragma, I found out it works in the way below.
2017 Dec 11
0
Change to r-devel warns on #pragma
Hi Patrick, It was recently added as a cran policy (thanks Dirk's cran policy watch: https://twitter.com/markvdloo/status/935810241190617088). It seems to be a general stricter policy on keeping to the C(++) standard. Warnings are there for a reason and should usually not be ignored. I'm not familiar with the warning you are suppressing but it seems likely that your code might assume
2016 Oct 25
2
[Help] Add custom pragma
Yes. I checked that file, but I wasn't sure whether that is right one to look at. What is *.td extension btw? When I google it, it says this is for Windows Debug Simulator. Why clang use this extension, which is limited to Windows environment? On Tue, Oct 25, 2016 at 7:00 PM, Vedant Kumar <vsk at apple.com> wrote: > That file is generated by the clang-tblgen tool: > >
2014 Jul 23
2
[LLVMdev] Adding custom #pragma for clang
I'd like to add a custom #pragma directive in clang for research purposes. I'm familiar with the LLVM pass-writing interface but new to the rest of LLVM and clang. I've looked into Simone Pellegrini's work on a #pragma interface (https://github.com/motonacciu/clomp and http://llvm.org/devmtg/2013-04/pellegrini-slides.pdf), but I'm in no position to determine if this approach
2012 Jul 26
1
[LLVMdev] A pragma to turn the optimizations off
On Thu, Jul 26, 2012 at 12:48 AM, Moshe Kravchik <mkravchik at hotmail.com> wrote: > > Hi, > > I'm looking for a pragma to insert in my source that will turn the > optimization off for that file. Could not find one, it is possible? > > Thanks a lot, > Moshe No, clang does not have a pragma for this. You should use your build system to pass -O0 to clang for this
2016 Dec 12
0
[RFC] Enable "#pragma omp declare simd" in the LoopVectorizer
On 12 December 2016 at 16:49, Francesco Petrogalli <Francesco.Petrogalli at arm.com> wrote: > I am not sure I understand here. In my patch, all I am doing is “vector > symbol awareness generation”. There are no globals that are generated in > the final object file, it is just the TargetLibraryInfoImpl that is being > populated with the info needed by the vectorizer. The
2017 Dec 11
2
Change to r-devel warns on #pragma
A recent change to r-devel causes an R CMD check warning when a C file includes a "#pragma GCC diagnostic ignored" pragma: https://github.com/wch/r-source/commit/b76c8fd355a0f5b23d42aaf44a879cac0fc31fa4 . This causes the CRAN checks for the "corpus" package to emit a warning: https://www.r-project.org/nosvn/R.check/r-devel-linux-x86_64-fedora-clang/corpus-00check.html .
2018 Jan 09
0
[cfe-dev] Why is #pragma STDC FENV_ACCESS not supported?
I know next to nothing about the AST, so I'll leave commentary on that to someone who does except to say that I don't believe there is a strong connection between Richard's suggestion and Hal's. An IRBuilder can be created anywhere (and is frequently used in the optimizer). When the front end support is implemented it may use an IRBuilder that leverages the state Hal is suggesting,
2010 Jun 02
0
[LLVMdev] Support for per-loop pragma
Thanks for comments/suggestions. Yes, attaching metadata to instructions will be good choices for many cases. But for loops, attaching metadata to back-edges requires that the front end to build loops, which is an additional task for the front end. And this task is really a backend's job, not the front end's. If the only concern is that it is hard for pragma intrinsics to stay with their
2018 Jan 09
0
[cfe-dev] Why is #pragma STDC FENV_ACCESS not supported?
> On Jan 9, 2018, at 11:04 AM, Kevin P. Neal via cfe-dev <cfe-dev at lists.llvm.org> wrote: > >> On 01/08/2018 07:06 PM, Richard Smith via llvm-dev wrote: >> >> On 8 January 2018 at 11:15, Kaylor, Andrew via llvm-dev >> <[1]llvm-dev at lists.llvm.org> wrote: >> >> Hi Kevin, >> Thanks for reaching out about this, and
2016 Dec 12
2
[RFC] Enable "#pragma omp declare simd" in the LoopVectorizer
)On 12 December 2016 at 13:44, Francesco Petrogalli <Francesco.Petrogalli at arm.com> wrote: > I am using “D” for 64-bit NEON and “Q” for 128-bit NEON, which makes NEON > vector symbols look as follows: > > _ZVGQN2v__Z1fd > _ZVGDN2v__Z1ff > _ZVGQN4v__Z1ff Hi Francesco, The ARM AAPCS (A.2.1) says: "For C++ the mangled name for parameters is as though the equivalent