As part of #2259, the KeyValuePair converter was identified as an area of potential perf improvement. Currently (and in 3.0\3.1) it re-enters the serializer to serialize TKey and TValue which is expensive because a Dictionary lookup occurs for each (to find the converter).
Instead, the converter should cache the converter. Caching is possible on the converter instance since the type is internal and there are no concerns about having an instance shared across different JsonSerializerOptions instances that may have different converters for TKey and TValue.