imported patch fix-direct-invalidation
imported patch fix-windows