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

ie_precision: added FloatTrait to fix VS2015 client compilation #5810

Merged
merged 1 commit into from
May 25, 2021

Conversation

mshabunin
Copy link
Contributor

@mshabunin mshabunin commented May 25, 2021

Related PR #5654

Details:

Our VS2015 build has failed due to some unsupported template constructs:

c:\deployment_tools\inference_engine\include\ie_precision.hpp(440): error C2891: 'T': cannot take the address of a template parameter (compiling source file dnn.cpp)  
c:\deployment_tools\inference_engine\include\ie_precision.hpp(439): note: see declaration of 'T' (compiling source file dnn.cpp)

I understand that VS2015 is quite old and is not officially supported by OpenVINO, but since the fix is not too complex, I hope it won't break anything and can be accepted.

This patch is more naive version of the original code and I hope someone can propose better and more elegant solution in review comments. Other idea was to extend PrecisionTrait with something like is_float field or method, seemingly more extensive this change can simplify the code as a whole by omitting is_floating function completly.

cc @apertovs @ilya-lavrenov @alalek

@mshabunin mshabunin requested a review from a team May 25, 2021 14:13
@openvino-pushbot openvino-pushbot added the category: inference OpenVINO Runtime library - Inference label May 25, 2021
@ilya-lavrenov ilya-lavrenov added this to the 2021.4 milestone May 25, 2021
@ilya-lavrenov ilya-lavrenov self-assigned this May 25, 2021
@mshabunin
Copy link
Contributor Author

Updated to second proposed solution.

@ilya-lavrenov ilya-lavrenov enabled auto-merge (squash) May 25, 2021 14:33
@ilya-lavrenov ilya-lavrenov merged commit 84392f3 into openvinotoolkit:master May 25, 2021
@mshabunin mshabunin deleted the fix-vs2015-build branch May 26, 2021 10:25
AlexeyLebedev1 pushed a commit to AlexeyLebedev1/openvino that referenced this pull request May 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: inference OpenVINO Runtime library - Inference
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants