Antoine Pitrou <pit...@free.fr> added the comment: That said, it is possible to further improve json by reducing the number of memory allocations and temporary copies. Here is an experimental (meaning: not polished) patch which gains 40% in decoding speed in your example (9 seconds versus 15).
We could also add an option to intern object keys when decoding (which wins 400MB in your example); or, alternatively, have an internal "memo" remembering already seen keys and avoiding duplicates. ---------- keywords: +patch Added file: http://bugs.python.org/file15444/json-opts.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue6594> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com