JDK-8160357: assert(_in == (Node**)this) failed: Must not pass arg count to 'new'
Kim Barrett
kim.barrett at oracle.com
Mon Jun 27 18:58:40 UTC 2016
> On Jun 27, 2016, at 10:57 AM, Yasumasa Suenaga <yasuenag at gmail.com> wrote:
>
>> I see only space changes in a webrev below.
>
> Sorry, I wrote incorrect URL.
> Please see as below:
>
> http://cr.openjdk.java.net/~ysuenaga/JDK-8160357/webrev.00/
The change consists of:
src/share/vm/opto/node.cpp
remove:
329 assert( _in == (Node**)this, "Must not pass arg count to 'new'" );
This assertion is being tripped because gcc6 is removing the relevant
assignment from Node::operator new:
inline void* operator new(size_t x) throw() {
Compile* C = Compile::current();
Node* n = (Node*)C->node_arena()->Amalloc_D(x);
#ifdef ASSERT
n->_in = (Node**)n; // magic cookie for assertion check
#endif
return (void*)n;
}
That assignment of n->_in is, in this context, undefined behavior.
This was reported by Andrew Hughes back in March 2016.
http://mail.openjdk.java.net/pipermail/build-dev/2016-March/016767.html
This particular problem was suppose to have been worked around by
https://bugs.openjdk.java.net/browse/JDK-8151841
which added -fno-lifetime-dse when building with gcc 6 or later. Maybe
that got lost in the switch to the new build system? Hm,
https://bugs.openjdk.java.net/browse/JDK-8157358
might be relevant.
More information about the hotspot-dev
mailing list