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

Compiling errors caused by turning off openmp option when building code for arm platform #586

Closed
hry76519 opened this issue Sep 25, 2018 · 2 comments

Comments

@hry76519
Copy link

hry76519 commented Sep 25, 2018

Hi, I found that there will be compiling error occured if I turn off the openmp in the CMakeList.txt file:
option(NCNN_OPENMP "openmp support" OFF)
The error message are as follows:

In file included from /users/lance.huang/ncnn-0920/src/layer/arm/convolution_arm.cpp:21:0:
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3.h: In member function ‘int ncnn::Convolution_arm::_ZNK4ncnn15Convolution_arm7forwardERKNS_3MatERS1_RKNS_6OptionE.part.14(const ncnn::Mat&, ncnn::Mat&, const ncnn::Option&) const’:
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3.h:12848:18: error: can’t find a register in class ‘LO_REGS’ while reloading ‘asm’
);
^
In file included from /users/lance.huang/ncnn-0920/src/layer/arm/convolution_arm.cpp:28:0:
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3_int8.h:3814:18: error: ‘asm’ operand has impossible constraints
);
^
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3_int8.h:4044:22: error: ‘asm’ operand has impossible constraints
);
^
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3_int8.h:5025:18: error: ‘asm’ operand has impossible constraints
);
^
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3_int8.h:5348:18: error: ‘asm’ operand has impossible constraints
);
^
In file included from /users/lance.huang/ncnn-0920/src/layer/arm/convolution_arm.cpp:21:0:
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3.h:12848:18: error: ‘asm’ operand has impossible constraints
);
^
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_3x3.h:13068:22: error: ‘asm’ operand has impossible constraints
);
^
/users/lance.huang/ncnn-0920/src/layer/arm/convolution_arm.cpp:454: confused by earlier errors, bailing out
src/CMakeFiles/ncnn.dir/build.make:542: recipe for target 'src/CMakeFiles/ncnn.dir/layer/arm/convolution_arm.cpp.o' failed
make[2]: *** [src/CMakeFiles/ncnn.dir/layer/arm/convolution_arm.cpp.o] Error 1
CMakeFiles/Makefile2:302: recipe for target 'src/CMakeFiles/ncnn.dir/all' failed
make[1]: *** [src/CMakeFiles/ncnn.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

The errors seem to be something wrong about the neon code.
The older version of NCNN (about three month ago) is OK for turning off OpenMP, while the recent version will get the compiling errors.

Would you please help to check and fix the problem?
Thanks.

@hry76519 hry76519 changed the title Compiling errors caused by turning off openmp option Compiling errors caused by turning off openmp option when building code for arm platform Sep 25, 2018
@522730312
Copy link

可能跟你的 arm 平台有关吧,我这边倒是没有出现这个问题 armv7 用的ncnn推荐的编辑链编辑的

@nihui
Copy link
Member

nihui commented Aug 2, 2019

This is usually a issue in your toolchain
ask your platform vender for a toolchain upgrade

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

3 participants