hotspot/src/share/vm/oops/constantPoolKlass.hpp
Print this page
rev 611 : Merge
*** 1,10 ****
#ifdef USE_PRAGMA_IDENT_HDR
#pragma ident "@(#)constantPoolKlass.hpp 1.51 07/05/29 09:44:18 JVM"
#endif
/*
! * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
--- 1,10 ----
#ifdef USE_PRAGMA_IDENT_HDR
#pragma ident "@(#)constantPoolKlass.hpp 1.51 07/05/29 09:44:18 JVM"
#endif
/*
! * Copyright 1997-2008 Sun Microsystems, Inc. All Rights Reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*** 25,35 ****
*
*/
// A constantPoolKlass is the klass of a constantPoolOop
! class constantPoolKlass : public arrayKlass {
public:
// Dispatched klass operations
bool oop_is_constantPool() const { return true; }
int oop_size(oop obj) const;
int klass_oop_size() const { return object_size(); }
--- 25,36 ----
*
*/
// A constantPoolKlass is the klass of a constantPoolOop
! class constantPoolKlass : public Klass {
! juint _alloc_size; // allocation profiling support
public:
// Dispatched klass operations
bool oop_is_constantPool() const { return true; }
int oop_size(oop obj) const;
int klass_oop_size() const { return object_size(); }
*** 45,55 ****
return (constantPoolKlass*) k->klass_part();
}
// Sizing
static int header_size() { return oopDesc::header_size() + sizeof(constantPoolKlass)/HeapWordSize; }
! int object_size() const { return arrayKlass::object_size(header_size()); }
// Garbage collection
void oop_follow_contents(oop obj);
int oop_adjust_pointers(oop obj);
--- 46,56 ----
return (constantPoolKlass*) k->klass_part();
}
// Sizing
static int header_size() { return oopDesc::header_size() + sizeof(constantPoolKlass)/HeapWordSize; }
! int object_size() const { return align_object_size(header_size()); }
// Garbage collection
void oop_follow_contents(oop obj);
int oop_adjust_pointers(oop obj);
*** 58,67 ****
--- 59,73 ----
// Iterators
int oop_oop_iterate(oop obj, OopClosure* blk);
int oop_oop_iterate_m(oop obj, OopClosure* blk, MemRegion mr);
+ // Allocation profiling support
+ // no idea why this is pure virtual and not in Klass ???
+ juint alloc_size() const { return _alloc_size; }
+ void set_alloc_size(juint n) { _alloc_size = n; }
+
#ifndef PRODUCT
public:
// Printing
void oop_print_on(oop obj, outputStream* st);
#endif