OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 // arguments to be a compile time smi). | 190 // arguments to be a compile time smi). |
191 "_DateField": true, | 191 "_DateField": true, |
192 "_GetFromCache": true, | 192 "_GetFromCache": true, |
193 | 193 |
194 // This function expects its first argument to be a non-smi. | 194 // This function expects its first argument to be a non-smi. |
195 "_IsStringWrapperSafeForDefaultValueOf" : true, | 195 "_IsStringWrapperSafeForDefaultValueOf" : true, |
196 | 196 |
197 // Only applicable to strings. | 197 // Only applicable to strings. |
198 "_HasCachedArrayIndex": true, | 198 "_HasCachedArrayIndex": true, |
199 "_GetCachedArrayIndex": true, | 199 "_GetCachedArrayIndex": true, |
| 200 "_OneByteSeqStringSetChar": true, |
| 201 "_TwoByteSeqStringSetChar": true, |
200 | 202 |
201 // Only for debugging parallel recompilation. | 203 // Only for debugging parallel recompilation. |
202 "InstallRecompiledCode": true, | 204 "InstallRecompiledCode": true, |
203 "ForceParallelRecompile": true | 205 "ForceParallelRecompile": true |
204 }; | 206 }; |
205 | 207 |
206 var currentlyUncallable = { | 208 var currentlyUncallable = { |
207 // We need to find a way to test this without breaking the system. | 209 // We need to find a way to test this without breaking the system. |
208 "SystemBreak": true | 210 "SystemBreak": true |
209 }; | 211 }; |
210 | 212 |
211 function testNatives() { | 213 function testNatives() { |
212 var allNatives = %ListNatives(); | 214 var allNatives = %ListNatives(); |
213 var start = 0; | 215 var start = 0; |
214 var stop = (allNatives.length >> 2); | 216 var stop = (allNatives.length >> 2); |
215 for (var i = start; i < stop; i++) { | 217 for (var i = start; i < stop; i++) { |
216 var nativeInfo = allNatives[i]; | 218 var nativeInfo = allNatives[i]; |
217 var name = nativeInfo[0]; | 219 var name = nativeInfo[0]; |
218 if (name in knownProblems || name in currentlyUncallable) | 220 if (name in knownProblems || name in currentlyUncallable) |
219 continue; | 221 continue; |
220 print(name); | 222 print(name); |
221 var argc = nativeInfo[1]; | 223 var argc = nativeInfo[1]; |
222 testArgumentCount(name, argc); | 224 testArgumentCount(name, argc); |
223 testArgumentTypes(name, argc); | 225 testArgumentTypes(name, argc); |
224 } | 226 } |
225 } | 227 } |
226 | 228 |
227 testNatives(); | 229 testNatives(); |
OLD | NEW |