Fossil

Check-in [b6b7ff79]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Moved the parts taken over by the top. sort passes out the breaker passes, and renumbered them (comments).
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:b6b7ff79ccf41d67015daea1f8baf283c599dda8
User & Date: aku 2007-11-25 03:00:50
Context
2007-11-25
03:05
Moved more parts taken over by the top. sort passes out the breaker passes, and renumbered them. check-in: d743f04b user: aku tags: trunk
03:00
Moved the parts taken over by the top. sort passes out the breaker passes, and renumbered them (comments). check-in: b6b7ff79 user: aku tags: trunk
02:59
Investigation of changeset order differences between running passes 1 to 6 and pass 6 alone show why the topological sort passes are separate in cvs2svn. The breaking of cycles can change the order of things due to different timeranges and dependencies of the broken changesets. Created two new passes for the sorting. The break passes 7 and 8 are now passes 8 and 9, and the new sort passes are 7 and 10. check-in: 66c85b4d user: aku tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to tools/cvs2fossil/lib/c2f_pbreakrcycle.tcl.

45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
..
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
    typemethod setup {} {
	# Define the names and structure of the persistent state of
	# this pass.

	state reading revision
	state reading changeset
	state reading csrevision

	state writing csorder {
	    -- Commit order of changesets based on their dependencies
	    cid INTEGER  NOT NULL  REFERENCES changeset,
	    pos INTEGER  NOT NULL,
	    UNIQUE (cid),
	    UNIQUE (pos)
	}
	return
    }

    typemethod load {} {
	# Pass manager interface. Executed to load data computed by
	# this pass into memory when this pass is skipped instead of
	# executed.

	state reading changeset
	project::rev loadcounter
	return
    }

    typemethod run {} {
	# Pass manager interface. Executed to perform the
	# functionality of the pass.

	cyclebreaker savecmd  [myproc SaveOrder]
	cyclebreaker breakcmd {::vc::fossil::import::cvs::cyclebreaker break}

	state transaction {
	    cyclebreaker run break-rev [myproc Changesets]
	}

	repository printcsetstatistics
................................................................................
	return
    }

    typemethod discard {} {
	# Pass manager interface. Executed for all passes after the
	# run passes, to remove all data of this pass from the state,
	# as being out of date.

	state discard csorder
	return
    }

    # # ## ### ##### ######## #############
    ## Internal methods

    proc Changesets {} {
	return [struct::list filter [project::rev all] [myproc IsByRevision]]
    }

    proc IsByRevision {cset} { $cset byrevision }

    proc SaveOrder {graph at cset} {
	set cid [$cset id]

	log write 4 breakrcycle "Comitting @ $at: [$cset str]"
	state run {
	    INSERT INTO csorder (cid,  pos)
	    VALUES              ($cid, $at)
	}
	# MAYBE TODO: Write the project level changeset dependencies as well.
	return
    }

    # # ## ### ##### ######## #############
    ## Configuration

    pragma -hasinstances   no ; # singleton
    pragma -hastypeinfo    no ; # no introspection
    pragma -hastypedestroy no ; # immortal








<
<
<
<
<
<
<
<







<
<
<







<







 







<
<












<
<
<
<
<
<
<
<
<
<
<
<







45
46
47
48
49
50
51








52
53
54
55
56
57
58



59
60
61
62
63
64
65

66
67
68
69
70
71
72
..
73
74
75
76
77
78
79


80
81
82
83
84
85
86
87
88
89
90
91












92
93
94
95
96
97
98
    typemethod setup {} {
	# Define the names and structure of the persistent state of
	# this pass.

	state reading revision
	state reading changeset
	state reading csrevision








	return
    }

    typemethod load {} {
	# Pass manager interface. Executed to load data computed by
	# this pass into memory when this pass is skipped instead of
	# executed.



	return
    }

    typemethod run {} {
	# Pass manager interface. Executed to perform the
	# functionality of the pass.


	cyclebreaker breakcmd {::vc::fossil::import::cvs::cyclebreaker break}

	state transaction {
	    cyclebreaker run break-rev [myproc Changesets]
	}

	repository printcsetstatistics
................................................................................
	return
    }

    typemethod discard {} {
	# Pass manager interface. Executed for all passes after the
	# run passes, to remove all data of this pass from the state,
	# as being out of date.


	return
    }

    # # ## ### ##### ######## #############
    ## Internal methods

    proc Changesets {} {
	return [struct::list filter [project::rev all] [myproc IsByRevision]]
    }

    proc IsByRevision {cset} { $cset byrevision }













    # # ## ### ##### ######## #############
    ## Configuration

    pragma -hasinstances   no ; # singleton
    pragma -hastypeinfo    no ; # no introspection
    pragma -hastypedestroy no ; # immortal

Changes to tools/cvs2fossil/lib/c2f_pbreakscycle.tcl.

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# you should have received as part of this distribution.
#
# This software consists of voluntary contributions made by many
# individuals.  For exact contribution history, see the revision
# history and logs, available at http://fossil-scm.hwaci.com/fossil
# # ## ### ##### ######## ############# #####################

## Pass VII. This pass goes over the set of symbol based changesets
## and breaks all dependency cycles they may be in. We need a
## dependency tree. Identical to pass VI, except for the selection of
## the changesets.

# # ## ### ##### ######## ############# #####################
## Requirements








|







6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# you should have received as part of this distribution.
#
# This software consists of voluntary contributions made by many
# individuals.  For exact contribution history, see the revision
# history and logs, available at http://fossil-scm.hwaci.com/fossil
# # ## ### ##### ######## ############# #####################

## Pass VIII. This pass goes over the set of symbol based changesets
## and breaks all dependency cycles they may be in. We need a
## dependency tree. Identical to pass VI, except for the selection of
## the changesets.

# # ## ### ##### ######## ############# #####################
## Requirements