summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/ion/bug995817.js
blob: 6a4677185403564a4928b0797b54a38b7f04711e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
setJitCompilerOption('baseline.warmup.trigger', 1);
let r;
(function() {
     function f() {
         return (1 + -1 / 0) << null;
     }
     assertEq(f(), 0);
     assertEq(f(), 0);

     function g(x,y) {
         var a = x|0;
         var b = y|0;
         return (a / b + a / b) | 0;
     }
     assertEq(g(3,4), 1);
     assertEq(g(3,4), 1);
})();