< prev index next >

src/share/vm/gc/parallel/psScavenge.hpp

Print this page
rev 8362 : 8079792: GC directory structure cleanup
Reviewed-by:
   1 /*
   2  * Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_VM_GC_IMPLEMENTATION_PARALLELSCAVENGE_PSSCAVENGE_HPP
  26 #define SHARE_VM_GC_IMPLEMENTATION_PARALLELSCAVENGE_PSSCAVENGE_HPP
  27 
  28 #include "gc_implementation/parallelScavenge/cardTableExtension.hpp"
  29 #include "gc_implementation/parallelScavenge/psVirtualspace.hpp"
  30 #include "gc_implementation/shared/collectorCounters.hpp"
  31 #include "gc_implementation/shared/gcTrace.hpp"
  32 #include "memory/allocation.hpp"
  33 #include "oops/oop.hpp"
  34 #include "utilities/stack.hpp"
  35 
  36 class GCTaskManager;
  37 class GCTaskQueue;
  38 class OopStack;
  39 class ReferenceProcessor;
  40 class ParallelScavengeHeap;
  41 class ParallelScavengeTracer;
  42 class PSIsAliveClosure;
  43 class PSRefProcTaskExecutor;
  44 class STWGCTimer;
  45 
  46 class PSScavenge: AllStatic {
  47   friend class PSIsAliveClosure;
  48   friend class PSKeepAliveClosure;
  49   friend class PSPromotionManager;
  50 
  51  enum ScavengeSkippedCause {


 146 
 147   static void copy_and_push_safe_barrier_from_klass(PSPromotionManager* pm, oop* p);
 148 
 149   // Is an object in the young generation
 150   // This assumes that the 'o' is in the heap,
 151   // so it only checks one side of the complete predicate.
 152 
 153   inline static bool is_obj_in_young(oop o) {
 154     return (HeapWord*)o >= _young_generation_boundary;
 155   }
 156 
 157   inline static bool is_obj_in_young(narrowOop o) {
 158     return (uintptr_t)o >= _young_generation_boundary_compressed;
 159   }
 160 
 161   inline static bool is_obj_in_young(HeapWord* o) {
 162     return o >= _young_generation_boundary;
 163   }
 164 };
 165 
 166 #endif // SHARE_VM_GC_IMPLEMENTATION_PARALLELSCAVENGE_PSSCAVENGE_HPP
   1 /*
   2  * Copyright (c) 2002, 2015, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_VM_GC_PARALLEL_PSSCAVENGE_HPP
  26 #define SHARE_VM_GC_PARALLEL_PSSCAVENGE_HPP
  27 
  28 #include "gc/parallel/cardTableExtension.hpp"
  29 #include "gc/parallel/psVirtualspace.hpp"
  30 #include "gc/shared/collectorCounters.hpp"
  31 #include "gc/shared/gcTrace.hpp"
  32 #include "memory/allocation.hpp"
  33 #include "oops/oop.hpp"
  34 #include "utilities/stack.hpp"
  35 
  36 class GCTaskManager;
  37 class GCTaskQueue;
  38 class OopStack;
  39 class ReferenceProcessor;
  40 class ParallelScavengeHeap;
  41 class ParallelScavengeTracer;
  42 class PSIsAliveClosure;
  43 class PSRefProcTaskExecutor;
  44 class STWGCTimer;
  45 
  46 class PSScavenge: AllStatic {
  47   friend class PSIsAliveClosure;
  48   friend class PSKeepAliveClosure;
  49   friend class PSPromotionManager;
  50 
  51  enum ScavengeSkippedCause {


 146 
 147   static void copy_and_push_safe_barrier_from_klass(PSPromotionManager* pm, oop* p);
 148 
 149   // Is an object in the young generation
 150   // This assumes that the 'o' is in the heap,
 151   // so it only checks one side of the complete predicate.
 152 
 153   inline static bool is_obj_in_young(oop o) {
 154     return (HeapWord*)o >= _young_generation_boundary;
 155   }
 156 
 157   inline static bool is_obj_in_young(narrowOop o) {
 158     return (uintptr_t)o >= _young_generation_boundary_compressed;
 159   }
 160 
 161   inline static bool is_obj_in_young(HeapWord* o) {
 162     return o >= _young_generation_boundary;
 163   }
 164 };
 165 
 166 #endif // SHARE_VM_GC_PARALLEL_PSSCAVENGE_HPP
< prev index next >