Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(275)

Side by Side Diff: src/hydrogen.cc

Issue 104313003: Remove unnecessary overflow check in BuildCreateAllocationMemento. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: comment fix. Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 2574 matching lines...) Expand 10 before | Expand all | Expand 10 after
2585 Add<HStoreNamedField>( 2585 Add<HStoreNamedField>(
2586 allocation_memento, 2586 allocation_memento,
2587 HObjectAccess::ForAllocationMementoSite(), 2587 HObjectAccess::ForAllocationMementoSite(),
2588 allocation_site); 2588 allocation_site);
2589 if (FLAG_allocation_site_pretenuring) { 2589 if (FLAG_allocation_site_pretenuring) {
2590 HValue* memento_create_count = Add<HLoadNamedField>( 2590 HValue* memento_create_count = Add<HLoadNamedField>(
2591 allocation_site, HObjectAccess::ForAllocationSiteOffset( 2591 allocation_site, HObjectAccess::ForAllocationSiteOffset(
2592 AllocationSite::kMementoCreateCountOffset)); 2592 AllocationSite::kMementoCreateCountOffset));
2593 memento_create_count = AddUncasted<HAdd>( 2593 memento_create_count = AddUncasted<HAdd>(
2594 memento_create_count, graph()->GetConstant1()); 2594 memento_create_count, graph()->GetConstant1());
2595 // This smi value is reset to zero after every gc, overflow isn't a problem
2596 // since the counter is bounded by the new space size.
2597 memento_create_count->ClearFlag(HValue::kCanOverflow);
2595 HStoreNamedField* store = Add<HStoreNamedField>( 2598 HStoreNamedField* store = Add<HStoreNamedField>(
2596 allocation_site, HObjectAccess::ForAllocationSiteOffset( 2599 allocation_site, HObjectAccess::ForAllocationSiteOffset(
2597 AllocationSite::kMementoCreateCountOffset), memento_create_count); 2600 AllocationSite::kMementoCreateCountOffset), memento_create_count);
2598 // No write barrier needed to store a smi. 2601 // No write barrier needed to store a smi.
2599 store->SkipWriteBarrier(); 2602 store->SkipWriteBarrier();
2600 } 2603 }
2601 } 2604 }
2602 2605
2603 2606
2604 HInstruction* HGraphBuilder::BuildGetNativeContext() { 2607 HInstruction* HGraphBuilder::BuildGetNativeContext() {
(...skipping 8203 matching lines...) Expand 10 before | Expand all | Expand 10 after
10808 if (ShouldProduceTraceOutput()) { 10811 if (ShouldProduceTraceOutput()) {
10809 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); 10812 isolate()->GetHTracer()->TraceHydrogen(name(), graph_);
10810 } 10813 }
10811 10814
10812 #ifdef DEBUG 10815 #ifdef DEBUG
10813 graph_->Verify(false); // No full verify. 10816 graph_->Verify(false); // No full verify.
10814 #endif 10817 #endif
10815 } 10818 }
10816 10819
10817 } } // namespace v8::internal 10820 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698