search for: initval

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

Did you mean: initial
2011 Feb 13
2
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
...0.5403023058681398 global b = 1 + 1; works fine @a = global double 0x3FE14A280FB5068C ; <double*> [#uses=0] @b = global double 2.000000e+000 ; <double*> [#uses=0] define double @0() { entry: ret double 0x3FE14A280FB5068C } The relevant code is ... Value *InitVal; InitVal = Init->Codegen(); GlobalVariable * globval = *new* *GlobalVariable*(*TheModule, InitVal->getType(), *false*, llvm::GlobalValue::*ExternalLinkage*, cast<Constant>(InitVal), Twine(GlobalName) ); Any help, as always, would be really much appreciated! Anton Skvorts 201...
2011 Feb 12
2
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
Hi Apolagize if this newbie question has some obvious answer. When running something like ... ExprAST *Init = GlobalNames[i].second; const Value *InitVal; InitVal = Init->Codegen(); GlobalVariable * globvar = new GlobalVariable(*TheModule, InitVal->getType(), false, llvm::GlobalValue::ExternalLinkage, InitVal, Twine(GlobalName)); ... I'm getting the following error error: invalid conversion from `const llvm::Value*' to `llvm::Constan...
2011 Feb 13
3
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
Oh, I thought that after "codegening" cos(0) would get me double 1.0 (assigment is working for anything like: global a = 1/3 + 2 /3 for example) What would be the best way to make assigments involving functions, like global a = cos(0); without getting the assertion arising from InitVal = cast<Constant>(Init->Codegen()); ? I made some changes and now my code basically works, except in assigments like the one above. It is a little bit frustrating because is the main thing preventing me finishing my little silly scripting language for monte carlo simulations. Value *Globa...
2011 Feb 13
0
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
Hi Anton, > But there are still some details I must be missing. I'm getting an assertion > when I try the following assignment in my script: > global c = cos(1); > Assertion failed: isa<X>(Val) && "cast<Ty>() argument of incompatible type!", I think this is telling you that cos(1) is not a constant. Ciao, Duncan.
2012 Nov 10
2
[LLVMdev] Forward references of globals in .ll files
...just not understanding the IR. Take the following IR: @a = addrspace(1) global i8 0 @a2 = global i8 addrspace(1)* @a This parses fine. But if I rearrange the statements to: @a2 = global i8 addrspace(1)* @a @a = addrspace(1) global i8 0 then I get an ugly assertion failure: Assertion failed: (InitVal->getType() == getType()->getElementType() && "Initializer type must match GlobalVariable type"), function setInitializer, file /Users/jholewinski/projects/llvm/src/llvm/lib/VMCore/Globals.cpp, line 168. Looking at the debugger, I see that InitVal (the initializer for @a2) h...
2011 Feb 12
0
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
Hi Anton, > I'm getting the following error > > error: invalid conversion from `const llvm::Value*' to `llvm::Constant*' > > How may I make this conversion? Any help would be much appreciated! cast<Constant>(whatever) Ciao, Duncan.
2012 Nov 10
0
[LLVMdev] Forward references of globals in .ll files
...> > @a = addrspace(1) global i8 0 > @a2 = global i8 addrspace(1)* @a > > This parses fine. But if I rearrange the statements to: > > @a2 = global i8 addrspace(1)* @a > @a = addrspace(1) global i8 0 > > then I get an ugly assertion failure: > > Assertion failed: (InitVal->getType() == getType()->getElementType() && > "Initializer type must match GlobalVariable type"), function setInitializer, > file /Users/jholewinski/projects/llvm/src/llvm/lib/VMCore/Globals.cpp, line > 168. > > Looking at the debugger, I see that InitVal (th...
2012 Mar 08
3
rpanel / list error
Hi All, I have created a simulation that works perfect and I have the results been returned in a list as I have multiple values. I then decided to include some user interaction by using the package rpanel, I now get the error: object of type 'builtin' is not subsettable when I attempted to have the return my list with the results . Any help needed. I can also upload code if needs be.
2023 Dec 05
3
[Bug 1726] New: invalid json generated by ipset list -output json
...er: mark at glines.org I tried to use the -output json parameter with ipset list, and found that it does not emit valid json. This is true in both the Debian Trixie package, version 7.19-1, as well as a fresh ipset build from today's git. I can see two problems with the output: 1. the "initval" field is emitted as hex, which is not a part of the json syntax [1]. 2. in combination with '-name', it seems to be printing key:value pairs in an array, not a map. I set up a test ipset as follows: --- root at gir:~# ipset list root at gir:~# ipset new test hash:ip root at gir:~# i...
2012 Nov 10
2
[LLVMdev] Forward references of globals in .ll files
...>> @a2 = global i8 addrspace(1)* @a >> >> This parses fine. But if I rearrange the statements to: >> >> @a2 = global i8 addrspace(1)* @a >> @a = addrspace(1) global i8 0 >> >> then I get an ugly assertion failure: >> >> Assertion failed: (InitVal->getType() == getType()->getElementType() && >> "Initializer type must match GlobalVariable type"), function setInitializer, >> file /Users/jholewinski/projects/llvm/src/llvm/lib/VMCore/Globals.cpp, line >> 168. >> >> Looking at the debugger, I...
2013 Mar 26
0
[LLVMdev] Fwd: Extending Kaleidoscope to support Strings
...y std::string as a Value *. I have: Value *StringExprAST::Codegen() { StringRef r(Val); // Val is a std::string captured by the parser return ConstantDataArray::getString(getGlobalContext(), r); } For a test string of "Hello World!", I am trying to create an Alloca * and store the InitVal, which I get from codegen of StringExprAST. uint64_t v(13); APInt d(8, v); Value * ArraySize = ConstantInt::get(getGlobalContext(), d); Alloca = CreateEntryBlockAllocaString(TheFunction, VarName, ArraySize); Builder.CreateStore(InitVal, Alloca); I get the following error: tok_string: "Hello...
2012 Sep 09
1
Error msg in rpanel
...: ", val),cex=1.4) panel } my.redraw <- function(panel) { rp.tkrreplot(panel, my.tkrplot) panel } my.panel <- rp.control(title = "Addition") rp.textentry(panel = my.panel, var = nmbr1, labels = "First: ", action = my.redraw, initval="100") rp.textentry(panel = my.panel, var = nmbr2, labels = "Second:", action = my.redraw, initval="200") rp.radiogroup(panel = my.panel, var = vals, values = c("numbers", "strings"), action = my.re...
2011 Feb 13
0
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
...that after "codegening" cos(0) would get me double 1.0 > (assigment is working for anything like: global a = 1/3 + 2 /3 for > example) What would be the best way to make assigments involving > functions, like global a = cos(0); > without getting the assertion arising from InitVal = > cast<Constant>(Init->Codegen()); ? the problem is that you are performing a function call (to "cos"). A function call is simply not a constant in the sense of LLVM (even if it is a constant in the sense of mathematics): it needs to be executed to work out what the return...
2011 Feb 13
1
[LLVMdev] conversion from 'const llvm::Value*' to 'llvm::Constant*'
...degening" cos(0) would get me double 1.0 > > (assigment is working for anything like: global a = 1/3 + 2 /3 for > > example)   What would be the best way to make assigments involving > > functions, like  global a = cos(0); > > without getting the assertion arising from  InitVal = > > cast<Constant>(Init->Codegen()); ? > > the problem is that you are performing a function call (to "cos").  A function > call is simply not a constant in the sense of LLVM (even if it is a constant in > the sense of mathematics): it needs to be executed to...
2003 Dec 14
1
compile error with C code and standalone R math C library
...th.so: undefined reference to `Rlog1p' collect2: ld returned 1 exit status ********************************************************************** rr-sa.c ********************************************************************** #include <stdio.h> #include <assert.h> #define T 3 #define INITVAL 1 #define MATHLIB_STANDALONE #define THETA 2 #include <Rmath.h> #include <time.h> void advance(double *node, int *current_pos, double newval); void retreat(double *node, int *current_pos); double new_val(double *node, double theta, int current_pos); double accept_prob(double *node, do...
2007 Oct 27
7
[Bug 12975] New: Bad rendering of text data extracted from XML file
http://bugs.freedesktop.org/show_bug.cgi?id=12975 Summary: Bad rendering of text data extracted from XML file Product: swfdec Version: unspecified Platform: Other OS/Version: All Status: NEW Severity: normal Priority: medium Component: library AssignedTo: swfdec at lists.freedesktop.org
2010 Oct 13
2
How to fix error in the package 'rgenoud'
Dear R user fellows, I would like to ask you about the package 'rgenoud' which is a genetic optimization tool. I ran the function 'genoud' with two variables to be minimized by the following command. result<-genoud(fn,nvars=2,starting.values=c(0.5,0), pop.size=1000, max.generations=10, wait.generations=3) Then, I had the following error message. Error in
2014 Apr 10
0
REGRESSION Re: [PATCH] drm/nouveau/bios: fix bug introduced in 457e77b2
...as per dcb git bisect bad fc243d7f92d95d961186126efaad36197f133ab1 # bad: [88e98d49a1b3e0f8103cdd4fd80d576ec33133ab] drm/gf100-/gr: split ppc state into its subunits git bisect bad 88e98d49a1b3e0f8103cdd4fd80d576ec33133ab # bad: [e21bfd171a192dfba4a8907f2fcc41acac0f685f] drm/gf110/gr: fixup gpc/tpc initvals lists git bisect bad e21bfd171a192dfba4a8907f2fcc41acac0f685f # bad: [eeb0558e074215656ae11a170059a5f2ce29963f] drm/gf104/gr: rename gf104 (nvc4), it came before gf106 (nvc3) git bisect bad eeb0558e074215656ae11a170059a5f2ce29963f # bad: [6acc09b99d5d8f276a4f9bffc32f0bb0f939c7ca] drm/nvc0-/graph:...
2013 Mar 15
22
[PATCH 00/09] arm: tools: build for arm64 and enable cross-compiling for both arm32 and arm64
The following patches shave some rough edges off the tools build system to allow cross compiling for at least arm32 and arm64 based on the Debian/Ubuntu multiarch infrastructure. They also add the necessary fixes to build for arm64 (which I have only tried cross, not native). I have posted some instructions on how to compile with these patches on the wiki:
2014 Nov 10
5
[LLVMdev] [RFC] Separating Metadata from the Value hierarchy
...static MDStringRef get(LLVMContext &Context, StringRef String); > > You have reference/pointer disagreement, I’d recommend taking LLVMContext& to the ctor for uniformity (and remove the assert). This is a workaround for `StringMapEntry`'s imperfect forwarding -- it passes the `InitVal` constructor argument by value. I'll fix the problem at its source and clean this up. > +class ReplaceableMetadataImpl { > > I’m not following your algorithm intentions well yet, but this seems like a really heavy-weight implementation, given that this is a common base class for a n...