fixes for aarch64

@adamcrume @yuyuyu101 take a look?