emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Long lines and bidi


From: Dmitry Antipov
Subject: Re: Long lines and bidi
Date: Mon, 11 Feb 2013 11:54:57 +0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130107 Thunderbird/17.0.2

On 02/11/2013 09:43 AM, Dmitry Antipov wrote:

Yet another interesting profile (generated by scroll-both micro-benchmark with
r111730) is shown below.

Input is 4K lines, each line is ~27K bytes, Imla'ei (modern Arabic) script. IIUC
this R2L text with long lines should push bidi really hard, but ... bidi core
routines (by itself) are almost irrelevant in the profile:

     39.96%        emacs  emacs                          [.] scan_buffer
     28.72%        emacs  emacs                          [.] 
buf_charpos_to_bytepos
     21.82%        emacs  emacs                          [.] 
buf_bytepos_to_charpos
      0.59%        emacs  emacs                          [.] re_match_2_internal

... and with Paul's mem(r)chr patch it is:

    43.38%        emacs  emacs                          [.] 
buf_charpos_to_bytepos
    28.42%        emacs  emacs                          [.] 
buf_bytepos_to_charpos
    13.10%        emacs  libc-2.16.so                   [.] memrchr
     0.85%        emacs  emacs                          [.] re_match_2_internal
...

So I should vote YES. This is simple optimization which really makes sense,
and I suspect that the "less usual" input is, the more sense it has.

Dmitry




reply via email to

[Prev in Thread] Current Thread [Next in Thread]