Skip to content

Unify string encoding #1294

Open
Open

Description

@Aidan63

The UTF8 and UTF16 classes in cpp::encoding mostly duplicates the encoding which also occurs in String.cpp. I would have updated string to also use those dedicated encoding classes but doing some benchmarking of converting 5 paragraphs of lorem ipsum with a few emojis in it from UTF16 to UTF8 showed it to be twice as slow.

So there probably needs to be an optimisation pass to close the distance before unifying the two.

Activity

  1. tobil4sk commented on Jan 27, 2026

    @tobil4sk
    Member

    Seems like the new string encodings might also be related to a runtime performance regression in the dox benchmark: https://benchs.haxe.org/dox/index.html#13;false;true;true;JustData;none;2025-12-10;2026-01-09;C%2B%2B,C%2B%2B%20(GC%20Gen);runtime;pr-12078;true

    The PRs were merged 2nd jan: #1283, HaxeFoundation/haxe#12476

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions