Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-5788

Improve write characters

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.7.1
    • Component/s: BSON, Performance
    • None
    • None
    • Java Drivers
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?
    • None
    • None
    • None
    • None
    • None
    • None

      While running few benchmarks vs https://github.com/quarkusio/quarkus-super-heroes/blob/main/README.md

      using native image (graal CE) we found OutputBuffer::writeCharacters heap-based code path to be:

      • bloated by many not inlined calls: which Graal CE should be blamed since it has a very simple and naive inliner
      • an excessive usage of logic to handle the current buffer to be used to write chars into
      • zero loop unrolling due to the complexity of the main loop

      The same takes can be observed with any recent version of Hotspot (JDK 21) .

            Assignee:
            slav.babanin@mongodb.com Slav Babanin
            Reporter:
            nigro.fra@gmail.com Francesco Nigro
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              None
              None
              None
              None