src/share/vm/memory/barrierSet.inline.hpp

changeset 1280
df6caf649ff7
parent 791
1ee8caae33af
child 1526
6aa7255741f3
equal deleted inserted replaced
1274:bb18957ad21e 1280:df6caf649ff7
21 * have any questions. 21 * have any questions.
22 * 22 *
23 */ 23 */
24 24
25 // Inline functions of BarrierSet, which de-virtualize certain 25 // Inline functions of BarrierSet, which de-virtualize certain
26 // performance-critical calls when when the barrier is the most common 26 // performance-critical calls when the barrier is the most common
27 // card-table kind. 27 // card-table kind.
28 28
29 void BarrierSet::write_ref_field_pre(void* field, oop new_val) { 29 template <class T> void BarrierSet::write_ref_field_pre(T* field, oop new_val) {
30 if (kind() == CardTableModRef) { 30 if (kind() == CardTableModRef) {
31 ((CardTableModRefBS*)this)->inline_write_ref_field_pre(field, new_val); 31 ((CardTableModRefBS*)this)->inline_write_ref_field_pre(field, new_val);
32 } else { 32 } else {
33 write_ref_field_pre_work(field, new_val); 33 write_ref_field_pre_work(field, new_val);
34 } 34 }

mercurial