Hi,

Attached is a patch to use VC8 specific optimization options. FTR, VC8 no longer supports the /Gn processor code generation directive, and the makefile now uses link time code generation when not optimizing for space.

Enjoy.

Mike
--
If space is a vacuum, who changes the bags?
*** Make_mvc.mak.orig   Wed Apr 26 10:30:22 2006
--- Make_mvc.mak        Wed Jan 17 13:48:57 2007
***************
*** 321,326 ****
--- 321,327 ----
  OUTDIR=$(OBJDIR)
  
  # Convert processor ID to MVC-compatible number
+ !if "$(_NMAKE_VER)" != "8.00.50727.42"
  !if "$(CPUNR)" == "i386"
  CPUARG = /G3
  !elseif "$(CPUNR)" == "i486"
***************
*** 334,339 ****
--- 335,346 ----
  !else
  CPUARG =
  !endif
+ !else
+ # VC8 only allows specifying SSE architecture
+ !if "$(CPUNR)" == "pentium4"
+ CPUARG = /arch:SSE2
+ !endif
+ !endif
  
  !ifdef NODEBUG
  VIM = vim
***************
*** 344,349 ****
--- 351,362 ----
  !else # MAXSPEED
  OPTFLAG = /Ox
  !endif
+ # Use link time code generation in VC8 if not worried about size
+ !if "$(_NMAKE_VER)" == "8.00.50727.42"
+ !if "$(OPTIMIZE)" != "SPACE"
+ OPTFLAG = $(OPTFLAG) /GL
+ !endif
+ !endif
  CFLAGS = $(CFLAGS) $(OPTFLAG) -DNDEBUG $(CPUARG)
  RCFLAGS = $(rcflags) $(rcvars) -DNDEBUG
  ! ifdef USE_MSVCRT
***************
*** 706,711 ****
--- 719,733 ----
  LINKARGS2 = $(CON_LIB) $(GUI_LIB) $(LIBC) $(OLE_LIB)  user32.lib $(SNIFF_LIB) 
\
                $(MZSCHEME_LIB) $(PERL_LIB) $(PYTHON_LIB) $(RUBY_LIB) \
                $(TCL_LIB) $(NETBEANS_LIB) $(XPM_LIB) $(LINK_PDB)
+ 
+ # Report link time code generation progress if used. 
+ !ifdef NODEBUG
+ !if "$(_NMAKE_VER)" == "8.00.50727.42"
+ !if "$(OPTIMIZE)" != "SPACE"
+ LINKARGS1 = $(LINKARGS1) /LTCG:STATUS
+ !endif
+ !endif
+ !endif
  
  all:  $(VIM).exe vimrun.exe install.exe uninstal.exe xxd/xxd.exe \
                GvimExt/gvimext.dll

Reply via email to