AMD support

Ok the wrapper is far bigger than the function. Your choice if you want to support the environments though!