Ticket #45904

astr_vadd_at() + fc_vsnprintf(): Single internal buffer

Eröffnet am: 2022-10-17 22:49 Letztes Update: 2024-02-09 15:41

Auswertung:
Verantwortlicher:
(Keine)
Typ:
Status:
Offen
Komponente:
Meilenstein:
Priorität:
5 - Mittel
Schweregrad:
5 - Mittel
Lösung:
Keine
Datei:
Keine

Details

In case of fallback fc_vsnprintf(), we produce the text first to our own internal buffer, from which it's copied to caller's buffer. If that caller is astr_vadd_at(), that buffer is another internal buffer, and the string gets copied again to final astr.

It should be easy to rearrange this so it skips one of those internal buffers (one copy), and, for platforms (Windows) relying on the fallback fc_vsnprintf(), such an optimization on constantly used low level functionality would likely be worth the effort.

Before this, #45903 is a priority, though. (so this might be something for 3.0.6?)

Ticket-Verlauf (3/7 Historien)

2022-10-17 22:49 Aktualisiert von: cazfi
  • New Ticket "astr_vadd_at() + fc_vsnprintf(): Single internal buffer" created
2022-10-27 04:53 Aktualisiert von: cazfi
2023-01-30 13:00 Aktualisiert von: cazfi
2023-03-26 15:36 Aktualisiert von: cazfi
2023-06-10 07:22 Aktualisiert von: cazfi
Kommentar

I have a patch for this, but it has proven not to be reliable. I don't want to take such risk of regression on the coming release.

2023-11-10 15:08 Aktualisiert von: cazfi
2024-02-09 15:41 Aktualisiert von: cazfi

Dateianhangliste

Keine Anhänge

Bearbeiten

You are not logged in. I you are not logged in, your comment will be treated as an anonymous post. » Anmelden