DATE: 2018.11.21
1、參考
https://stackoverflow.com/questions/29880695/compiling-error-impossible-constraint-in-asm?answertab=active#tab-top
https://stackoverflow.com/questions/30918170/impossible-constraint-in-asm-error
https://blog.csdn.net/Q1302182594/article/details/50794409
https://blog.csdn.net/u012509728/article/details/50404424
2、問題描述
今天在進行Android平台的x86和x86_64編譯時,對於x86內聯匯編代碼進行編譯時,報出如下錯誤:
impossible constraint in 'asm' error;
#define asm __asm__
3、解決方案
原因還未找到。
初步分析: Android ndk采用的匯編器為yasm,已經確認yasm支持Intel格式和GNU AS(AT&T)格式的純匯編編譯,但是可能並不支持AT&T格式的x86 Inline匯編,這個問題有待進一步確認 。
問題確認:
待補充