Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

使用gcc在arm5te cpu上编译的错误 #31

Open
fw867 opened this issue Jan 28, 2015 · 1 comment
Open

使用gcc在arm5te cpu上编译的错误 #31

fw867 opened this issue Jan 28, 2015 · 1 comment

Comments

@fw867
Copy link

fw867 commented Jan 28, 2015

其它模块都编译通过只有下面这个不行,出错
[/tmp/make/src] # make
gcc -g -Wall -c -o memory.o memory.c
memory.c: In function 'rte_atomic32_cmpset':
memory.c:90: error: impossible constraint in 'asm'
make: *** [memory.o] Error 1

问题出在:
asm volatile(
"lock ; "
"cmpxchgl %[src], %[dst];"
"sete %[res];"
: [res] "=a" (res), /* output _/
[dst] "=m" (_dst)
: [src] "r" (src), /* input _/
"a" (exp),
"m" (_dst)
: "memory"); /* no-clobber list */
return res;

请问要怎么修改?

@jfb8856606
Copy link
Member

原子操作在每个平台上都不相同,目前只支持x86的linux平台,像ARM/HPUNIX/MIPS(龙芯Loongson)/win32等暂不支持。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants