| 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 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 HType type = CalculateInferredType(); | 407 HType type = CalculateInferredType(); |
| 408 bool result = (!type.Equals(type_)); | 408 bool result = (!type.Equals(type_)); |
| 409 type_ = type; | 409 type_ = type; |
| 410 return result; | 410 return result; |
| 411 } | 411 } |
| 412 | 412 |
| 413 | 413 |
| 414 void HValue::RegisterUse(int index, HValue* new_value) { | 414 void HValue::RegisterUse(int index, HValue* new_value) { |
| 415 HValue* old_value = OperandAt(index); | 415 HValue* old_value = OperandAt(index); |
| 416 if (old_value == new_value) return; | 416 if (old_value == new_value) return; |
| 417 if (old_value != NULL) { | 417 if (old_value != NULL && old_value->uses_.Contains(this)) { |
| 418 ASSERT(old_value->uses_.Contains(this)); | |
| 419 old_value->uses_.RemoveElement(this); | 418 old_value->uses_.RemoveElement(this); |
| 420 } | 419 } |
| 421 if (new_value != NULL) { | 420 if (new_value != NULL) { |
| 422 new_value->uses_.Add(this); | 421 new_value->uses_.Add(this); |
| 423 } | 422 } |
| 424 } | 423 } |
| 425 | 424 |
| 426 | 425 |
| 427 void HValue::AddNewRange(Range* r) { | 426 void HValue::AddNewRange(Range* r) { |
| 428 if (!HasRange()) ComputeInitialRange(); | 427 if (!HasRange()) ComputeInitialRange(); |
| (...skipping 1081 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1510 | 1509 |
| 1511 | 1510 |
| 1512 void HCheckPrototypeMaps::Verify() { | 1511 void HCheckPrototypeMaps::Verify() { |
| 1513 HInstruction::Verify(); | 1512 HInstruction::Verify(); |
| 1514 ASSERT(HasNoUses()); | 1513 ASSERT(HasNoUses()); |
| 1515 } | 1514 } |
| 1516 | 1515 |
| 1517 #endif | 1516 #endif |
| 1518 | 1517 |
| 1519 } } // namespace v8::internal | 1518 } } // namespace v8::internal |
| OLD | NEW |