Duplicate :
|
|
Relates :
|
|
Relates :
|
oopDesc::is_oop_or_null is an ordinary member function, whose definition includes a test using the expression "this == NULL". However, this can be assumed to never be NULL, as that would require undefined behavior. So the compiler is free to optimize away that test, eliminating the "_or_null" part of the function's intended semantics. Recent versions of gcc (like gcc 6) seem to be more aggressive about optimizations around that sort of thing, leading to crashes.
|