OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 1321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1332 : new Range(); | 1332 : new Range(); |
1333 result->Shl(c->Integer32Value()); | 1333 result->Shl(c->Integer32Value()); |
1334 result->set_can_be_minus_zero(false); | 1334 result->set_can_be_minus_zero(false); |
1335 return result; | 1335 return result; |
1336 } | 1336 } |
1337 } | 1337 } |
1338 return HValue::InferRange(); | 1338 return HValue::InferRange(); |
1339 } | 1339 } |
1340 | 1340 |
1341 | 1341 |
| 1342 Range* HLoadKeyedSpecializedArrayElement::InferRange() { |
| 1343 switch (elements_kind()) { |
| 1344 case EXTERNAL_PIXEL_ELEMENTS: |
| 1345 return new Range(0, 255); |
| 1346 case EXTERNAL_BYTE_ELEMENTS: |
| 1347 return new Range(-128, 127); |
| 1348 case EXTERNAL_UNSIGNED_BYTE_ELEMENTS: |
| 1349 return new Range(0, 255); |
| 1350 case EXTERNAL_SHORT_ELEMENTS: |
| 1351 return new Range(-32768, 32767); |
| 1352 case EXTERNAL_UNSIGNED_SHORT_ELEMENTS: |
| 1353 return new Range(0, 65535); |
| 1354 default: |
| 1355 return HValue::InferRange(); |
| 1356 } |
| 1357 } |
| 1358 |
1342 | 1359 |
1343 void HCompareGeneric::PrintDataTo(StringStream* stream) { | 1360 void HCompareGeneric::PrintDataTo(StringStream* stream) { |
1344 stream->Add(Token::Name(token())); | 1361 stream->Add(Token::Name(token())); |
1345 stream->Add(" "); | 1362 stream->Add(" "); |
1346 HBinaryOperation::PrintDataTo(stream); | 1363 HBinaryOperation::PrintDataTo(stream); |
1347 } | 1364 } |
1348 | 1365 |
1349 | 1366 |
1350 void HStringCompareAndBranch::PrintDataTo(StringStream* stream) { | 1367 void HStringCompareAndBranch::PrintDataTo(StringStream* stream) { |
1351 stream->Add(Token::Name(token())); | 1368 stream->Add(Token::Name(token())); |
(...skipping 777 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2129 | 2146 |
2130 | 2147 |
2131 void HCheckPrototypeMaps::Verify() { | 2148 void HCheckPrototypeMaps::Verify() { |
2132 HInstruction::Verify(); | 2149 HInstruction::Verify(); |
2133 ASSERT(HasNoUses()); | 2150 ASSERT(HasNoUses()); |
2134 } | 2151 } |
2135 | 2152 |
2136 #endif | 2153 #endif |
2137 | 2154 |
2138 } } // namespace v8::internal | 2155 } } // namespace v8::internal |
OLD | NEW |