RFR: 8255416: Investigate err_msg to detect unnecessary uses [v2]

Aleksey Shipilev shade at openjdk.java.net
Thu Oct 29 08:20:45 UTC 2020


On Thu, 29 Oct 2020 08:15:42 GMT, Anton Kozlov <akozlov at openjdk.org> wrote:

>> I _am_ the author of those `SHENANDOAH_CHECK_FLAG_SET` blocks ;)
>> 
>> This should be fine:
>> 
>> do {                                                     \
>>   if (!(name)) {                                         \
>>     vm_exit_during_initialization("Error",               \
>>       "GC mode needs -XX:+" #name " to work correctly"); \
>>   }                                                      \
>> } while (0)
>
> OK, if you're OK with that. But let's introduce some consistency with e.g. https://github.com/openjdk/jdk/blob/a804c6a6/src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp#L420 and use 8 spaces for the argument indentation
> 
>   do {                                                                      \
>     if (!(name)) {                                                          \
>       vm_exit_during_initialization("Error",                                \
>               "GC mode needs -XX:+" #name " to work correctly");            \
>     }                                                                       \
>   } while (0)

Fine with me!

-------------

PR: https://git.openjdk.java.net/jdk/pull/905


More information about the shenandoah-dev mailing list