1 # Copyright 2013 the V8 project authors. All rights reserved. 2 # Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 3 # 4 # Redistribution and use in source and binary forms, with or without 5 # modification, are permitted provided that the following conditions 6 # are met: 7 # 1. Redistributions of source code must retain the above copyright 8 # notice, this list of conditions and the following disclaimer. 9 # 2. Redistributions in binary form must reproduce the above copyright 10 # notice, this list of conditions and the following disclaimer in the 11 # documentation and/or other materials provided with the distribution. 12 # 13 # THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY 14 # EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 15 # WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 16 # DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY 17 # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 18 # (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 19 # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON 20 # ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 22 # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 24 Tests what happens in the DFG JIT if we load from a Float32 array that contains a weirdly formatted NaN. 25 26 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". 27 28 29 -4587521 30 NaN 31 PASS "" + foo(floatView) is "NaN" 32 NaN 33 PASS "" + foo(floatView) is "NaN" 34 NaN 35 PASS "" + foo(floatView) is "NaN" 36 NaN 37 PASS "" + foo(floatView) is "NaN" 38 NaN 39 PASS "" + foo(floatView) is "NaN" 40 NaN 41 PASS "" + foo(floatView) is "NaN" 42 NaN 43 PASS "" + foo(floatView) is "NaN" 44 NaN 45 PASS "" + foo(floatView) is "NaN" 46 NaN 47 PASS "" + foo(floatView) is "NaN" 48 NaN 49 PASS "" + foo(floatView) is "NaN" 50 NaN 51 PASS "" + foo(floatView) is "NaN" 52 NaN 53 PASS "" + foo(floatView) is "NaN" 54 NaN 55 PASS "" + foo(floatView) is "NaN" 56 NaN 57 PASS "" + foo(floatView) is "NaN" 58 NaN 59 PASS "" + foo(floatView) is "NaN" 60 NaN 61 PASS "" + foo(floatView) is "NaN" 62 NaN 63 PASS "" + foo(floatView) is "NaN" 64 NaN 65 PASS "" + foo(floatView) is "NaN" 66 NaN 67 PASS "" + foo(floatView) is "NaN" 68 NaN 69 PASS "" + foo(floatView) is "NaN" 70 NaN 71 PASS "" + foo(floatView) is "NaN" 72 NaN 73 PASS "" + foo(floatView) is "NaN" 74 NaN 75 PASS "" + foo(floatView) is "NaN" 76 NaN 77 PASS "" + foo(floatView) is "NaN" 78 NaN 79 PASS "" + foo(floatView) is "NaN" 80 NaN 81 PASS "" + foo(floatView) is "NaN" 82 NaN 83 PASS "" + foo(floatView) is "NaN" 84 NaN 85 PASS "" + foo(floatView) is "NaN" 86 NaN 87 PASS "" + foo(floatView) is "NaN" 88 NaN 89 PASS "" + foo(floatView) is "NaN" 90 NaN 91 PASS "" + foo(floatView) is "NaN" 92 NaN 93 PASS "" + foo(floatView) is "NaN" 94 NaN 95 PASS "" + foo(floatView) is "NaN" 96 NaN 97 PASS "" + foo(floatView) is "NaN" 98 NaN 99 PASS "" + foo(floatView) is "NaN" 100 NaN 101 PASS "" + foo(floatView) is "NaN" 102 NaN 103 PASS "" + foo(floatView) is "NaN" 104 NaN 105 PASS "" + foo(floatView) is "NaN" 106 NaN 107 PASS "" + foo(floatView) is "NaN" 108 NaN 109 PASS "" + foo(floatView) is "NaN" 110 NaN 111 PASS "" + foo(floatView) is "NaN" 112 NaN 113 PASS "" + foo(floatView) is "NaN" 114 NaN 115 PASS "" + foo(floatView) is "NaN" 116 NaN 117 PASS "" + foo(floatView) is "NaN" 118 NaN 119 PASS "" + foo(floatView) is "NaN" 120 NaN 121 PASS "" + foo(floatView) is "NaN" 122 NaN 123 PASS "" + foo(floatView) is "NaN" 124 NaN 125 PASS "" + foo(floatView) is "NaN" 126 NaN 127 PASS "" + foo(floatView) is "NaN" 128 NaN 129 PASS "" + foo(floatView) is "NaN" 130 NaN 131 PASS "" + foo(floatView) is "NaN" 132 NaN 133 PASS "" + foo(floatView) is "NaN" 134 NaN 135 PASS "" + foo(floatView) is "NaN" 136 NaN 137 PASS "" + foo(floatView) is "NaN" 138 NaN 139 PASS "" + foo(floatView) is "NaN" 140 NaN 141 PASS "" + foo(floatView) is "NaN" 142 NaN 143 PASS "" + foo(floatView) is "NaN" 144 NaN 145 PASS "" + foo(floatView) is "NaN" 146 NaN 147 PASS "" + foo(floatView) is "NaN" 148 NaN 149 PASS "" + foo(floatView) is "NaN" 150 NaN 151 PASS "" + foo(floatView) is "NaN" 152 NaN 153 PASS "" + foo(floatView) is "NaN" 154 NaN 155 PASS "" + foo(floatView) is "NaN" 156 NaN 157 PASS "" + foo(floatView) is "NaN" 158 NaN 159 PASS "" + foo(floatView) is "NaN" 160 NaN 161 PASS "" + foo(floatView) is "NaN" 162 NaN 163 PASS "" + foo(floatView) is "NaN" 164 NaN 165 PASS "" + foo(floatView) is "NaN" 166 NaN 167 PASS "" + foo(floatView) is "NaN" 168 NaN 169 PASS "" + foo(floatView) is "NaN" 170 NaN 171 PASS "" + foo(floatView) is "NaN" 172 NaN 173 PASS "" + foo(floatView) is "NaN" 174 NaN 175 PASS "" + foo(floatView) is "NaN" 176 NaN 177 PASS "" + foo(floatView) is "NaN" 178 NaN 179 PASS "" + foo(floatView) is "NaN" 180 NaN 181 PASS "" + foo(floatView) is "NaN" 182 NaN 183 PASS "" + foo(floatView) is "NaN" 184 NaN 185 PASS "" + foo(floatView) is "NaN" 186 NaN 187 PASS "" + foo(floatView) is "NaN" 188 NaN 189 PASS "" + foo(floatView) is "NaN" 190 NaN 191 PASS "" + foo(floatView) is "NaN" 192 NaN 193 PASS "" + foo(floatView) is "NaN" 194 NaN 195 PASS "" + foo(floatView) is "NaN" 196 NaN 197 PASS "" + foo(floatView) is "NaN" 198 NaN 199 PASS "" + foo(floatView) is "NaN" 200 NaN 201 PASS "" + foo(floatView) is "NaN" 202 NaN 203 PASS "" + foo(floatView) is "NaN" 204 NaN 205 PASS "" + foo(floatView) is "NaN" 206 NaN 207 PASS "" + foo(floatView) is "NaN" 208 NaN 209 PASS "" + foo(floatView) is "NaN" 210 NaN 211 PASS "" + foo(floatView) is "NaN" 212 NaN 213 PASS "" + foo(floatView) is "NaN" 214 NaN 215 PASS "" + foo(floatView) is "NaN" 216 NaN 217 PASS "" + foo(floatView) is "NaN" 218 NaN 219 PASS "" + foo(floatView) is "NaN" 220 NaN 221 PASS "" + foo(floatView) is "NaN" 222 NaN 223 PASS "" + foo(floatView) is "NaN" 224 NaN 225 PASS "" + foo(floatView) is "NaN" 226 NaN 227 PASS "" + foo(floatView) is "NaN" 228 NaN 229 PASS "" + foo(floatView) is "NaN" 230 I didn't crash, which is a good thing. 231 PASS successfullyParsed is true 232 233 TEST COMPLETE 234 235