hotspot/src/share/vm/memory/genCollectedHeap.hpp
changeset 9935 51267b5e1a3d
parent 9342 456b8d0486b5
child 9995 290620c08233
equal deleted inserted replaced
9640:f85ccaa4b680 9935:51267b5e1a3d
   214     } else {
   214     } else {
   215       return is_in(p);
   215       return is_in(p);
   216     }
   216     }
   217   }
   217   }
   218 
   218 
   219   // Returns "TRUE" iff "p" points into the youngest generation.
   219   // Returns true if the reference is to an object in the reserved space
   220   bool is_in_youngest(void* p);
   220   // for the young generation.
       
   221   // Assumes the the young gen address range is less than that of the old gen.
       
   222   bool is_in_young(oop p);
       
   223 
       
   224 #ifdef ASSERT
       
   225   virtual bool is_in_partial_collection(const void* p);
       
   226 #endif
       
   227 
       
   228   virtual bool is_scavengable(const void* addr) {
       
   229     return is_in_young((oop)addr);
       
   230   }
   221 
   231 
   222   // Iteration functions.
   232   // Iteration functions.
   223   void oop_iterate(OopClosure* cl);
   233   void oop_iterate(OopClosure* cl);
   224   void oop_iterate(MemRegion mr, OopClosure* cl);
   234   void oop_iterate(MemRegion mr, OopClosure* cl);
   225   void object_iterate(ObjectClosure* cl);
   235   void object_iterate(ObjectClosure* cl);
   281     // We wanted to assert that:-
   291     // We wanted to assert that:-
   282     // assert(UseParNewGC || UseSerialGC || UseConcMarkSweepGC,
   292     // assert(UseParNewGC || UseSerialGC || UseConcMarkSweepGC,
   283     //       "Check can_elide_initializing_store_barrier() for this collector");
   293     //       "Check can_elide_initializing_store_barrier() for this collector");
   284     // but unfortunately the flag UseSerialGC need not necessarily always
   294     // but unfortunately the flag UseSerialGC need not necessarily always
   285     // be set when DefNew+Tenured are being used.
   295     // be set when DefNew+Tenured are being used.
   286     return is_in_youngest((void*)new_obj);
   296     return is_in_young(new_obj);
   287   }
   297   }
   288 
   298 
   289   // Can a compiler elide a store barrier when it writes
   299   // Can a compiler elide a store barrier when it writes
   290   // a permanent oop into the heap?  Applies when the compiler
   300   // a permanent oop into the heap?  Applies when the compiler
   291   // is storing x to the heap, where x->is_perm() is true.
   301   // is storing x to the heap, where x->is_perm() is true.