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 1836 matching lines...) Loading... |
1847 stream->Add("["); | 1847 stream->Add("["); |
1848 key()->PrintNameTo(stream); | 1848 key()->PrintNameTo(stream); |
1849 stream->Add("] "); | 1849 stream->Add("] "); |
1850 dependency()->PrintNameTo(stream); | 1850 dependency()->PrintNameTo(stream); |
1851 if (RequiresHoleCheck()) { | 1851 if (RequiresHoleCheck()) { |
1852 stream->Add(" check_hole"); | 1852 stream->Add(" check_hole"); |
1853 } | 1853 } |
1854 } | 1854 } |
1855 | 1855 |
1856 | 1856 |
1857 bool HLoadKeyedFastElement::RequiresHoleCheck() { | 1857 bool HLoadKeyedFastElement::RequiresHoleCheck() const { |
1858 if (IsFastPackedElementsKind(elements_kind())) { | 1858 if (IsFastPackedElementsKind(elements_kind())) { |
1859 return false; | 1859 return false; |
1860 } | 1860 } |
1861 | 1861 |
1862 for (HUseIterator it(uses()); !it.Done(); it.Advance()) { | 1862 for (HUseIterator it(uses()); !it.Done(); it.Advance()) { |
1863 HValue* use = it.value(); | 1863 HValue* use = it.value(); |
1864 if (!use->IsChange()) return true; | 1864 if (!use->IsChange()) return true; |
1865 } | 1865 } |
1866 | 1866 |
1867 return false; | 1867 return false; |
(...skipping 215 matching lines...) Loading... |
2083 } | 2083 } |
2084 | 2084 |
2085 | 2085 |
2086 void HLoadGlobalCell::PrintDataTo(StringStream* stream) { | 2086 void HLoadGlobalCell::PrintDataTo(StringStream* stream) { |
2087 stream->Add("[%p]", *cell()); | 2087 stream->Add("[%p]", *cell()); |
2088 if (!details_.IsDontDelete()) stream->Add(" (deleteable)"); | 2088 if (!details_.IsDontDelete()) stream->Add(" (deleteable)"); |
2089 if (details_.IsReadOnly()) stream->Add(" (read-only)"); | 2089 if (details_.IsReadOnly()) stream->Add(" (read-only)"); |
2090 } | 2090 } |
2091 | 2091 |
2092 | 2092 |
2093 bool HLoadGlobalCell::RequiresHoleCheck() { | 2093 bool HLoadGlobalCell::RequiresHoleCheck() const { |
2094 if (details_.IsDontDelete() && !details_.IsReadOnly()) return false; | 2094 if (details_.IsDontDelete() && !details_.IsReadOnly()) return false; |
2095 for (HUseIterator it(uses()); !it.Done(); it.Advance()) { | 2095 for (HUseIterator it(uses()); !it.Done(); it.Advance()) { |
2096 HValue* use = it.value(); | 2096 HValue* use = it.value(); |
2097 if (!use->IsChange()) return true; | 2097 if (!use->IsChange()) return true; |
2098 } | 2098 } |
2099 return false; | 2099 return false; |
2100 } | 2100 } |
2101 | 2101 |
2102 | 2102 |
2103 void HLoadGlobalGeneric::PrintDataTo(StringStream* stream) { | 2103 void HLoadGlobalGeneric::PrintDataTo(StringStream* stream) { |
(...skipping 523 matching lines...) Loading... |
2627 | 2627 |
2628 | 2628 |
2629 void HCheckPrototypeMaps::Verify() { | 2629 void HCheckPrototypeMaps::Verify() { |
2630 HInstruction::Verify(); | 2630 HInstruction::Verify(); |
2631 ASSERT(HasNoUses()); | 2631 ASSERT(HasNoUses()); |
2632 } | 2632 } |
2633 | 2633 |
2634 #endif | 2634 #endif |
2635 | 2635 |
2636 } } // namespace v8::internal | 2636 } } // namespace v8::internal |
OLD | NEW |