Support AMD

Let compile support amd.