Re: [fpc-pascal] generated assembler

2006-09-22 Thread Florian Klaempfl
Vincent Snijders wrote: > Florian Klaempfl schreef: >>> >>> >>> Line 17 generates two assembler instructions. Line 22 generates three >>> assembler instructions. As far as I can see both high(d) and @d[high(d)] >>> are constants, because d is a global variable. >>> >>> Is it possible that line 22 w

Re: [fpc-pascal] generated assembler

2006-09-22 Thread Vincent Snijders
Florian Klaempfl schreef: Line 17 generates two assembler instructions. Line 22 generates three assembler instructions. As far as I can see both high(d) and @d[high(d)] are constants, because d is a global variable. Is it possible that line 22 will generate 2 assembler instructions in the futu

Re: [fpc-pascal] generated assembler

2006-09-21 Thread Florian Klaempfl
Vincent Snijders wrote: > Hi, > > I am looking at some shootout benchmarks and I have the following > question. Look at the following program: > > program loop; > > {$mode objfpc} > > var > d: array[0..$FFF] of double; > di: PDouble; > i: integer; > c: double; > > begin > c := 125; >

[fpc-pascal] generated assembler

2006-09-21 Thread Vincent Snijders
Hi, I am looking at some shootout benchmarks and I have the following question. Look at the following program: program loop; {$mode objfpc} var d: array[0..$FFF] of double; di: PDouble; i: integer; c: double; begin c := 125; i := low(d); repeat d[i] := c*c; inc(i); u