8385319: AOT: Missed BAD_ADDRESS_ID spots in JDK-8357175

Co-authored-by: Aleksey Shipilev <shade@openjdk.org>
Reviewed-by: shade
This commit is contained in:
Vladimir Kozlov 2026-05-23 17:35:28 +00:00
parent 845d951012
commit d99c8b3507

View File

@ -1794,7 +1794,7 @@ bool AOTCodeCache::write_asm_remarks(CodeBlob& cb) {
}
const char* cstr = add_C_string(str);
int id = _table->id_for_C_string((address)cstr);
assert(id != -1, "asm remark string '%s' not found in AOTCodeAddressTable", str);
assert(id != BAD_ADDRESS_ID, "asm remark string '%s' not found in AOTCodeAddressTable", str);
n = write_bytes(&id, sizeof(int));
if (n != sizeof(int)) {
return false;
@ -1836,7 +1836,7 @@ bool AOTCodeCache::write_dbg_strings(CodeBlob& cb) {
log_trace(aot, codecache, stubs)("dbg string=%s", str);
const char* cstr = add_C_string(str);
int id = _table->id_for_C_string((address)cstr);
assert(id != -1, "db string '%s' not found in AOTCodeAddressTable", str);
assert(id != BAD_ADDRESS_ID, "db string '%s' not found in AOTCodeAddressTable", str);
uint n = write_bytes(&id, sizeof(int));
if (n != sizeof(int)) {
return false;