[vector] Replace IllegalArgumentE with UnsupportedOE for zero arg methods

Viswanathan, Sandhya sandhya.viswanathan at intel.com
Thu May 7 20:53:20 UTC 2020

Thanks, looks good.

Best Regards,

From: Paul Sandoz <paul.sandoz at oracle.com>
Sent: Thursday, May 07, 2020 1:09 PM
To: Viswanathan, Sandhya <sandhya.viswanathan at intel.com>
Cc: panama-dev at openjdk.java.net' <panama-dev at openjdk.java.net>
Subject: Re: [vector] Replace IllegalArgumentE with UnsupportedOE for zero arg methods

Ah, LaneType.SHORT.asFloating() throws, but its an IAE not UOE, I fixed that, added a comment, added some tests for the viewAs methods:



On May 7, 2020, at 11:11 AM, Viswanathan, Sandhya <sandhya.viswanathan at intel.com<mailto:sandhya.viswanathan at intel.com>> wrote:

Hi Paul,

Changes look good. Only one question below:

For ByteVector.java and ShortVector.java, the method viewAsFloatingLanes is throwing AssertionError and not UnsupportedOperationException:

    viewAsFloatingLanes() {
        LaneType flt = LaneType.SHORT.asFloating();
        throw new AssertionError();  // should already throw IAE

Best Regards,

-----Original Message-----
From: panama-dev <panama-dev-bounces at openjdk.java.net<mailto:panama-dev-bounces at openjdk.java.net>> On Behalf Of Paul Sandoz
Sent: Wednesday, May 06, 2020 5:22 PM
To: panama-dev at openjdk.java.net<mailto:panama-dev at openjdk.java.net>' <panama-dev at openjdk.java.net<mailto:panama-dev at openjdk.java.net>>
Subject: [vector] Replace IllegalArgumentE with UnsupportedOE for zero arg methods


Please review the following change replacing IllegalArgumentException with UnsupportedOperationException for some methods that accept zero args:

 http://cr.openjdk.java.net/~psandoz/panama/vector-ise-to-uoe/webrev/ <http://cr.openjdk.java.net/~psandoz/panama/vector-ise-to-uoe/webrev/>

This change is in response to reviews in preparation for integration into jdk/jdk.


More information about the panama-dev mailing list