When the GC code was converted to use the unified logging framework the verification logging was changed to mostly use:
log_info(gc, vefiy)("Information about verification failure");
The problem with this is that some verification, in particular in G1, does not report the relevant information in asserts and guarnatee messages. Instead the information is logged ahead of time and at some later point there is something like a "guarantee(false, "Verification failed.");"
So, to know what went wrong you really need the information that was logged. However when it is logged on log_info(gc, verify) you need to have remembered to set -Xlog:gc* on the command line to get this information.
A better solution is to log failure information at the error level. That way it is always logged.
log_info(gc, vefiy)("Information about verification failure");
The problem with this is that some verification, in particular in G1, does not report the relevant information in asserts and guarnatee messages. Instead the information is logged ahead of time and at some later point there is something like a "guarantee(false, "Verification failed.");"
So, to know what went wrong you really need the information that was logged. However when it is logged on log_info(gc, verify) you need to have remembered to set -Xlog:gc* on the command line to get this information.
A better solution is to log failure information at the error level. That way it is always logged.