Comments (11)
I don't use visual studio, but the _MCS_VER #defines in audiomark.c switch from hardcoded mode to file-read mode. If you remove the _MSC_VER code in the audiomark.c and just include the raw files, can you make it work? It appears to be limited to that file only.
from audiomark.
I tried to build on Linux (i.e. no _MCS_VER defined) and gets a lot of warning messages as shown from screenshot. It seems to me this is not normal so I just stopped the build.
from audiomark.
Yes, there are lots of warnings. I don't think the array sizes are matched up yet. I'm skipping the warnings for now and getting all the parts connected. Then going back and sanitizing. You might want to correct this in the process of adding your BF code. I don't yet have a strategy for checking the output (and input) of each stage for correctness. Someone has yet to develop that.
from audiomark.
OK, ignore warnings and let it continue in Linux but I get compile error copied below. Something is not right. Anything special I need do or setup? It will be good if your cmake build supports MS visual studio since it is easier tool to debug.
In file included from /mnt/c/Users/LiKaiping/workspace/audio/audiomark-dev/components/arm/audio_beamformer/src/arm_beamformer_process_f32.c:33: /mnt/c/Users/LiKaiping/workspace/audio/audiomark-dev/platform/cmake/../../libraries/DSP/Include/arm_math_types.h:82:10: fatal error: cmsis_compiler.h: No such file or directory 82 | #include "cmsis_compiler.h" | ^~~~~~~~~~~~~~~~~~ compilation terminated.
from audiomark.
@Kaipingli88 I modified the CMakeLists.txt
file to work with MSVC's CMake. It generates audiomark.sln
which can be opened and compiled from MSVC2019 (my version). I couldn't start the debugger, but I could run it from a command prompt. Maybe you can help me understand what is wrong with the project setup. I did not include the solution file because all of the path names were hard coded to my directory structure for some reason.
from audiomark.
I forgot to mention this is ONLY in the cleanup01
branch which I haven't merged yet because I heavily modified the audiomark.c
file and have a lot of Q's for Laurent.
from audiomark.
The reason why I couldn't launch the debugger was due to having "ALL_BUILD" set as the default project. Once I set it to "audiomark" I could debug inside MSVC.
from audiomark.
I pulled your cleanup01 branch and tried your cmake to build for MSVC. I have a build error copied below:
C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,58): error C2146: s yntax error: missing ')' before identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD \audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,58): error C2061: s yntax error: identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,58): error C2059: s yntax error: ';' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,61): error C2059: s yntax error: ',' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,110): error C2059: syntax error: ')' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,60): error C2146: s yntax error: missing ')' before identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD \audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,60): error C2061: s yntax error: identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,60): error C2059: s yntax error: ';' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,63): error C2059: s yntax error: ',' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,113): error C2059: syntax error: ')' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj]
It looks like my MSVC somehow does not understand "__RESTRICT". My MSVC is Microsoft Visual Studio Professional 2019
Version 16.11.20
from audiomark.
That's very odd. What happens if you edit this code and add RESTRICT to the _MSC_VER
define block?
#if defined(_MSC_VER)
#ifndef __STATIC_FORCEINLINE
#define __STATIC_FORCEINLINE static __forceinline
#endif
#ifndef __STATIC_INLINE
#define __STATIC_INLINE static __inline
#endif
#ifndef __ALIGNED
#define __ALIGNED(x) __declspec(align(x))
#endif
//ptorelli--start
#elif defined ( __APPLE_CC__ ) || defined ( __GNUC__ )
#include <stdint.h>
#define __ALIGNED(x) __attribute__((aligned(x)))
#define __STATIC_FORCEINLINE static inline __attribute__((always_inline))
#define __STATIC_INLINE static inline
#ifndef __RESTRICT
#define __RESTRICT __restrict
#endif
//ptorelli--end
from audiomark.
Yes, it builds fine with this change.
from audiomark.
Completely fixed as of bfe2a48.
Closing, but we can re-open if it happens again.
from audiomark.
Related Issues (20)
- Variables idx_microphone_L, idx_microphone_R, idx_downlink, idx_for_asr in hard_coded_demo.c should be initialized HOT 2
- Why do we have so many FFT APIs? HOT 1
- Speexdsp component is set in fixed-point not agree with the top level API HOT 3
- There are too many `#define` macros. HOT 1
- What is the correct license header for the source files? HOT 1
- Reduce the # of warnings during compilation HOT 1
- How do we properly use the NODE_MEMREQ interface? HOT 9
- Document memory allocation scheme HOT 1
- Add valgrind/callgrind/(sp)lint static checking HOT 1
- No allocator present; assigns inaccessible memory HOT 2
- Are the provided three input audio files sufficient? HOT 5
- Fix inconsistent float types, use of `int` types, and signed constants HOT 1
- Understand if we should be using `restricted` on our function calls HOT 1
- Update to official CMSIS versions in reference libraries HOT 1
- MISRA 2012 compliance HOT 1
- Move reference th_api.c to it's own area; change CMake files HOT 1
- Can we use submodule for CMSIS-NN and CMSIS-DSP inside the port/arm/lib folder HOT 1
- Incorrect restrict qualifiers on th_memmove HOT 1
- Missing Model.hpp in the ds_cnn_model.hpp
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from audiomark.