search for: gvars

Displaying 20 results from an estimated 28 matches for "gvars".

Did you mean: vars
2020 Jun 03
2
Fwd: I cannot change value of global variable in LLVM IR using IRBuilder
Hi Everyone, I'm quite new to LLVM and I want to update value of global variable in LLVM IR. I created new global variable in ModulePass: bool runOnModule(llvm::Module &M) { IRBuilder<> Builder(M.getContext()); Instruction *I = &*inst_begin(M.getFunction("main")); Builder.SetInsertPoint(I); M.getOrInsertGlobal("globalKey",
2005 Aug 14
1
Panel data handling (lags, growth rates)
...ode and propose improvements. Second, it'll be great if some package-owner can adopt these orphans :-) and make them available to the R community. The two functions follow: library(Hmisc) # Am using Lag() in this. # Task: For a supplied list of variables (the list `lagvars'), # make new columns in a dataset denoting lagged values. # You must supply `unitvar' which identifies the unit that's # repeatedly observed. # You must supply the name of the time variable `timevar' # and you must tell a list of the lags that inte...
2013 Apr 07
1
[LLVMdev] How to get the Instruction where one function use the global variable.
Hi, all I try to get the Instructions where one function use the global variable. for (llvm::Module::global_iterator gvar_iter = M.global_begin(); gvar_iter != M.global_end(); gvar_iter++) { llvm::GlobalVariable *gvar = &*gvar_iter; llvm::errs() << "const global var: " << gvar->getName() << "\n"; for (
2020 Jun 03
2
Fwd: I cannot change value of global variable in LLVM IR using IRBuilder
I don't think it's the same problem as you described. By printing I meant calling printf function and passing my global variable as one of the arguments. My code: Instruction* InstructionVisitor::incrementGlobalKey(Instruction* I) { IRBuilder<> Builder(I->getContext()); Builder.SetInsertPoint(I->getNextNode()); GlobalVariable* key =
2012 Nov 09
2
[LLVMdev] [NVPTX] llc -march=nvptx64 -mcpu=sm_20 generates invalid zero align for device function params
Hi Dmitry, > I'm attaching a patch that should fix the issue mentioned above. It > simply makes the same check seen in the same file for global > variables: > > emitPTXAddressSpace(PTy->getAddressSpace(), O); > if (GVar->getAlignment() == 0) > O << " .align " << (int) TD->getPrefTypeAlignment(ETy); > else > O
2013 Mar 05
4
[LLVMdev] Convert C variable to LLVM IR Variable
Hi everyone, I am doing some work with LLVM IR, I need to use LLVM IR to do operation on C variables. Code emission is done by LLVM JIT. That variable is C thread local , for example __thread int* gvar; I think some methods to convert that variable to LLVM IR, (1) use external function I know LLVM IR is able to call an external function, so I can write codes that look like: int* load()
2012 Nov 09
0
[LLVMdev] [NVPTX] llc -march=nvptx64 -mcpu=sm_20 generates invalid zero align for device function params
Hi Duncan, You're right, global variables use preferred alignment. And - yes, preferred alignment in this case is bigger: 8 instead of 4. NVIDIA's prop. compiler gives 4. However, since CUDA 5.0 ptx modules are linkable with each other, I think alignments for externally visible functions and data should all follow ABI rules. Is there a guide on making tests? I have ~5 pending patches
2012 Nov 09
3
[LLVMdev] [NVPTX] llc -march=nvptx64 -mcpu=sm_20 generates invalid zero align for device function params
Hi Dmitry, > You're right, global variables use preferred alignment. And - yes, > preferred alignment in this case is bigger: 8 instead of 4. NVIDIA's > prop. compiler gives 4. However, since CUDA 5.0 ptx modules are > linkable with each other, I think alignments for externally visible > functions and data should all follow ABI rules. giving it an alignment of 8 does
2012 Nov 09
0
[LLVMdev] [NVPTX] llc -march=nvptx64 -mcpu=sm_20 generates invalid zero align for device function params
Test cases exist under test/CodeGen/NVPTX (name changed in May). Now that I'm back at NVIDIA, I'm going to be running through the bugzilla issues (thanks Dmitry for the reports!). I have practically the exact same patch here in my queue. :) In this case, I would prefer ABI alignment for compatibility with the vendor compiler. It should work either way, but I do need to audit the
2012 Nov 09
0
[LLVMdev] [NVPTX] llc -march=nvptx64 -mcpu=sm_20 generates invalid zero align for device function params
Dear all, I'm attaching a patch that should fix the issue mentioned above. It simply makes the same check seen in the same file for global variables: emitPTXAddressSpace(PTy->getAddressSpace(), O); if (GVar->getAlignment() == 0) O << " .align " << (int) TD->getPrefTypeAlignment(ETy); else O << " .align " <<
2011 Feb 04
1
GWAF package: lme.batch.imputed(): object 'kmat' not found
...d_release.0.fhsR.gz', pedfile='pedfile.csv', phen='phen1', covar=c('covar1','covar2'), kinmat='imputed_fhs.kinship.RData', outfile='imputed.FHS.IBC.GWAF.LME.output.0.txt' )) Gives the error messages: Error in coxme.varcheck(ncluster, varlist, n, gvars, groups, sparse, rescale, : object 'kmat' not found Error in lme.cov.out$theta : $ operator is invalid for atomic vectors Might anyone know why? Thank you for your time! Jim --------------------------------------------------- > R.Version() $platform [1] "x86_64-apple-darwin9....
2011 Jan 12
4
[LLVMdev] How to define a global variable?
Hi, I'm trying to define a mutable variable, outside functions. The code below is trying to evaluate an expression much like "x = 1" at the module level in Python. It appears that when it tries to JIT the function there is an error because there is no storage allocated for 'x'. How do I do that? thanks, Rob ----- dumped IR ----- ; ModuleID = 'repl-module' %0 =
2012 Jul 11
2
[LLVMdev] [NVPTX] llc -march=nvptx64 -mcpu=sm_20 generates invalid zero align for device function params
Hello, FYI, this is a bug http://llvm.org/bugs/show_bug.cgi?id=13324 When compiling the following code for sm_20, func params are by some reason given with .align 0, which is invalid. Problem does not occur if compiled for sm_10. > cat test.ll ; ModuleID = '__kernelgen_main_module' target datalayout = "e-p:64:64-i64:64:64-f64:64:64-n1:8:16:32:64" target triple =
2011 Apr 15
1
no solution yet, please help: extract p-value from mixed model in kinship package
...error > message******************************************** > Error message: Error in lmekin(yvar ~ mydata[, 3], data = mydata, random = ~1 | id, varlist = list(kmat))$coefficients[2, : incorrect number of dimensions In addition: Warning message: In coxme.varcheck(ncluster, varlist, n, gvars, groups, sparse, rescale, : Diagonal of variance matrix is not constant #**************************************ultimate target: to put in loop******************************* > Ultimately I want to put into the loop: > > for(i in 3:length(mydata)) { > > P <- vector (mode=&quot...
2010 May 12
2
Reading R code help--Beginner
Hi, I am brand new to R and not familiar with the language, though I have been reading the manuals and making some slow going progress. I am working with some source code from a Global Vector Auto -Regressive program written by Ranier Puhr from the R-forge group. I need help interpreting the processes of the following code. I am going to post in parts since it's pretty long: GVAR
2012 Oct 02
0
[LLVMdev] [RFC] OpenMP Representation in LLVM IR
Not to distract, but the word, `procedurization' is not an English word. It's just leaping out at me when it is either procedure(s) (noun) or proceduralize (verb). Even processes would make sense. I couldn't help myself because the word was distracting. - Marc P.S. Not that my vote counts, but I'm more in the camp of Hal whose approach to tackling the parallelization
2012 Jan 17
0
[LLVMdev] ValueMapper question: no type mapping for GlobalValue?
So it looks like the verifier doesn't catch this condition - I think it should. The attached program reproduces the problem - verification succeeds, but the linker fails with a type assertion. BTW, if no one has the bandwidth to work on this I'm willing to attempt a fix, assuming that you agree that the verifier should discover this condition. Michael Muller wrote: > >
2012 Sep 28
11
[LLVMdev] [RFC] OpenMP Representation in LLVM IR
Hi All, We'd like to make a proposal for OpenMP representation in LLVM IR. Our goal is to reach an agreement in the community on a simple, complete and extensible representation of OpenMP language constructs in LLVM IR. Hopefully, this would serve as a common ground and would enable further development of OpenMP support both in Clang and LLVM compiler toolchain. We seek feedback on the
2012 Oct 03
0
[LLVMdev] [RFC] OpenMP Representation in LLVM IR
Andrey, While I think that it will be relatively easy to have the intrinsics serve as code-motion barriers for other code that might be threads sensitive (like other external function calls), we would need to think through exactly how this would work. The easiest thing would be to make the intrinsics have having unmodeled side effects, although we might want to do something more intelligent.
2012 Jan 13
2
[LLVMdev] ValueMapper question: no type mapping for GlobalValue?
=?ISO-8859-1?Q?Rafael_=C1vila_de_Esp=EDndola?= wrote: > > I can reproduce this consistently, but only under an extremely large pile of > > code :-) I haven't tried to strip it down to minimal a test case yet, but I > > will. One salient difference with the code you've provided is that in my > > code, @a is a struct type. However, changing the example to use a