git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* svn to git, N-squared?
@ 2006-06-12  2:02 Jon Smirl
  2006-06-12  3:31 ` Linus Torvalds
  2006-06-12  4:29 ` Eric Wong
  0 siblings, 2 replies; 23+ messages in thread
From: Jon Smirl @ 2006-06-12  2:02 UTC (permalink / raw)
  To: git

I have Mozilla CVS in a SVN repository. I've been using git-svnimport
to import it. This time I am letting it run to completion; but the
import has been running for four days now and it is only up to 2004.
The import task is stable at 570MB and it is using about 50% of my
CPU. It is constantly spawning off git write-tree, read-tree,
hash-object, update-index. It is not doing excessive disk activity.

The import seems to be getting n-squared slower. It is still making
forward progress but the progress seems to be getting slower and
slower.

It looks like it is doing write-tree, read-tree, hash-object,
update-index once or more per change set. If these commands are
n-proportional and they are getting run n times, then this is a
n-squared process. Projecting this out, the import may take 10 days or
more to completely finish.

-- 
Jon Smirl
jonsmirl@gmail.com

^ permalink raw reply	[flat|nested] 23+ messages in thread
* Re: svn to git, N-squared?
@ 2006-06-12  4:39 linux
  2006-06-12 15:32 ` Jon Smirl
  0 siblings, 1 reply; 23+ messages in thread
From: linux @ 2006-06-12  4:39 UTC (permalink / raw)
  To: git, jonsmirl, torvalds

>	for i in ??
>	do
>		cp -r $i $i.new
>		rm -rf $i
>		mv $i.new $i
>	done
>
> in your .git/objects/ directory (CAREFUL! Any script that does "rm -rf" 
> should be double- and triple-checked for sanity! ;)

Insanity is copying the data rather than just the file name.  Git is
good about not reading unnecessary files, and anything necessary should
be cached, so on-disk fragmentation is not a concern.

rmdir --ignore-fail-on-non-empty ??	# Probably unnecessary.
for i in ??
do
	mkdir $i.new
	mv $i/* $i.new
	rmdir $i
	mv $i.new $i
done

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2006-06-12 19:17 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-12  2:02 svn to git, N-squared? Jon Smirl
2006-06-12  3:31 ` Linus Torvalds
2006-06-12  3:39   ` Jon Smirl
2006-06-12  4:02     ` Linus Torvalds
2006-06-12 19:04       ` Yakov Lerner
2006-06-12 19:17         ` Linus Torvalds
2006-06-12 16:18   ` Randal L. Schwartz
2006-06-12 16:25     ` Randal L. Schwartz
2006-06-12  4:29 ` Eric Wong
  -- strict thread matches above, loose matches on Subject: below --
2006-06-12  4:39 linux
2006-06-12 15:32 ` Jon Smirl
2006-06-12 15:45   ` Linus Torvalds
2006-06-12 15:55     ` Jon Smirl
2006-06-12 16:12       ` Linus Torvalds
2006-06-12 16:22         ` Jon Smirl
2006-06-12 16:32           ` Jon Smirl
2006-06-12 16:57             ` Linus Torvalds
2006-06-12 16:41           ` Linus Torvalds
2006-06-12 16:44             ` Jon Smirl
2006-06-12 17:08               ` Linus Torvalds
2006-06-12 18:06                 ` Jon Smirl
2006-06-12 19:00                   ` Jon Smirl
2006-06-12 16:16     ` Jon Smirl

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).