[vector] RFR: conversion operator fixes

John Rose john.r.rose at oracle.com
Thu Jul 25 23:28:53 UTC 2019


http://cr.openjdk.java.net/~jrose/vectors/conversion-fixes

I wrote a test harness for the operators and began to find bugs.
The harness isn’t complete, but I have a bunch of fixes to contribute.

The in-place and zero-extend conversions are fixed.

The documentation is better on a number of points.

The in-place conversions were mis-designed:  It doesn’t make sense to
do an in-place conversion in a float or double lane.  This is fixed, and
the types of some conversions are changed.

There’s a query to ask for the underlying value conversion of an in-place
conversion, since that can no longer be deduced easily.

Two factory methods are consolidated into one.

The shift operators are marked as “NOFP” meaning they won’t throw
JIT errors when you try to use them on float or double.

Can someone please shepherd this fix for me?

Ideally, the new regression test should be completed also.  It’s kind of
a mess right now, so I’m putting out on the side as a “bonus":

http://cr.openjdk.java.net/~jrose/vectors/conversion-fixes/OperatorCensusTest.java

— John


More information about the panama-dev mailing list