jgraley / inferno-cpp2v

2 stars 0 forks source link

Detection of out of order tree zones #722

Closed jgraley closed 1 month ago

jgraley commented 1 year ago

From #718 we can only preserve tree zones when their DF order is unchanged relative to each other. I.e. if there's been a "swap", one of them will have to be duplicated. Need to use free zones to spot the swaps, so maybe do this after #721 - but then, you'd have to redo #721 because there would be more free zones due to the new duplicates. So no, use the free zones as they are, maybe walking though them.

jgraley commented 1 year ago

Will need an alternative Execute() like method for a pseudo-run of the CS. It produces maps relating zones to the zones attached to their terminii. Need FreeZone terminii in DF order #719 for this to work.

We now believe that the Duplicate action can be done immediately as a CST right here.

A DB structure that tracks subtree size might help us choose the smallest tree zone to duplicate.

Important: to detect mis-orderings, we need an ordering to compare against. But this is none other than the current value of the DF ordering itself, in the DB. So that's alright then.