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

Side by Side Diff: src/heap.cc

Issue 414045: After performing scavenge, hint OS that data in from spaces are no more neede... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 1 month 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 | src/platform.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 775 matching lines...) Expand 10 before | Expand all | Expand 10 after
786 target->Iterate(&scavenge_visitor); 786 target->Iterate(&scavenge_visitor);
787 UpdateRSet(target); 787 UpdateRSet(target);
788 } 788 }
789 789
790 // Take another spin if there are now unswept objects in new space 790 // Take another spin if there are now unswept objects in new space
791 // (there are currently no more unswept promoted objects). 791 // (there are currently no more unswept promoted objects).
792 } while (new_space_front < new_space_.top()); 792 } while (new_space_front < new_space_.top());
793 793
794 // Set age mark. 794 // Set age mark.
795 new_space_.set_age_mark(new_space_.top()); 795 new_space_.set_age_mark(new_space_.top());
796 new_space_.ResetFromSpace();
796 797
797 // Update how much has survived scavenge. 798 // Update how much has survived scavenge.
798 survived_since_last_expansion_ += 799 survived_since_last_expansion_ +=
799 (PromotedSpaceSize() - survived_watermark) + new_space_.Size(); 800 (PromotedSpaceSize() - survived_watermark) + new_space_.Size();
800 801
801 LOG(ResourceEvent("scavenge", "end")); 802 LOG(ResourceEvent("scavenge", "end"));
802 803
803 gc_state_ = NOT_IN_GC; 804 gc_state_ = NOT_IN_GC;
804 } 805 }
805 806
(...skipping 3242 matching lines...) Expand 10 before | Expand all | Expand 10 after
4048 for (int i = 0; i < kNumberOfCaches; i++) { 4049 for (int i = 0; i < kNumberOfCaches; i++) {
4049 if (caches_[i] != NULL) { 4050 if (caches_[i] != NULL) {
4050 delete caches_[i]; 4051 delete caches_[i];
4051 caches_[i] = NULL; 4052 caches_[i] = NULL;
4052 } 4053 }
4053 } 4054 }
4054 } 4055 }
4055 4056
4056 4057
4057 } } // namespace v8::internal 4058 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/platform.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698