search for: upperbound

Displaying 20 results from an estimated 26 matches for "upperbound".

2012 Nov 26
2
[LLVMdev] RFC: change BoundsChecking.cpp to use address-based tests
...╴╴╴╴╴╴╴╴┡━━━━━━━┩╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶╶ │ │ │ │ Cmp1: Offset ≥ 0 (unless constant) │ │ Cmp2: Size ≥ Offset ┆ ┆ Cmp3: ObjSize ≥ NeededSize I am looking at generating IR like this: %upperbound = getelementptr inbounds i64* %memobj, i64 %elements %end = getelementptr inbounds i64* %ptr, i64 1 %ilowerbound = ptrtoint i64* %memobj to i64 %iupperbound = ptrtoint i64* %upperbound to i64 %iptr = ptrtoint i64* %ptr to i64 %iend = ptrtoint i64* %end to i64 %cmpl = icmp ult %iptr, %...
2012 Nov 26
0
[LLVMdev] RFC: change BoundsChecking.cpp to use address-based tests
...fer) - ptr points to the last few bytes of the address space (with a large offset, but starting in bounds) - the information read/written is large and therefore there's an overflow in the memory addresses that are accessed. In this case, you'll have ptr > lowerbound and end < upperbound. The bad part is that end < ptr. I thought a bit on the subject and I couldn't find any solution with just 2 branches. The exception I found is if the size of an allocated object is always smaller than half of the address space (which seems a reasonable assumption to me, but I didn'...
2018 May 03
4
adding overall constraint in optim()
....vector(tail(head(mo,i),1)) wgt.vect <- as.vector(tail(head(moWeightsMax,i),1)) cov.mat <- cov(tail(head(morets,i+12),12)) opt.fun <- function(wgt.vect) -sum(Mo.vect %*% wgt.vect) / (t(wgt.vect) %*% (cov.mat %*% wgt.vect)) LowerBounds<-c(0.2,0.05,0.1,0,0,0) UpperBounds<-c(0.6,0.3,0.6,0.15,0.1,0.2) OptimSolution<-optim(wgt.vect, fn=opt.fun, method="L-BFGS-B",lower=LowerBounds,upper=UpperBounds) Any thoughts are appreciated! Mike Michael Ashton, CFA Managing Principal Enduring Investments LLC W: 973.457.4602 C: 551.655.8006 [[alternat...
2012 Feb 27
2
[LLVMdev] How to unroll loop with non-constant boundary
...nt lower bound, second with usual non-constant lower bound: >> >>     int main(int argc, char ** argv) >>     { >>         int numOfIterations= 1; >>         int stride=1; >>         int lowerBound = 1000; - 1st | int lowerBound = argc; - 2nd >>         int upperBound = lowerBound + (numOfIterations - 1)*stride; >> >>         int i = lowerBound; >> >>         int s = 0; >>         while(i <= upperBound) >>         { >>            s += i; >>            i++; >>         } >>         return s; >>  ...
2012 Feb 27
3
[LLVMdev] How to unroll loop with non-constant boundary
...Consider two loops with one interation - First with constant lower bound, second with usual non-constant lower bound: int main(int argc, char ** argv) { int numOfIterations= 1; int stride=1; int lowerBound = 1000; - 1st | int lowerBound = argc; - 2nd int upperBound = lowerBound + (numOfIterations - 1)*stride; int i = lowerBound; int s = 0; while(i <= upperBound) { s += i; i++; } return s; } After the application of -O3 optimization: The first loop was unrolled: defin...
2012 Dec 04
2
[LLVMdev] RFC: change BoundsChecking.cpp to use address-based tests
...the last few bytes of the address space (with a large > offset, but starting in bounds) > - the information read/written is large and therefore there's an > overflow in the memory addresses that are accessed. > > In this case, you'll have ptr > lowerbound and end < upperbound. The bad > part is that end < ptr. > > > I thought a bit on the subject and I couldn't find any solution with > just 2 branches. > The exception I found is if the size of an allocated object is always > smaller than half of the address space (which seems a reasonable &gt...
2012 Feb 27
0
[LLVMdev] How to unroll loop with non-constant boundary
...sual non-constant lower bound: >>> >>> int main(int argc, char ** argv) >>> { >>> int numOfIterations= 1; >>> int stride=1; >>> int lowerBound = 1000; - 1st | int lowerBound = argc; - 2nd >>> int upperBound = lowerBound + (numOfIterations - 1)*stride; >>> >>> int i = lowerBound; >>> >>> int s = 0; >>> while(i <= upperBound) >>> { >>> s += i; >>> i++; >>> }...
2012 Feb 27
0
[LLVMdev] How to unroll loop with non-constant boundary
...First with constant lower bound, second with usual non-constant lower bound: > > int main(int argc, char ** argv) > { > int numOfIterations= 1; > int stride=1; > int lowerBound = 1000; - 1st | int lowerBound = argc; - 2nd > int upperBound = lowerBound + (numOfIterations - 1)*stride; > > int i = lowerBound; > > int s = 0; > while(i <= upperBound) > { > s += i; > i++; > } > return s; > } > After the application of -O3...
2018 May 03
0
adding overall constraint in optim()
...gt; wgt.vect <- as.vector(tail(head(moWeightsMax,i),1)) > cov.mat <- cov(tail(head(morets,i+12),12)) > opt.fun <- function(wgt.vect) -sum(Mo.vect %*% wgt.vect) / (t(wgt.vect) %*% (cov.mat %*% wgt.vect)) > > LowerBounds<-c(0.2,0.05,0.1,0,0,0) > UpperBounds<-c(0.6,0.3,0.6,0.15,0.1,0.2) > > OptimSolution<-optim(wgt.vect, fn=opt.fun, method="L-BFGS-B",lower=LowerBounds,upper=UpperBounds) > > > Any thoughts are appreciated! > > Mike > > Michael Ashton, CFA > Managing Principal > > Enduring Investm...
2018 May 03
2
adding overall constraint in optim()
...<- as.vector(tail(head(moWeightsMax,i),1)) >> cov.mat <- cov(tail(head(morets,i+12),12)) >> opt.fun <- function(wgt.vect) -sum(Mo.vect %*% wgt.vect) / (t(wgt.vect) %*% (cov.mat %*% wgt.vect)) >> >> LowerBounds<-c(0.2,0.05,0.1,0,0,0) >> UpperBounds<-c(0.6,0.3,0.6,0.15,0.1,0.2) >> >> OptimSolution<-optim(wgt.vect, fn=opt.fun, method="L-BFGS-B",lower=LowerBounds,upper=UpperBounds) >> >> >> Any thoughts are appreciated! >> >> Mike >> >> Michael Ashton, CFA >> M...
2018 May 04
0
adding overall constraint in optim()
...il(head(moWeightsMax,i),1)) >>> cov.mat <- cov(tail(head(morets,i+12),12)) >>> opt.fun <- function(wgt.vect) -sum(Mo.vect %*% wgt.vect) / (t(wgt.vect) %*% (cov.mat %*% wgt.vect)) >>> >>> LowerBounds<-c(0.2,0.05,0.1,0,0,0) >>> UpperBounds<-c(0.6,0.3,0.6,0.15,0.1,0.2) >>> >>> OptimSolution<-optim(wgt.vect, fn=opt.fun, method="L-BFGS-B",lower=LowerBounds,upper=UpperBounds) >>> >>> >>> Any thoughts are appreciated! >>> >>> Mike >>> >>>...
2018 May 06
1
adding overall constraint in optim()
...t; >>> cov.mat <- cov(tail(head(morets,i+12),12)) > >>> opt.fun <- function(wgt.vect) -sum(Mo.vect %*% wgt.vect) / > (t(wgt.vect) %*% (cov.mat %*% wgt.vect)) > >>> > >>> LowerBounds<-c(0.2,0.05,0.1,0,0,0) > >>> UpperBounds<-c(0.6,0.3,0.6,0.15,0.1,0.2) > >>> > >>> OptimSolution<-optim(wgt.vect, fn=opt.fun, method="L-BFGS-B",lower= > LowerBounds,upper=UpperBounds) > >>> > >>> > >>> Any thoughts are appreciated! > >>> > &g...
2018 Nov 01
4
Fwd: RFC: Adding debug information to LLVM to support Fortran
...ndices from 1 to 10 for the rows and 2 to 11 for the columns. TYPE(t) :: array(10,2:11) For this declaration, the compiler generates the following LLVM metadata. !100 = !DIFortranArrayType(baseType: !7, elements: !101) !101 = !{ !102, !103 } !102 = !DIFortranSubrange(constLowerBound: 1, constUpperBound: 10) !103 = !DIFortranSubrange(constLowerBound: 2, constUpperBound: 11) The DWARF generated for this is as follows. (DWARF asserts in the standard that arrays are interpreted as column-major.) DW_TAG_array_type: DW_AT_name: array DW_AT_type: 4d08 ;TYPE(t) DW_...
2018 May 05
1
adding overall constraint in optim()
Hi, You can use the projectLinear argument in BB::spg to optimize with linear equality/inequality constraints. Here is how you implement the constraint that all parameters sum to 1. require(BB) spg(par=p0, fn=myFn, project="projectLinear", projectArgs=list(A=matrix(1, 1, length(p0)), b=1, meq=1)) Hope this is helpful, Ravi [[alternative HTML version deleted]]
2018 Nov 01
2
RFC: Adding debug information to LLVM to support Fortran
...ng LLVM metadata. !100 = !DIFortranArrayType(baseType: !7, elements: !101) Since the DI* hierarchy really just is the DWARF type hierarchy, I don't think we will need to introduce any fortran-specific names for arrays. !101 = !{ !102, !103 } !102 = !DIFortranSubrange(constLowerBound: 1, constUpperBound: 10) !103 = !DIFortranSubrange(constLowerBound: 2, constUpperBound: 11) The DWARF generated for this is as follows. (DWARF asserts in the standard that arrays are interpreted as column-major.) DW_TAG_array_type: DW_AT_name: array DW_AT_type: 4d08 ;TYPE(t) DW_TAG_sub...
2016 Apr 09
0
[FORGED] Generating random data with non-linear correlation between two variables
...data set is linear whereas non-linear (e.g., polynomial) with another. However, the distributions of the v1 and v2 should not be other than normal or slightly positively skewed or slightly negatively skewed. In Oracle, random data is generated with packaged function dbms_random.value(lowerbound, upperbound), which can be called from SQL query with where clause (level <= no_of_rows) for the number of rows you want. After the rows are generated, we can write custom functions to spread the data points along the y-axis, so that they wouldn't overlap. I hope this may clear the use case further....
2016 Apr 09
1
[FORGED] Generating random data with non-linear correlation between two variables
...is linear whereas non-linear (e.g., polynomial) with another. However, the distributions of the v1 and v2 should not be other than normal or slightly positively skewed or slightly negatively skewed. > > In Oracle, random data is generated with packaged function dbms_random.value(lowerbound, upperbound), which can be called from SQL query with where clause (level <= no_of_rows) for the number of rows you want. > > After the rows are generated, we can write custom functions to spread the data points along the y-axis, so that they wouldn't overlap. > > I hope this may clear th...
2010 May 18
0
[LLVMdev] suggestion: add a member in llvm::CodeMetrics
Is it worthwhile to add a void analyzeInstRange(InstIter begin, InstIter end) {} which estimate code metrics of any instruction range in a basic block. Or we are good with analyzeBasicBlock as an upperbound? thanks yuanfang
2012 Dec 04
0
[LLVMdev] RFC: change BoundsChecking.cpp to use address-based tests
Hi, > Could you provide a bit of background of the expected domains of Size and > Offset? In particular, are they signed or unsigned integers? A > non-negative size doesn't seem to make much sense in this context, but > depending on how it's calculated I could see it arising. Is a zero Size > something that might arise here? I'm assuming the Offset comes from an
2016 Apr 09
3
[FORGED] Generating random data with non-linear correlation between two variables
Please specify your goal in the oracle/psql analytical functions you know or specify what you mean by nonlinear correlation Sent from my iPhone > On Apr 9, 2016, at 6:09 AM, Muhammad Bilal <Muhammad2.Bilal at live.uwe.ac.uk> wrote: > > No its not. I am doing all these experiments for my own learning purpose. I am Oracle SQL & PLSQL programmer and I can do these things