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

Side by Side Diff: third_party/WebKit/Source/platform/heap/ThreadState.h

Issue 2307003002: Move collectGarbage* methods to ThreadState (Closed)
Patch Set: fix Created 4 years, 3 months 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 510 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 521
522 void resetHeapCounters(); 522 void resetHeapCounters();
523 void increaseAllocatedObjectSize(size_t); 523 void increaseAllocatedObjectSize(size_t);
524 void decreaseAllocatedObjectSize(size_t); 524 void decreaseAllocatedObjectSize(size_t);
525 void increaseMarkedObjectSize(size_t); 525 void increaseMarkedObjectSize(size_t);
526 526
527 void callThreadShutdownHooks(); 527 void callThreadShutdownHooks();
528 528
529 v8::Isolate* isolate() const { return m_isolate; } 529 v8::Isolate* isolate() const { return m_isolate; }
530 530
531 void collectGarbage(BlinkGC::StackState, BlinkGC::GCType, BlinkGC::GCReason) ;
532 void collectGarbageForTerminatingThread();
533 void collectAllGarbage();
534
531 private: 535 private:
532 enum SnapshotType { 536 enum SnapshotType {
533 HeapSnapshot, 537 HeapSnapshot,
534 FreelistSnapshot 538 FreelistSnapshot
535 }; 539 };
536 540
537 ThreadState(bool perThreadHeapEnabled); 541 ThreadState(bool perThreadHeapEnabled);
538 ~ThreadState(); 542 ~ThreadState();
539 543
540 NO_SANITIZE_ADDRESS void copyStackUntilSafePointScope(); 544 NO_SANITIZE_ADDRESS void copyStackUntilSafePointScope();
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
706 710
707 template<> class ThreadStateFor<AnyThread> { 711 template<> class ThreadStateFor<AnyThread> {
708 STATIC_ONLY(ThreadStateFor); 712 STATIC_ONLY(ThreadStateFor);
709 public: 713 public:
710 static ThreadState* state() { return ThreadState::current(); } 714 static ThreadState* state() { return ThreadState::current(); }
711 }; 715 };
712 716
713 } // namespace blink 717 } // namespace blink
714 718
715 #endif // ThreadState_h 719 #endif // ThreadState_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698