#HOTELEX #Shanghai 2026 is set to take place from March 30 to April 2, 2026, in Shanghai, #China, positioning itself as a #key #event for #global #hospitality and #foodservice #suppliers aiming to access the #Chinese and broader #Asian #markets. The #exhibition builds on the record-breaking #performance of its 2025 edition. #Exhibitors at the 2025 #event reported a 37% rise in qualified #leads and a 23% increase in on-site #transactions. https://cnbusinessforum.com/hotelex-shanghai-2026-to-host-hospitality-and-foodservice-exhibition-in-china/
🔍 Optimizing base64 decoding in jwt-cpp
jwt-cpp is a popular header-only C++ library for creating and verifying JSON Web Tokens. Clean, lightweight, no heavy dependencies — exactly the kind of lib you want in a Linux server stack.
While working with it I noticed a performance issue in the base64 decoding path. 🐛
⚙️ The old approach:
For every character in the input, the decoder called std::find_if to search linearly through a 64-char alphabet array.
→ O(n) per character lookup
→ Called for every single byte being decoded
→ A JWT with a large payload = a lot of unnecessary searching
🔧 The fix — a reverse lookup table:
Instead of searching, I precomputed a 256-entry lookup table. Each array index represents a byte value, each entry its base64 value — or -1 if invalid.
Decoding a character becomes a single array access:
auto index = rdata[static_cast<unsigned char>(symbol)];
→ O(1) per character lookup
→ No iteration, no comparisons
→ constexpr — lives in read-only memory, CPU cache friendly
📊 For JWT verification on a busy server this happens thousands of times per second. Small change, real impact.
👉 github.com/Thalhammer/jwt-cpp/commit/59cdb43
#HOTELEX #Shanghai 2026 is set to take place from March 30 to April 2, 2026, in Shanghai, #China, positioning itself as a #key #event for #global #hospitality and #foodservice #suppliers aiming to access the #Chinese and broader #Asian #markets. The #exhibition builds on the record-breaking #performance of its 2025 edition. #Exhibitors at the 2025 #event reported a 37% rise in qualified #leads and a 23% increase in on-site #transactions. https://cnbusinessforum.com/hotelex-shanghai-2026-to-host-hospitality-and-foodservice-exhibition-in-china/
Partial #performance comparison of #blas / #lapack in #rstats using Xeon E5-2697, i3-12100t, Ultra 7, 265, i7-11000 . The old timer still punches well for its age. Interesting to watch the less than gracious degradation in the AVX512 capable chip (i7)
Subscribe to #performance entries via RSS feed