webrev <was> Re: Move Vector API from scratch project to an incubator module

mandy chung mandy.chung at oracle.com
Wed Sep 20 20:03:21 UTC 2017


AFAICT, this looks fine.  While there will be more javadoc work to do, 
you may want to add a package-info.java for jdk.incubator.vector so that 
the module summary will show the description of the package.

Mandy

On 9/20/17 9:20 AM, Paul Sandoz wrote:
> Unless there are objections i will push by the end of the week, as i want to have this ready and settled by JavaOne so that it is demo ready for our presentation.
>
> Paul.
>
>> On 15 Sep 2017, at 15:01, Paul Sandoz <Paul.Sandoz at oracle.com> wrote:
>>
>> I created the incubating module, modified Hotspot appropriately, added @HotSpotIntrinsicCandidate on supported methods (to the template), and added just one simple test to verify (by eye for now):
>>
>>     2408  319 %           AddTest::main @ 2 (54 bytes)
>>                             @ 8   AddTest::workload (63 bytes)   inline (hot)
>>                               @ 5   jdk.incubator.vector.Vector::speciesInstance (289 bytes)   inline (hot)
>>                               @ 27   jdk.incubator.vector.FloatVector$FloatSpecies::fromArray (12 bytes)   (intrinsic)
>>                               @ 36   jdk.incubator.vector.FloatVector$FloatSpecies::fromArray (12 bytes)   (intrinsic)
>>                               @ 42   jdk.incubator.vector.FloatVector::add (11 bytes)   (intrinsic)
>>                               @ 49   jdk.incubator.vector.FloatVector::intoArray (12 bytes)   (intrinsic)
>>                               @ 54   jdk.incubator.vector.Float256Vector$Float256Species::length (4 bytes)   inline (hot)
>>
>> http://cr.openjdk.java.net/~psandoz/panama/incubator_vector/webrev/
>>
>> Paul.
>>
>>> On 14 Sep 2017, at 11:50, Paul Sandoz <Paul.Sandoz at oracle.com> wrote:
>>>
>>> Hi,
>>>
>>> The vector intrinsics work is making some good progress.
>>>
>>> I propose to move the Vector API from jdk/test/panama/vector-draft-spec to its own module in the JDK named jdk.incubator.vector with classes under a package of the same name. That way an OpenJDK ea distribution of panama will include the Vector API and developers can easily experiment.
>>>
>>> One awkward aspect is @HotSpotIntrinsicCandidate is internal to the JDK and only usable in java.base. We can export it’s package to the jdk.incubator.vector module and IIUC ensure classes in the vector module are loaded by the platform class loader, thus annotated methods that are intrinsic are acknowledged.
>>>
>>> (Ideally HotSpotIntrinsicCandidate should reside in the package jdk.internal.vm.annotation.)
>>>
>>> Paul.



More information about the panama-dev mailing list