Skip to content

(EXPERIMENTAL) Fix #624: try to use more efficient String constructor#625

Draft
cowtowncoder wants to merge 2 commits into3.xfrom
tatu/3.1/624-cbor-new-string
Draft

(EXPERIMENTAL) Fix #624: try to use more efficient String constructor#625
cowtowncoder wants to merge 2 commits into3.xfrom
tatu/3.1/624-cbor-new-string

Conversation

@cowtowncoder
Copy link
Member

No description provided.

@cowtowncoder
Copy link
Member Author

Oddly does not seem to speed up jackson-benchmarks CBOR test (in fact, ~5% slow down).

Maybe new String(byte[], int, int, Charset) not more optimal or... need to do some profiling I suppose.

@cowtowncoder
Copy link
Member Author

Oh. I suspect JDK uses fast method:

byte[] bytes = StringLatin1.encode(chars, 0, chars.length);

to handle conversion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant