On Wed, Aug 3, 2016 at 10:22 AM, Derek Gaston <fried...@gmail.com> wrote:
> Related to my other email... another thing that would allow us to do a LOT > of optimization is if we had a free void pointer on DofObject. This would > allow us to attach any kind of data structure we want for caching > computations on DofObject (for instance: caching the value of shape > functions at the quadrature points!). > > I see this as a compile time option (that is off by default) because it > obviously adds a bit of memory overhead. > > Note: for the kinds of optimizations I'm talking about I don't even want a > log(n) lookup in a map or the complexity of a hash computation for a > hash-map. I really want a (nearly) instantaneous access to a cached data > structure. > > Any opinions? > Can we not make it a pointer to a "Context" class with basically nothing (or some very minimal interface) in it that people can derive from and doesn't prevent you from doing what you want to do? If it needs to be a void*, I guess it's fine as long as there is an example of how you can use it in practice, a void* doesn't provide much documentation. -- John
------------------------------------------------------------------------------
_______________________________________________ Libmesh-devel mailing list Libmesh-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libmesh-devel