-
Enhancement
-
Resolution: Won't Fix
-
P3
-
None
-
None
-
None
-
generic
-
generic
Use same code on heap buffers and direct buffers.
Snippet of current code:
protected CoderResult decodeLoop(ByteBuffer src,
CharBuffer dst)
{
if (src.hasArray() && dst.hasArray())
return decodeArrayLoop(src, dst);
else
return decodeBufferLoop(src, dst);
}
Since access to heap buffers and direct buffers is now optimized via Unsafe [1], there is no more need to separately optimize the code for heap buffers and direct buffers.
[1] https://bugs.openjdk.java.net/browse/JDK-8149469
Snippet of current code:
protected CoderResult decodeLoop(ByteBuffer src,
CharBuffer dst)
{
if (src.hasArray() && dst.hasArray())
return decodeArrayLoop(src, dst);
else
return decodeBufferLoop(src, dst);
}
Since access to heap buffers and direct buffers is now optimized via Unsafe [1], there is no more need to separately optimize the code for heap buffers and direct buffers.
[1] https://bugs.openjdk.java.net/browse/JDK-8149469
- is blocked by
-
JDK-6509032 (bf) Monomorphic implementations for Direct and Heap versions of X-Buffer
- Open
- relates to
-
JDK-8149469 ByteBuffer API and implementation enhancements for VarHandles
- Resolved