I added twr_cache_malloc for use by the D2D code because the normal malloc i wrote is not optimized for speed, and the mallocs were causing a large slow down in the D2D code. Instead of using strdup, ...