stevedlawrence opened a new pull request #335: Fix performance regression 
related to alignment
URL: https://github.com/apache/incubator-daffodil/pull/335
 
 
   Commit 356291c3f5 changed how priorPotentialTerms worked (for the
   better) to remove the tuple. The purpose of the second value in tuple
   was to optionally contain the parent model group term if there were no
   prior terms or if this was an unordered sequence. This was confusing and
   probably not originally a good idea, and it wasn't even documented.
   
   When removing backpointers in the aforementioned commit, the alignment
   logic was changed to replace optEnclosingParent (assigned from the
   second tuple value) with immediatelyEnclosingModelGroup, a seemingly
   logical replacement based on the name. But optEnclosingParent was just
   poorly named since it was really just the enclosing parent if this term
   had no prior siblings or was in an unordered sequence. By using
   imediatelyEnclosingModelGroup, which always exist except for root, we
   always included the parent alignment even when it couldn't have an
   affect on a terms alignment. This meant we could insert unnecessary
   alignment processors and caused a pretty drastic reduction in
   performance in some cases.
   
   This changes the logic so we only ever include the parent alignment if
   it could have an affect and this terms alignment, and does so without
   the need of a confusing tuple.
   
   DAFFODIL-2299

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to