Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: test/mjsunit/math-pow.js

Issue 8817012: Fixing fix for MathPowHalf on ARM. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: . Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 128
129 assertEquals(+Infinity, 1/Math.pow(-0, 0.5)); 129 assertEquals(+Infinity, 1/Math.pow(-0, 0.5));
130 assertEquals(+Infinity, 1/Math.pow(-0, 0.6)); 130 assertEquals(+Infinity, 1/Math.pow(-0, 0.6));
131 assertEquals(-Infinity, 1/Math.pow(-0, 1)); 131 assertEquals(-Infinity, 1/Math.pow(-0, 1));
132 assertEquals(-Infinity, 1/Math.pow(-0, 10000000001)); 132 assertEquals(-Infinity, 1/Math.pow(-0, 10000000001));
133 133
134 assertEquals(+Infinity, Math.pow(-0, -0.5)); 134 assertEquals(+Infinity, Math.pow(-0, -0.5));
135 assertEquals(+Infinity, Math.pow(-0, -0.6)); 135 assertEquals(+Infinity, Math.pow(-0, -0.6));
136 assertEquals(-Infinity, Math.pow(-0, -1)); 136 assertEquals(-Infinity, Math.pow(-0, -1));
137 assertEquals(-Infinity, Math.pow(-0, -10000000001)); 137 assertEquals(-Infinity, Math.pow(-0, -10000000001));
138 138
139 assertEquals(4, Math.pow(16, 0.5)); 139 assertEquals(4, Math.pow(16, 0.5));
140 assertEquals(NaN, Math.pow(-16, 0.5)); 140 assertEquals(NaN, Math.pow(-16, 0.5));
141 assertEquals(0.25, Math.pow(16, -0.5)); 141 assertEquals(0.25, Math.pow(16, -0.5));
142 assertEquals(NaN, Math.pow(-16, -0.5)); 142 assertEquals(NaN, Math.pow(-16, -0.5));
143 143
144 // Tests from Sputnik S8.5_A13_T1. 144 // Tests from Sputnik S8.5_A13_T1.
145 assertTrue( 145 assertTrue(
146 (1*((Math.pow(2,53))-1)*(Math.pow(2,-1074))) === 4.4501477170144023e-308); 146 (1*((Math.pow(2,53))-1)*(Math.pow(2,-1074))) === 4.4501477170144023e-308);
147 assertTrue( 147 assertTrue(
148 (1*(Math.pow(2,52))*(Math.pow(2,-1074))) === 2.2250738585072014e-308); 148 (1*(Math.pow(2,52))*(Math.pow(2,-1074))) === 2.2250738585072014e-308);
149 assertTrue( 149 assertTrue(
150 (-1*(Math.pow(2,52))*(Math.pow(2,-1074))) === -2.2250738585072014e-308); 150 (-1*(Math.pow(2,52))*(Math.pow(2,-1074))) === -2.2250738585072014e-308);
151 } 151 }
152 152
153 test(); 153 test();
154 test(); 154 test();
155 %OptimizeFunctionOnNextCall(test); 155 %OptimizeFunctionOnNextCall(test);
156 test(); 156 test();
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698