Sharing global and local variables using Unified Memory