gcc assembly extended register

微笑、不失礼 提交于 2019-12-11 12:46:43

问题


What parameter/constraint do I have to use in order to tell the compiler to use an extended register pair as the output/input?

static inline void mac_dsp(int64_t *c, uint32_t a, uint32_t b){
    //This does not compile - "madd.u [%a15]0,[%a15]0,%d15,%d2: Too many operands"      
    __asm__ ("madd.u  %0,%0,%1,%2" : "+m" (*c) : "d" (a), "d" (b));

    //This does compile but I don't explicitly want to use e2 only but let the compiler 
    //chose which one...
    __asm__ ("madd.u  %%e2,%%e2,%1,%2" : "+m" (*c) : "d" (a), "d" (b));
}

Can anyone help me here? Thank you!

来源:https://stackoverflow.com/questions/52147076/gcc-assembly-extended-register

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!