Community
cancel
Showing results for 
Search instead for 
Did you mean: 
lmeyerov2
Beginner
116 Views

Compile DLL?

Hi all, I'm trying to make a (64bit) DLL with autovectorization from the commandline.

In my project settings (VS), I set the following options (mainly going for inliningacross files to support the SIMD blocks, but some may be wrong):

/Zi /nologo /W4 /O3 /Ob2 /Oi /Ot /Qipo /GA /Qparallel /Quse-intel-optimized-headers /D "_WINDLL" /D "_MBCS" /EHsc /GS /Gy /fp:precise /QaxSSE4.2 /QxSSE4.2 /Zc:wchar_t /Zc:forScope /Qrestrict /Fp"x64\\ReleaseSIMTask\\ChargedBackend.pch" /Fa"x64\\ReleaseSIMTask\\" /Fo"x64\\ReleaseSIMTask\\" /Qopt-report:3 /Qdiag-enable:sc-parallel3 /Qdiag-enable:sc-include /Qguide=4 /wd"4068"

What would I run to make a DLL from commandline? I tried

icl.exe /target:library /output:MyDLL.dll File1.cpp File2.cpp

but target wasn't supported. Putting in "/LD" instead then reported that no files were specified, so I permuted the params, etc.

Thanks all!
0 Kudos
2 Replies
lmeyerov2
Beginner
115 Views

*Bump*

This is increasingly an issue as the intel plugin for VS is no longer emitting a DLL at all (though it appears to be otherwise going through the build process..).
JenniferJ
Moderator
115 Views

sorry that we missed your question.

to create a DLL from cmdline:
icl /c /O2 /MD t1.cpp t2.cpp
xilink /DLL t1.obj t2.obj
or
icl /O2 /MD t1.cpp t2.cpp /link /DLL

the original build is within the IDE, it has the "/Qdiag-enable:sc-parallel3 /Qdiag-enable:sc-include", when the /Qdiag-enable:sc-parallel3 is on, the compiler will only do analysis, do not create .obj files. it's why there is no .dll

after you get the analysing result, make any necessary code change and build again. But to build the program for testing, you need toturn the option off and rebuild.

thanks,
Jennifer

Reply