Memoization of functions with vector inputs in Julia and JuMP

I’m evaluating the trade-offs and efficient use of memoization with lengthy vectors, particularly in optimisation. Suppose a vector input to an expensive function has many Float64 elements, say, 100,000. When this function is memoized:

  1. Is the whole vector stored or just some ID/ hashcode?

  2. Is the equality with an incoming vector tested by reference or by value? Does this depend on the number of elements?

  3. How can some of the memoized keys/values be deleted programmatically (e.g., by popping a stack)?

  4. How would the above apply if the input vector was the optimisation variable in JuMP?

Many thanks!