title: Concurrent Dictionary with 500k kvps (delete kvps or not)
body: <p>I have a program that runs for 500k devices-under-test (DUT) (numbered from 1 to 500k; keys also numbered so). After completion of a set of 500k DUTs, the program runs for another 500k, so on and so forth. As each DUT gets tested, I create a key-value-pair (kvp) for the DUT, in a concurrent dictionary. Now, I am wondering:
  1. whether after a single set of 500k DUTs has completed its testing, should I delete the concurrent dictionary of all the 500k kvps and add add the kvps again for the next set of 500k DUTs, or
  2. only clear the values for all the previous 500k keys, and add the values for the corresponding new 500k DUTs against their respective keys?</p>
  
  <p>Which one is better in terms of time-performance? ( I believe option#2 is better)
  The host system has enough memory to keep data for 500k DUTs all throughout the lifetime of the program. Hence, I am not considering memory as constraint.</p>