mirror of
https://github.com/openjdk/jdk.git
synced 2026-02-23 16:55:09 +00:00
8240324: Improve is_boot_class_loader_data() by adding simple check
Check if cld is the null_cld before looking at the class loader oop Reviewed-by: coleenp
This commit is contained in:
parent
52cfd292cc
commit
cf89ff7a4b
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. 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
|
||||
@ -39,8 +39,8 @@ inline oop ClassLoaderData::class_loader() const {
|
||||
}
|
||||
|
||||
inline bool ClassLoaderData::is_boot_class_loader_data() const {
|
||||
return class_loader() == NULL;
|
||||
}
|
||||
return this == _the_null_class_loader_data || class_loader() == NULL;
|
||||
}
|
||||
|
||||
inline ClassLoaderData* ClassLoaderData::class_loader_data_or_null(oop loader) {
|
||||
if (loader == NULL) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user