Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/hotspot/share/c1/c1_LIRGenerator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1300,7 +1300,7 @@ void LIRGenerator::do_isPrimitive(Intrinsic* x) {
}

__ move(new LIR_Address(rcvr.result(), java_lang_Class::klass_offset(), T_ADDRESS), temp, info);
__ cmp(lir_cond_notEqual, temp, LIR_OprFact::metadataConst(0));
__ cmp(lir_cond_notEqual, temp, LIR_OprFact::metadataConst(nullptr));
__ cmove(lir_cond_notEqual, LIR_OprFact::intConst(0), LIR_OprFact::intConst(1), result, T_BOOLEAN);
}

Expand Down Expand Up @@ -1333,7 +1333,7 @@ void LIRGenerator::do_getModifiers(Intrinsic* x) {

// Check if this is a Java mirror of primitive type, and select the appropriate klass.
LIR_Opr klass = new_register(T_METADATA);
__ cmp(lir_cond_equal, recv_klass, LIR_OprFact::metadataConst(0));
__ cmp(lir_cond_equal, recv_klass, LIR_OprFact::metadataConst(nullptr));
__ cmove(lir_cond_equal, prim_klass, recv_klass, klass, T_ADDRESS);

// Get the answer.
Expand Down
4 changes: 2 additions & 2 deletions src/hotspot/share/ci/ciConstantPoolCache.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1999, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 2024, 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
Expand Down Expand Up @@ -37,7 +37,7 @@
ciConstantPoolCache::ciConstantPoolCache(Arena* arena,
int expected_size) {
_elements =
new (arena) GrowableArray<void*>(arena, expected_size, 0, 0);
new (arena) GrowableArray<void*>(arena, expected_size, 0, nullptr);
_keys = new (arena) GrowableArray<int>(arena, expected_size, 0, 0);
}

Expand Down
4 changes: 2 additions & 2 deletions src/hotspot/share/ci/ciStreams.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1999, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 2024, 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
Expand Down Expand Up @@ -135,7 +135,7 @@ Bytecodes::Code ciBytecodeStream::next_wide_or_table(Bytecodes::Code bc) {
// ------------------------------------------------------------------
// ciBytecodeStream::reset_to_bci
void ciBytecodeStream::reset_to_bci( int bci ) {
_bc_start=_was_wide=0;
_bc_start = _was_wide = nullptr;
_pc = _start+bci;
}

Expand Down
4 changes: 2 additions & 2 deletions src/hotspot/share/code/codeCache.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,8 @@ class CodeBlob_sizes {
// Iterate over all CodeBlobs (cb) on the given CodeHeap
#define FOR_ALL_BLOBS(cb, heap) for (CodeBlob* cb = first_blob(heap); cb != nullptr; cb = next_blob(heap, cb))

address CodeCache::_low_bound = 0;
address CodeCache::_high_bound = 0;
address CodeCache::_low_bound = nullptr;
address CodeCache::_high_bound = nullptr;
volatile int CodeCache::_number_of_nmethods_with_dependencies = 0;
ExceptionCache* volatile CodeCache::_exception_cache_purge_list = nullptr;

Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/code/dependencies.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ void Dependencies::initialize(ciEnv* env) {
#endif
DEBUG_ONLY(_deps[end_marker] = nullptr);
for (int i = (int)FIRST_TYPE; i < (int)TYPE_LIMIT; i++) {
_deps[i] = new(arena) GrowableArray<ciBaseObject*>(arena, 10, 0, 0);
_deps[i] = new(arena) GrowableArray<ciBaseObject*>(arena, 10, 0, nullptr);
}
_content_bytes = nullptr;
_size_in_bytes = (size_t)-1;
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/code/nmethod.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3270,7 +3270,7 @@ void nmethod::print_recorded_oop(int log_n, int i) {
if (value == Universe::non_oop_word()) {
tty->print("non-oop word");
} else {
if (value == 0) {
if (value == nullptr) {
tty->print("nullptr-oop");
} else {
oop_at(i)->print_value_on(tty);
Expand Down
8 changes: 4 additions & 4 deletions src/hotspot/share/code/oopRecorder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ template <class T> void ValueRecorder<T>::copy_values_to(nmethod* nm) {
template <class T> void ValueRecorder<T>::maybe_initialize() {
if (_handles == nullptr) {
if (_arena != nullptr) {
_handles = new(_arena) GrowableArray<T>(_arena, 10, 0, 0);
_no_finds = new(_arena) GrowableArray<int>( _arena, 10, 0, 0);
_handles = new(_arena) GrowableArray<T>(_arena, 10, 0, T{});
_no_finds = new(_arena) GrowableArray<int>(_arena, 10, 0, 0);
} else {
_handles = new GrowableArray<T>(10, 0, 0);
_no_finds = new GrowableArray<int>( 10, 0, 0);
_handles = new GrowableArray<T>(10, 0, T{});
_no_finds = new GrowableArray<int>(10, 0, 0);
}
}
}
Expand Down