No supported MEX compiler, but codegen executes successfully

4 vues (au cours des 30 derniers jours)
dkv
dkv le 16 Mar 2017
Hi all,
I'm working with MATLAB Coder (R2016b, Windows 7 SP1) to get a speedup by compiling my function to a MEX file. The compilation is successful, and presumably Matlab is using the default LCC shipped with it, but I'd like to verify this for sanity purposes. However, when I run mex -setup I get a "No supported compiler for SDK found" error.
If this is intended and I install the MinGW compiler, how can I switch back and forth between the two?
Or, do I need to set an environment variable somewhere for Matlab to find LCC? If I do, how does the codegen command manage to find it without any additional help?

Réponses (1)

Ryan Livingston
Ryan Livingston le 17 Mar 2017
As it says here:
MATLAB Coder only uses LCC when there is no other compiler installed. If you install another compiler, LCC will not be used.
If performance is your goal, then I'd recommend using another compiler as LCC does not optimize to the degree of other compilers such as MinGW:

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by