Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Best compiler options for MSVC?

Author: Bryan Hofmann

Date: 10:41:32 02/16/04

Go up one level in this thread


On February 16, 2004 at 12:34:30, Peter Skinner wrote:

>On February 16, 2004 at 11:32:40, Bryan Hofmann wrote:
>
>>1. compile crafty with the additional options of "/prof_genx /prof_dir ."
>
>When using those two options I get this:
>CFLAGS   = /O3 /G6 /Gr /Ob2 /Qip /Qipo /QaxiW /W0 /prof_genx /prof_dir.
>
>xicl6.exe /D_CONSOLE /DWIN32 /O3 /G6 /Gr /Ob2 /Qip /Qipo /QaxiW /W0 /prof_genx
>/prof_dir. /DFAST /DEGTB6 /MT /DSMP /DCPUS=4 /DNT_INTEREX /DVC_INLINE_ASM
>/DUSE_ASSEMBLY /DEPD /DFUTILITY  /DNT_i386 /c x1.c
>Intel(R) C++ Compiler for 32-bit applications, Version 8.0   Build 20031017Z
>Package ID: W_CC_P_8.0.040
>Copyright (C) 1985-2003 Intel Corporation.  All rights reserved.
>icl: Command line warning: ignoring unknown option '-prof_genx'
>icl: Command line warning: ignoring unknown option '-prof_dir.'
>x1.c
>
>Where exactly do I put those options?
>
>Here is my makefile:
>
>TARGET   = NT_i386
>
>CC       = xicl6.exe
>LD       = xilink6.exe
>
>BFLAGS = /D_CONSOLE /DWIN32
>
>CFLAGS   = /O3 /G6 /Gr /Ob2 /Qip /Qipo /QaxiW /W0 /prof_genx /prof_dir.
>COPTS    = /DFAST /DEGTB6 /MT /DSMP /DCPUS=4 /DNT_INTEREX /DVC_INLINE_ASM
>/DUSE_ASSEMBLY /DEPD /DFUTILITY
>cobjs   = x1.obj
>
>ALLOPTS  = $(COPTS) $(AOPTS) /D$(TARGET)
>
>allobjs = $(cobjs) $(asmobjs) egtb.obj
>
>includes = chess.h data.h epd.h epddefs.h epdglue.h evaluate.h vcinline.h
>
>wcrafty  : $(allobjs)
>           $(LD) $(LDFLAGS) $(allobjs) /out:wcrafty.exe
>
>$(cobjs) : $(includes)
>
>.c.obj   :
>           $(CC) $(BFLAGS) $(CFLAGS) $(ALLOPTS) /c $*.c
>
>.cpp.obj :
>           $(CC) $(BFLAGS) $(CFLAGS) $(ALLOPTS) /Zm500 /c $*.cpp
>
>$(cobjs): $(includes)
>
>x1.c:      searchr.c search.c repeat.c next.c nextr.c history.c nexte.c \
>           quiesce.c evaluate.c movgen.c make.c unmake.c attacks.c swap.c \
>           boolean.c utility.c valid.c searchmp.c thread.c book.c data.c drawn.c
>\
>           edit.c epd.c epdglue.c init.c input.c interupt.c iterate.c main.c \
>           option.c output.c phase.c ponder.c preeval.c resign.c root.c learn.c
>\
>           setboard.c test.c time.c validate.c annotate.c analyze.c evtest.c
>bench.c \
>           hash.c probe.c
>           copy /b book.c+data.c+drawn.c+edit.c+epd.c+epdglue.c+\
>           init.c+input.c+interupt.c+iterate.c+main.c+option.c+output.c+\
>           phase.c+ponder.c+preeval.c+resign.c+root.c+learn.c+setboard.c+\
>           test.c+time.c+validate.c+annotate.c+analyze.c+evtest.c+bench.c+\
>           hash.c+probe.c+boolean.c+swap.c+attacks.c+evaluate.c+make.c+\
>           unmake.c+movgen.c+quiesce.c+search.c+next.c+searchr.c+repeat.c+\
>           nextr.c+history.c+nexte.c+utility.c+valid.c+searchmp.c+\
>           thread.c x1.c
>clean:
>	   del /q $(cobjs)
>	   del /q egtb.obj
>	   del /q log.*
>	   del /q game.**
>	   del /q *.bak
>	   del /q x1.c
>
>>2. run crafty with the following command "crafty < prof"
>>Note the prof file is below. Make sure you have a normal crafty.rc, book file
>>and EGTB path when you run this and in the same directory as the source as it
>>will create a file that will be used in the second stage.
>
>I have created the "prof" file, and it has no extention like .txr.. correct? Or
>does all the "prof" stuff get put into the normal rc file?
>
>I have never compiled something with PGO options.
>
>Peter

Sorry I gave the Linux switches, it should be "/Qprof_genx /Qprof_dir ." for the
first compile and "/Qprof_use /Qprof_dir ." (Also note the space between dir the
the . this means the prof directory is the current directory). The prof file i
gave you is simply a text file that will run crafty through several different
position. You can name it prof.txt just make sure the command you give to run
for step 2 is "crafty < prof.txt" Also after reading the documentation that
intel provides they recommend that you remove the /Qip & /Qipo for the first
compile and put them back in for the second compile.

Bryan



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.