{"thread":{"id":"3819","subject":"blame now knows -S","startedAt":"2006-04-07T09:28:40Z","lastAt":"2006-04-08T20:39:04Z","messageCount":5,"participants":["Junio C Hamano","Fredrik Kuivinen","Marco Costalba"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"18447","messageId":"7v1ww9loon.fsf@assigned-by-dhcp.cox.net","threadId":"3819","inReplyTo":null,"subject":"blame now knows -S","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-04-07T09:28:40Z","receivedAt":"2006-04-07T09:28:40Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"I've made a few changes to \"git blame\" myself:\n\n - fix breakage caused by recent revision walker reorganization;\n - use built-in xdiff instead of spawning GNU diff;\n - implement -S <ancestry-file> like annotate does.\n\nDepending on the density of changes, it now appears that blame\nis 10%-30% faster than annotate.  I thought CVS emulator might\nbe interested to give it a whirl..\n"},{"id":"18448","messageId":"7vu095k9yi.fsf@assigned-by-dhcp.cox.net","threadId":"3819","inReplyTo":"7v1ww9loon.fsf@assigned-by-dhcp.cox.net","subject":"Re: blame now knows -S","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-04-07T09:32:05Z","receivedAt":"2006-04-07T09:32:05Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Junio C Hamano <junkio@cox.net> writes:\n\n> I've made a few changes to \"git blame\" myself:\n>\n>  - fix breakage caused by recent revision walker reorganization;\n>  - use built-in xdiff instead of spawning GNU diff;\n>  - implement -S <ancestry-file> like annotate does.\n>\n> Depending on the density of changes, it now appears that blame\n> is 10%-30% faster than annotate.  I thought CVS emulator might\n> be interested to give it a whirl..\n\nSorry, forgot to mention... The updated blame will be in \"next\",\nnot in \"master\" yet.\n"},{"id":"18467","messageId":"20060408114240.GA10137@c165.ib.student.liu.se","threadId":"3819","inReplyTo":"7v1ww9loon.fsf@assigned-by-dhcp.cox.net","subject":"Re: blame now knows -S","fromName":"Fredrik Kuivinen","fromEmail":"freku045@student.liu.se","sentAt":"2006-04-08T11:42:40Z","receivedAt":"2006-04-08T11:42:40Z","isPatch":false,"sender":{"key":"frekui@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13770967?v=4"},"body":"On Fri, Apr 07, 2006 at 02:28:40AM -0700, Junio C Hamano wrote:\n> I've made a few changes to \"git blame\" myself:\n> \n>  - fix breakage caused by recent revision walker reorganization;\n>  - use built-in xdiff instead of spawning GNU diff;\n>  - implement -S <ancestry-file> like annotate does.\n> \n> Depending on the density of changes, it now appears that blame\n> is 10%-30% faster than annotate.  I thought CVS emulator might\n> be interested to give it a whirl..\n> \n\nNice work!\n\nThere is another possible optimisation with respect to xdiff. Instead\nof producing the diff on the xdiff side and parsing the diff in\nblame.c, we could add another call back which just gets the relevant\ninformation from the hunk header. I don't know how much we would gain\nfrom this, but it might be worth a try.\n\n- Fredrik\n"},{"id":"18468","messageId":"e5bfff550604080653l2c73f844n8e03e55f9c467039@mail.gmail.com","threadId":"3819","inReplyTo":"20060408114240.GA10137@c165.ib.student.liu.se","subject":"Re: blame now knows -S","fromName":"Marco Costalba","fromEmail":"mcostalba@gmail.com","sentAt":"2006-04-08T13:53:56Z","receivedAt":"2006-04-08T13:53:56Z","isPatch":false,"sender":{"key":"mcostalba@gmail.com","avatar":null},"body":"On 4/8/06, Fredrik Kuivinen <freku045@student.liu.se> wrote:\n> On Fri, Apr 07, 2006 at 02:28:40AM -0700, Junio C Hamano wrote:\n> > I've made a few changes to \"git blame\" myself:\n> >\n> >  - fix breakage caused by recent revision walker reorganization;\n> >  - use built-in xdiff instead of spawning GNU diff;\n> >  - implement -S <ancestry-file> like annotate does.\n> >\n> > Depending on the density of changes, it now appears that blame\n> > is 10%-30% faster than annotate.  I thought CVS emulator might\n> > be interested to give it a whirl..\n> >\n>\n> Nice work!\n>\n> There is another possible optimisation with respect to xdiff. Instead\n> of producing the diff on the xdiff side and parsing the diff in\n> blame.c, we could add another call back which just gets the relevant\n> information from the hunk header. I don't know how much we would gain\n> from this, but it might be worth a try.\n>\n\nIf I can comment on this thread, I would like to note IMHO that given\nthe differences in\nlanguages (C vs Perl) and the use of almost the same algorithm, just a\n10%-30% in speed difference between blame and annotate it means that\nany further optimization can gain little because the bottleneck is\nelsewhere.\n\nAnd I think is in getting the revision's history. Call it\ngit-rev-list, although both\nblame and annotate use directly the library revision.h\n\nAfter the new xdiff merge, git-rev-list accounts for almost whole the time.\nNormally more then 80% in qgit.\n\nAlthough the qgit annotation algorithm is different from both blame\nand annotate I think\nthat a faster git-rev-list <path> or revison history walker as you may\nwant to call it it's a key\nin really speed-up annotation stuff.\n\n    Marco\n"},{"id":"18478","messageId":"7vwtdzer9z.fsf@assigned-by-dhcp.cox.net","threadId":"3819","inReplyTo":"20060408114240.GA10137@c165.ib.student.liu.se","subject":"Re: blame now knows -S","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-04-08T20:39:04Z","receivedAt":"2006-04-08T20:39:04Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Fredrik Kuivinen <freku045@student.liu.se> writes:\n\n> There is another possible optimisation with respect to xdiff. Instead\n> of producing the diff on the xdiff side and parsing the diff in\n> blame.c, we could add another call back which just gets the relevant\n> information from the hunk header. I don't know how much we would gain\n> from this, but it might be worth a try.\n\nI've tried and then it turned out it did not make much of a\ndifference.\n"}]}