Mercurial > hg > truffle
comparison src/share/vm/gc_interface/collectedHeap.inline.hpp @ 481:7d7a7c599c17
6578152: fill_region_with_object has usability and safety issues
Reviewed-by: apetrusenko, ysr
author | jcoomes |
---|---|
date | Thu, 11 Dec 2008 12:05:08 -0800 |
parents | 1ee8caae33af |
children | 0fbdb4381b99 |
comparison
equal
deleted
inserted
replaced
480:d249b360e026 | 481:7d7a7c599c17 |
---|---|
32 } | 32 } |
33 | 33 |
34 void CollectedHeap::post_allocation_setup_no_klass_install(KlassHandle klass, | 34 void CollectedHeap::post_allocation_setup_no_klass_install(KlassHandle klass, |
35 HeapWord* objPtr, | 35 HeapWord* objPtr, |
36 size_t size) { | 36 size_t size) { |
37 | |
38 oop obj = (oop)objPtr; | 37 oop obj = (oop)objPtr; |
39 | 38 |
40 assert(obj != NULL, "NULL object pointer"); | 39 assert(obj != NULL, "NULL object pointer"); |
41 if (UseBiasedLocking && (klass() != NULL)) { | 40 if (UseBiasedLocking && (klass() != NULL)) { |
42 obj->set_mark(klass->prototype_header()); | 41 obj->set_mark(klass->prototype_header()); |
43 } else { | 42 } else { |
44 // May be bootstrapping | 43 // May be bootstrapping |
45 obj->set_mark(markOopDesc::prototype()); | 44 obj->set_mark(markOopDesc::prototype()); |
46 } | 45 } |
47 | |
48 // support low memory notifications (no-op if not enabled) | |
49 LowMemoryDetector::detect_low_memory_for_collected_pools(); | |
50 } | 46 } |
51 | 47 |
52 void CollectedHeap::post_allocation_install_obj_klass(KlassHandle klass, | 48 void CollectedHeap::post_allocation_install_obj_klass(KlassHandle klass, |
53 oop obj, | 49 oop obj, |
54 int size) { | 50 int size) { |
63 "missing blueprint"); | 59 "missing blueprint"); |
64 } | 60 } |
65 | 61 |
66 // Support for jvmti and dtrace | 62 // Support for jvmti and dtrace |
67 inline void post_allocation_notify(KlassHandle klass, oop obj) { | 63 inline void post_allocation_notify(KlassHandle klass, oop obj) { |
64 // support low memory notifications (no-op if not enabled) | |
65 LowMemoryDetector::detect_low_memory_for_collected_pools(); | |
66 | |
68 // support for JVMTI VMObjectAlloc event (no-op if not enabled) | 67 // support for JVMTI VMObjectAlloc event (no-op if not enabled) |
69 JvmtiExport::vm_object_alloc_event_collector(obj); | 68 JvmtiExport::vm_object_alloc_event_collector(obj); |
70 | 69 |
71 if (DTraceAllocProbes) { | 70 if (DTraceAllocProbes) { |
72 // support for Dtrace object alloc event (no-op most of the time) | 71 // support for Dtrace object alloc event (no-op most of the time) |