MagicFoundation / Alcinoe

Alcinoe Component Library For Delphi. Full opengl video player, WebRTC delphi wrapper, native ios/android TEdit, Improuved firemonkey controls, Firebase cloud messaging, Android/ios facebook sdk login, Json/Bson Parser, ImageMagick wrapper, MongoDb client And much more
Apache License 2.0
974 stars 214 forks source link

XML/JSON: Tiny.Library collaboration #154

Open d-mozulyov opened 3 years ago

d-mozulyov commented 3 years ago

Hello

I analyzed the sources of your libraries and came to the conclusion that the issue of optimization is very important for you. I have been programming in Delphi for over 20 years and spend a lot of time writing high-performance code. You can verify this by analyzing the benchmarks in my open source projects.

I would like to suggest that you use the Tiny.Library - it contains a lot of lightweight and high-performance code that works with text, data streams, RTTI, memory, generics and more. It is planned to supplement the library with routine testing, server applications, marshalling and more.

In fact, the library is a combination of the following libraries:

Nowadays there are not enough XML/JSON parsers and writers. Most Delphi parsers use standard strings for convenience. I think that in Tiny.Library this approach can be implemented, but as a superstructure on top of the low-level approach. I liked the approach in PugiXML, when addressing to pre-allocated memory occurs - this significantly speeds up the parsing process, especially in multithreaded applications, when each string allocation leads to the manager blocking. The library currently supports ALL possible XML encodings, including ALL possible BOMs. An automatic step-by-step encoding conversion has been implemented, which allows you to parse documents even several gigabytes in size, using only a few kilobytes of RAM. In addition, high-level functions are implemented for working with strings in pre-allocated memory, for example, for converting to a number or date - this will make it easy and convenient to use the fast parser in commercial products.

Writing high-performance code takes a lot of time and effort. The cost of making a mistake is very high. Since I am not an expert in XML/JSON, it is difficult for me to decide and take enough time to implement full-fledged parsers and writers. I need to collaborate with an expert who can consult, review code, and write automated tests. I suggest you consider this option. Contacts are listed in library units.

ghost commented 3 years ago

Димон, будет большой ошибкой, если автор будет использовать твою кривую поделку в своей библиотеке.

d-mozulyov commented 3 years ago

tumaso,

Если Вы нашли ошибку или хотите внести изменения, улучшающие библиотеку - просьба написать об этом в соответствующем проекте Если возникли сложности в понимании, как пользоваться кодом - рекомендую обратиться к документации или примерам, находящимся в репозитории Спасибо, что остаётесь неравнодушными к моим библиотекам!

ghost commented 3 years ago

Ты сначала сделай код stable, а уже потом fast. Кому нужен этот самый fast, если код гoвно?

d-mozulyov commented 3 years ago

tumaso,

Если у Вас есть примеры нестабильного кода - с большим удовольствием увижу их в разделе "Issues" соответствующего репозитория Спасибо за сотрудничество!