view graal/com.oracle.truffle.sl.test/tests/LoopPrint.sl @ 13858:6b91134526a7

Truffle: disable (most) optimistic optimizations (profile is not reliable in hosted mode)
author Andreas Woess <andreas.woess@jku.at>
date Mon, 03 Feb 2014 15:49:58 +0100
parents 64c77f0577bb
children afd6fa5e8229
line wrap: on
line source

function loop(n) {
  i = 0;  
  while (i < n) {  
    i = i + 1;  
  }  
  return i;
}  

function main() {
  println(loop(1000));  
}