Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Touching INCLUDE file cause slow build
Message
De
12/06/2008 15:49:18
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
À
12/06/2008 15:30:22
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de projet
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
01323594
Message ID:
01323600
Vues:
16
>I am working with PRG files rather than VCX files so I have to rebuild to see the effect of a change on my screens. Ergo, a fast build is quite important to me.
>
>I have a test directory where it take 2.4 seconds to build my project. I have two INCLUDE files.
>
>If I "touch" one of my INCLUDE files the build time goes to 6.4 seconds. By "touch" I mean make a trivial change (type space bar) which changes the datetime stamp on the file.
>
>When I say it goes to 6.4 seconds, I mean it doesn't get any better even if I rebuild a number of times. I get times like these;
> 6.407, 6.391, 6.360.
>
>I'm talking about a simple build (no RECOMPILE) parameter.
>
>If I restore the original INCLUDE file (which BeyondCompare says is identical to the touched file) I get these times:
> 6.492, 2.485, 2.490
>
>In this case (fast) the TIMESTAMP in the row of my PJX table for the INCLUDE file goes back to the original value.

Here's my old code which turns a datetime to a timestamp number:
local tmp, str, n, s, D, nHour, nMin, nSec
n=1
do case
case vartype(pParam1)="C"	&& it's a filename
	n=adir(A,pParam1)
	if n>0
		s=A(1,4)
		D=A(1,3)
		nHour=val(subs(s,1,2))
		nMin=val(subs(s,4,2))
		nSec=val(subs(s,7,2))
	endif
case vartype(pParam1)="T"	&& passed a datetime
	D=ttod(pParam1)
	nHour=hour(pParam1)
	nMin=minute(pParam1)
	nSec=sec(pParam1)
other	&& first parameter is a time, second a date
	s=pParam1
	D=pDate
	nHour=val(subs(s,1,2))
	nMin=val(subs(s,4,2))
	nSec=val(subs(s,7,2))
endc
tmp=0
if n>0	&& for n=0 we have a missing file, its timestamp will be zero
	tmp=year(D)-1980
	tmp=bitlshift(tmp,4)+month(D)
	tmp=bitlshift(tmp,5)+day(D)
	tmp=bitlshift(tmp,5)+nHour
	tmp=bitlshift(tmp,6)+nMin
	tmp=bitlshift(tmp,5)+nSec
endif
return  tmp

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform