In Loom I've seen crashes like this:
R12=0x00000000d1d08f10 is an oop:
[error occurred during error reporting (printing registers, top of stack, instructions near pc), id 0xe0000000, Internal Error (/opt/mach5/mesos/work_dir/slaves/779adf21-f3e5-4e6a-a889-8cc0f9bc6fbb-S14/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/33379539-c125-496e-86f3-b6c4ee310674/runs/32462260-aae6-43ab-91eb-c32e4b6e61c4/workspace/open/src/hotspot/share/memory/resourceArea.cpp:53)]
which happens because the thread doesn't have an active ResourceMark, it seems. resourceArea.cpp:53 is:
```
void ResourceArea::verify_has_resource_mark() {
if (_nesting <= 0) {
// Only report the first occurrence of an allocating thread that
// is missing a ResourceMark, to avoid possible recursive errors
// in error handling.
static volatile bool reported = false;
if (!Atomic::load(&reported)) {
if (!Atomic::cmpxchg(&reported, false, true)) {
fatal("memory leak: allocating without ResourceMark");
}
}
}
}
```
If the first missing resource area is found during error reporting, wouldn't it just be better to not crash and continue hs_err printing?
R12=0x00000000d1d08f10 is an oop:
[error occurred during error reporting (printing registers, top of stack, instructions near pc), id 0xe0000000, Internal Error (/opt/mach5/mesos/work_dir/slaves/779adf21-f3e5-4e6a-a889-8cc0f9bc6fbb-S14/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/33379539-c125-496e-86f3-b6c4ee310674/runs/32462260-aae6-43ab-91eb-c32e4b6e61c4/workspace/open/src/hotspot/share/memory/resourceArea.cpp:53)]
which happens because the thread doesn't have an active ResourceMark, it seems. resourceArea.cpp:53 is:
```
void ResourceArea::verify_has_resource_mark() {
if (_nesting <= 0) {
// Only report the first occurrence of an allocating thread that
// is missing a ResourceMark, to avoid possible recursive errors
// in error handling.
static volatile bool reported = false;
if (!Atomic::load(&reported)) {
if (!Atomic::cmpxchg(&reported, false, true)) {
fatal("memory leak: allocating without ResourceMark");
}
}
}
}
```
If the first missing resource area is found during error reporting, wouldn't it just be better to not crash and continue hs_err printing?