added cudamemset function implementation