search for: getlower

Displaying 11 results from an estimated 11 matches for "getlower".

Did you mean: getlexer
2011 Jun 22
2
[LLVMdev] ConstantRange::sub
Sure. I will submit a patch. BTW, what's the difference between the bounds I was expecting APInt NewLower = getLower() - Other.getUpper() + 1; APInt NewUpper = getUpper() - Other.getLower(); and the two you mentioned NewLower = Lower - (Upper-1) NewUpper = (Upper-1) - Lower + 1 They look equivalent to me. Did I miss anything? Thanks. - xi On Jun 22, 2011, at 2:39 PM, Nick Lewycky wrote: > Thanks, I thi...
2011 Jun 21
2
[LLVMdev] ConstantRange::sub
Hi, I have a question about ConstantRange::sub(const ConstantRange &Other) at lib/Support/ConstantRange.cpp:524. The code computes the new bounds as follows. APInt NewLower = getLower() - Other.getLower(); APInt NewUpper = getUpper() - Other.getUpper() + 1; Could someone explain this to me? I was expecting something like APInt NewLower = getLower() - Other.getUpper() + 1; APInt NewUpper = getUpper() - Other.getLower(); Thanks. - xi
2011 Jun 22
0
[LLVMdev] ConstantRange::sub
On 22 June 2011 12:51, Xi Wang <xi.wang at gmail.com> wrote: > Sure. I will submit a patch. > > BTW, what's the difference between the bounds I was expecting > > APInt NewLower = getLower() - Other.getUpper() + 1; > APInt NewUpper = getUpper() - Other.getLower(); > > and the two you mentioned > > NewLower = Lower - (Upper-1) > NewUpper = (Upper-1) - Lower + 1 > > They look equivalent to me. Did I miss anything? Thanks. > ... they are. Sorry, I was just...
2011 Jun 22
0
[LLVMdev] ConstantRange::sub
...add the test. On 20 June 2011 23:09, Xi Wang <xi.wang at gmail.com> wrote: > Hi, > > I have a question about ConstantRange::sub(const ConstantRange &Other) at > lib/Support/ConstantRange.cpp:524. The code computes the new bounds as > follows. > > APInt NewLower = getLower() - Other.getLower(); > APInt NewUpper = getUpper() - Other.getUpper() + 1; > > Could someone explain this to me? I was expecting something like > > APInt NewLower = getLower() - Other.getUpper() + 1; > APInt NewUpper = getUpper() - Other.getLower(); > These aren't qui...
2017 Aug 07
2
vrp
...> for (Instruction &I : BB) { > if (Value* v = dyn_cast<Value>(&I)) > if (v->getType()->isIntegerTy()) { > ConstantRange r = LV.getConstantRange(v, &BB, &I); > I.dump(); > printf("LOWER VALUE : %llu\n",r.getLower().getRawData()); > printf("UPPER VALUE : %llu\n",r.getUpper().getRawData()); > } > } About your other question, "the value range pass was not able to determine any size, even of the induction variable, is it a correct behavior?". Yes, returning a co...
2017 Aug 07
2
vrp
...t;> > if (Value* v = dyn_cast<Value>(&I)) >> > if (v->getType()->isIntegerTy()) { >> > ConstantRange r = LV.getConstantRange(v, &BB, &I); >> > I.dump(); >> > printf("LOWER VALUE : %llu\n",r.getLower().getRawData()); >> > printf("UPPER VALUE : %llu\n",r.getUpper().getRawData()); >> > } >> > } >> >> About your other question, "the value range pass was not able to >> determine any size, even of the induction variable,...
2017 Aug 07
2
vrp
Hello, I am trying to figure out, what vrp propagation does in llvm. I tried this program: #include <stdio.h> int main() { int s = 0; int j = 0; for (int i = 0; i < 100; i++) { j = j+i+1; s+=j; } return (s+j); } And got this under optimized version ( I don't want everything to be eliminated) define i32 @main()
2012 Jun 24
2
[LLVMdev] Problems building LLVM under Visual Studio
Hi all, I'm trying to build LLVM, synced from SVN trunk yesterday. I ran CMake and it generated VS 2008 project files, so far so good.  Then I tried to build them, by building the ALL_BUILD project. It got the first three all right, but choked on template issues in LLVMCore: 1>------ Build started: Project: LLVMCore, Configuration: Debug Win32 ------ 1>Compiling... 1>Verifier.cpp
2013 Jul 11
1
[LLVMdev] Scalar Evolution and Loop Trip Count.
...r of the range is the last possible loop // value. Also note that we already checked for a full range. APInt One(BitWidth,1); APInt A = cast<SCEVConstant>(getOperand(1))->getValue()->getValue(); APInt End = A.sge(One) ? (Range.getUpper() - One) : Range.getLower(); // The exit value should be (End+A)/A. APInt ExitVal = (End + A).udiv(A); ConstantInt *ExitValue = ConstantInt::get(SE.getContext(), ExitVal); In gdb, $6 = {BitWidth = 8, {VAL = 254, pVal = 0xfe}} (gdb) p ExitVal.isNegative() $7 = true (gdb) p ExitValue->dump() i8 -2 $8...
2009 Apr 20
0
New versions for the distr-family of packages
------------------------------------------------------------------------------- New versions released for the distr family of package ------------------------------------------------------------------------------- We would like to announce the availability on CRAN (with possibly a minor delay until on every mirror) of new versions of our packages in the "distr"-family (version 2.1),
2009 Apr 20
0
New versions for the distr-family of packages
------------------------------------------------------------------------------- New versions released for the distr family of package ------------------------------------------------------------------------------- We would like to announce the availability on CRAN (with possibly a minor delay until on every mirror) of new versions of our packages in the "distr"-family (version 2.1),