Help - Search - Members - Calendar
Full Version: ICL 8.0 to build processor specific LAME?
Hydrogenaudio Forums > Lossy Audio Compression > MP3 > MP3 - Tech
bluesky
Given the problems I ran into using mingw to compile a processor specific version of lame (detailed in this thread), I just downloaded the evaluation version of Intel C++ version 8.0 and am interested in using it to build a processor specific version of lame for both an AMD athlon XP. Can someone walk me through the process with ICL?

Thanks guys!
bluesky
Nevermind, looks like I need to install Microsoft Visual C++ 6.0 or better for 32-bit applications?? Damn. I guess nothing in life is free smile.gif
bluesky
Changed my mind again: we have MSVC 6 on several PCs at work. So I can install the 30-day trial ICL 8.1 on a machine there with MSVC 6!

Can anyone walk me through it?
robert
if you've installed your compilers, start the command shell, start the batch file that sets the environment variables right for icl (mainly PATH to include the directory of icl executables, INCLUDE and LIB for additional icl specific include files and libraries). I used to use the Makefile.MSVC for building LAME on windows.
robert
Maybe you don't need a complete VC6, you can get Visual C++ Toolkit 2003 for free from Microsoft. But I haven't tried to compile lame with it alone, so I can't tell you if that will work.

update: well, you would need a "Platform SDK" from Microsoft too. it's freely available too
bluesky
I'll give it a shot... as I said, I'll have to drive into the office to access it. So when I install the trial on that PC, this batch file you're talking about is part of that install? How would I go about setting up options for an athlon-xp or a p4 before the build?
robert
if you go the "Makefile.MSVC" route, you'll have to edit it to match your special CPU features you want. Look out for "Intel 4.5"
Gabriel
You can also build Lame directly on the command line by using the VC workspace by using the "lame - Win32 Release NASM" configuration.

Platform sdk is only needed for the Dshow filter. ACM codec has some alternative headers provided, and dll and command line frontend do not need anything from the platform sdk.
bluesky
I'll give it a try... I'm a total new user of both MSVC and ICL.
robert
QUOTE (Gabriel @ Jan 29 2005, 06:10 PM)
Platform sdk is only needed for the Dshow filter. ACM codec has some alternative headers provided, and dll and command line frontend do not need anything from the platform sdk.
*

Well, if one has no "MS Visual C++ Studio", but the freely available "MS C++ Toolkit 2003" only, then he would need the windows.h include file, which is not part of the Toolkit but is contained in the freely available "Platform SDK".
Gabriel
Oh! There is no windows.h in the free compiler toolkit?
Btw the platform sdk was free in the past, but I am not sure if it is still.


Regarding the original question: if you want to build Lame on windows, it is probably easier to use cygwin than mingw.
robert
QUOTE (Gabriel @ Jan 29 2005, 07:16 PM)
Oh! There is no windows.h in the free compiler toolkit?
Btw the platform sdk was free in the past, but I am not sure if it is still.


it seems still to be free:
QUOTE (http://msdn.microsoft.com/visualc/vctoolkit2003/)
You might decide you want to augment the Toolkit with additional free tools from Microsoft, including the Platform SDK or the .NET Framework SDK.

But it's huge, considering the few include files one would need to build LAME.
bluesky
OK... finally got remote access to a PC that has MSVC 6sp5 and I install the trial ICL 8.1 today. I assume I'll need nasmw.exe somewhere? Can you walk me through the build process?
Gabriel
You need nasmw in your path if you want to build the nasm version.
Open lame_vc6.dsw
Select your target (likely "lame")
Select your build (likelly "win32 release nasm")
build
bluesky
QUOTE (Gabriel @ Feb 1 2005, 03:40 AM)
You need nasmw in your path if you want to build the nasm version.
Open lame_vc6.dsw
Select your target (likely "lame")
Select your build (likelly "win32 release nasm")
build
*


When you say to 'open lame_vc6.dsw' do you mean within the MSVC GUI? I'm trying to use the ICL shell to accompilsh this. If I copy nasmw.exe to my build directory I can do I:

CODE
nmake -f Makefile.MSVC CPU=P3


Which gives me a lame.exe that's a bit slower than the one I can d/l from rarewares.org. I'd like to repeat the process to give a binary that will yield some speed optimizations for an athlon xp processor with ICL.
john33
QUOTE (bluesky @ Feb 1 2005, 08:47 PM)
I'd like to repeat the process to give a binary that will yield some speed optimizations for an athlon xp processor with ICL.
*

Excuse me!!! huh.gif You want an Intel compiler to optimise for AMD processors??? tongue.gif
bluesky
Well, my own tests prove that the rarewares.org icl lame.exe is 2-3% faster than anything I can produce in GCC.
robert
QUOTE (bluesky @ Feb 1 2005, 09:47 PM)
When you say to 'open lame_vc6.dsw' do you mean within the MSVC GUI?  I'm trying to use the ICL shell to accompilsh this.  If I copy nasmw.exe to my build directory I can do I:

CODE
nmake -f Makefile.MSVC CPU=P3


Which gives me a lame.exe that's a bit slower than the one I can d/l from rarewares.org.  I'd like to repeat the process to give a binary that will yield some speed optimizations for an athlon xp processor with ICL.
*

you can add PREC=SINGLE to your make command safely.

The intel compiler integrates itself into the MSVC Studio. There you can select which compiler to use. You can use the VC6 project files to build lame too.
bluesky
OK... but how does one tweak the options like in a ./configure step with icl? Can you post an example for me with some suggested optimizations for an XP?
robert
ok, just tried the icl 8.1 demo on my athlon-xp 1700 winxp. I got the best result with the following compiler options:
/G6 -> optimize for p3
/O3 -> maximum speed
/Ob2 -> inline all
plus use of single precision float
/DFLOAT8=float
/DREAL_IS_FLOAT=1 -> the decoder uses different names
plus some to disable debugging code
/DNDEBUG

the easiest way is, just edit the CFLAGS setting in Makefile.MSVC in the intel4.5 section. Then run "nmake -f Makefile.MSVC".
Garf
You can use /Qip /Qipo and even profiling too, read the manuals.
SoNiX
In case you have a spare machine, you could try a linux distro. GCC will do the job right. In case you don't, how about a linux live cd distro? It could be a hell of a help. Linux IMHO is a good enviroment for C/C++.



SoNiX dry.gif
robert
QUOTE (Garf @ Feb 9 2005, 01:32 PM)
You can use /Qip /Qipo and even profiling too, read the manuals.
*

Believe it or not, I read the manual smile.gif

IIRC: /Ob2 implies /Qip, /Qipo gave no improvements on my athlon-xp
robert
QUOTE (SoNiX @ Feb 9 2005, 01:52 PM)
In case you have a spare machine, you could try a linux distro. GCC will do the job right. In case you don't, how about a linux live cd distro? It could be a hell of a help. Linux IMHO is a good enviroment for C/C++.



SoNiX  dry.gif
*

Well, if you were talking to me, I already use Linux for some years now.
SoNiX
QUOTE (robert @ Feb 9 2005, 12:24 PM)
QUOTE (SoNiX @ Feb 9 2005, 01:52 PM)
In case you have a spare machine, you could try a linux distro. GCC will do the job right. In case you don't, how about a linux live cd distro? It could be a hell of a help. Linux IMHO is a good enviroment for C/C++.



SoNiX  dry.gif
*

Well, if you were talking to me, I already use Linux for some years now.
*



@robert: Sorry. The reply was to bluesky.



SoNiX dry.gif
Gabriel
QUOTE
So why go Win32, now?

Why not?
Anyway this is not really relevant to this thread...
SoNiX
QUOTE (Gabriel @ Feb 9 2005, 03:37 PM)
QUOTE
So why go Win32, now?

Why not?
Anyway this is not really relevant to this thread...
*




Edited last post. Like you, just trying to help.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.