RFR: 8214363: HeapWord should not be a fake class

Kim Barrett kim.barrett at oracle.com
Mon Feb 18 20:18:09 UTC 2019


> On Feb 18, 2019, at 6:56 AM, Per Liden <per.liden at oracle.com> wrote:
> 
> On 02/14/2019 11:53 PM, Kim Barrett wrote:
>> Please review this change to the definitions of HeapWord and MetaWord.
>> They are no longer a class type.  Rather, they are typedefs for a
>> pointer to associated incomplete (and never defined) helper classes.
>> Thus, we no longer pretend to have class objects where they never
>> existed.
>> Among other things, this makes memset on a HeapWord[] no longer trigger
>> gcc8's new -Wclass-memaccess in ObjectStartArray::set_covered_region().
>> Other than the change to the definitions of HeapWord and MetaWord,
>> most of the changes are removal of no longer valid forward class
>> declarations for those types.
>> CR:
>> https://bugs.openjdk.java.net/browse/JDK-8214363
>> Webrev:
>> http://cr.openjdk.java.net/~kbarrett/8214363/open.02/
> 
> Looks good!
> 
> /Per
> 
>> Testing:
>> mach5 tier1-3.
>> Built using gcc8.2 and verified there is no longer a -Wclass-memaccess
>> warning from objectStartArray.cpp.

Thanks.



More information about the hotspot-dev mailing list