Files
n8n-openai-adapter/lib/elixir/test
José Valim 12c5b20278 Make Base encoding/decoding 100%/25% faster respectively
decode16, in particular, is 50% faster, as we don't need to
handle padding.

We also reduce the .beam size from 330kb to 80kb.

This is achieved by building look tables, as described in
https://www.erlang.org/blog/type-based-optimizations-in-the-jit/

For decoding, we build a sparse lookup table with nils in it.
The tables are still small (less than 80 elements) and we have
to check for nils, but that's more efficient than the previous
approach as well.

The code is also simpler, as we rely less on macros
and more on dynamic code generation.

Closes #11866.
2022-06-19 16:15:29 +02:00
..