You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by wbyeh <wb...@hotmail.com> on 2016/09/07 12:00:52 UTC

Please warn Oracle Java8 VM has inline optimization error!

Dear Friends,

I just test ignite 1.7.0 with Oracle JDK8 with some occasional error on
adjacent calling on Cache Object setters, it seems some bytecode
optimization caused the passing parameter to be ignored on the subsequent
setter call.


 e.g.
  double w, p =0;
  w = p =4.0; 
  askrec.setWin(w); 
  askrec.setPlace(p); 


	public void setPlace(Double p) {
		assert p > 0 : "place <=0 " + p;
		this.place = p;
	}

### Excluding compile: my.own.AskRecord::setPlace

Exception in thread "main" java.lang.AssertionError: place <=0 0.0
	at my.own.AskRecord.setPlace(AskRecord.java:225)
	at my.trade.TradeManagerTest1.case6(TradeManagerTest1.java:336)
	at my.trade.TradeManagerTest1.mainTest(TradeManagerTest1.java:489)
	at my.trade.TM2.main(TM2.java:12)


I am using '-XX:-inline' to prevent this issue but still under verifying.


-Patrick, Yeh




--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by wbyeh <wb...@hotmail.com>.
https://bugs.openjdk.java.net/browse/JDK-8165766



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7822.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by wbyeh <wb...@hotmail.com>.
https://github.com/WENPIN1/BreakJava8TierComp

Frequently reproduce the AssertionError on Windows x64 

Java(TM) SE Runtime Environment 1.8.0_101-b13 Oracle Corporation Java
HotSpot(TM) 64-Bit Server VM 25.101-b13



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7627.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by Alexey Goncharuk <al...@gmail.com>.
Hi Patrick,

I was not able to reproduce this issue neither under 8u51 nor on 8u101
under Mac using your code. Can you share the reproducer which does not use
Ignite with us when it's available?

2016-09-09 11:43 GMT+03:00 wbyeh <wb...@hotmail.com>:

> Val,
>
> It's definitely not an ignite issue.
> It's Oracle JDK8 TieredCompilation bug.
>
> We may test the git source to reproduce this issue and I have consolidate
> the reproducer.
> I'll upload it to the git soon.
>
> -Patrick
>
>
>
> --
> View this message in context: http://apache-ignite-users.
> 70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-
> inline-optimization-error-tp7582p7625.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by wbyeh <wb...@hotmail.com>.
Val,

It's definitely not an ignite issue.
It's Oracle JDK8 TieredCompilation bug.

We may test the git source to reproduce this issue and I have consolidate
the reproducer.
I'll upload it to the git soon.

-Patrick 



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7625.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by vkulichenko <va...@gmail.com>.
Hi,

This is interesting. What should I run in your test to reproduce the issue?
Can you create a JIRA ticket for it?

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7617.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by wbyeh <wb...@hotmail.com>.
https://youtu.be/dQxGd_yiQ4A


I think I solved this Java 8 optimization by '-XX:-TieredCompilation'  
or change the code above not to use autobox during method call.

It's quite .....


e.g.

Double w =4; 
Double p =4; 
  askrec.setWin(w); 
  askrec.setPlace(p); 


        public void setPlace(Double p) { 
                assert p > 0 : "place <=0 " + p; 
                this.place = p; 
        } 



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7602.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by wbyeh <wb...@hotmail.com>.
Val,

I've consolidated the test case.

https://github.com/WENPIN1/Ignite_Java8_Test

-Patrick



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7598.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Please warn Oracle Java8 VM has inline optimization error!

Posted by vkulichenko <va...@gmail.com>.
Hi Patrick,

Is there a test that reproduces the issue?

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Please-warn-Oracle-Java8-VM-has-inline-optimization-error-tp7582p7595.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.