<table><tr><td style="">jtamate added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D11487">View Revision</a></tr></table><br /><div><div><blockquote style="border-left: 3px solid #8C98B8;
          color: #6B748C;
          font-style: italic;
          margin: 4px 0 12px 0;
          padding: 8px 12px;
          background-color: #F8F9FC;">
<div style="font-style: normal;
          padding-bottom: 4px;">In <a href="https://phabricator.kde.org/D11487#232497" style="background-color: #e7e7e7;
          border-color: #e7e7e7;
          border-radius: 3px;
          padding: 0 4px;
          font-weight: bold;
          color: black;text-decoration: line-through;">D11487#232497</a>, <a href="https://phabricator.kde.org/p/mwolff/" style="
              border-color: #f1f7ff;
              color: #19558d;
              background-color: #f1f7ff;
                border: 1px solid transparent;
                border-radius: 3px;
                font-weight: bold;
                padding: 0 4px;">@mwolff</a> wrote:</div>
<div style="margin: 0;
          padding: 0;
          border: 0;
          color: rgb(107, 116, 140);"><p><a href="https://phabricator.kde.org/p/jtamate/" style="
              border-color: #f1f7ff;
              color: #19558d;
              background-color: #f1f7ff;
                border: 1px solid transparent;
                border-radius: 3px;
                font-weight: bold;
                padding: 0 4px;">@jtamate</a> I just checked, the function is called with the same parameters for me locally. What output do you get for this:</p>

<p>For me this is the interesting bit:</p>

<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">15.097 debug: unknown[unknown:0]: [ (0, 0)  ->  (0, 358720) ] "" true false
15.097 debug: unknown[unknown:0]: 0 1979 358720
23.013 debug: unknown[unknown:0]: [ (5, 0)  ->  (5, 162682) ] "" true false
23.013 debug: unknown[unknown:0]: 5 12 162682</pre></div></div>
</blockquote>



<blockquote style="border-left: 3px solid #a7b5bf; color: #464c5c; font-style: italic; margin: 4px 0 12px 0; padding: 4px 12px; background-color: #f8f9fc;"><p>So for line 0 I should actually get quite abysmal performance too, worst case 1979 * 358720, but it flies right through here... Now I wonder what kind of CPU you are using? I have a i7-5600U CPU @ 2.60GHz here in my laptop, which has:</p>

<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="console" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);"><span style="color: #000080">$ lstopo --of console</span>
<span style="color: #808080">Machine (11GB)</span>
<span style="color: #808080">  Package L#0 + L3 L#0 (4096KB)</span>
<span style="color: #808080">    L2 L#0 (256KB) + L1d L#0 (32KB) + L1i L#0 (32KB) + Core L#0</span>
<span style="color: #808080">      PU L#0 (P#0)</span>
<span style="color: #808080">      PU L#1 (P#1)</span>
<span style="color: #808080">    L2 L#1 (256KB) + L1d L#1 (32KB) + L1i L#1 (32KB) + Core L#1</span>
<span style="color: #808080">      PU L#2 (P#2)</span>
<span style="color: #808080">      PU L#3 (P#3)</span>
<span style="color: #808080"></span></pre></div>

<p>The 1979 entries of attributes (each 12byte large) produce ~24KB of data, which fits nicely within my L1 cache. Maybe I'm just lucky and this is what hides this issue from me?</p></blockquote>

<p>Same debug output.</p>

<p>AMD Phenom(tm) II X6 1100T Processor, 3.30 GHz<br />
Machine (16GB)</p>

<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">Package L#0 + L3 L#0 (6144KB)
  L2 L#0 (512KB) + L1d L#0 (64KB) + L1i L#0 (64KB) + Core L#0 + PU L#0 (P#0)
  L2 L#1 (512KB) + L1d L#1 (64KB) + L1i L#1 (64KB) + Core L#1 + PU L#1 (P#1)
  L2 L#2 (512KB) + L1d L#2 (64KB) + L1i L#2 (64KB) + Core L#2 + PU L#2 (P#2)
  L2 L#3 (512KB) + L1d L#3 (64KB) + L1i L#3 (64KB) + Core L#3 + PU L#3 (P#3)
  L2 L#4 (512KB) + L1d L#4 (64KB) + L1i L#4 (64KB) + Core L#4 + PU L#4 (P#4)
  L2 L#5 (512KB) + L1d L#5 (64KB) + L1i L#5 (64KB) + Core L#5 + PU L#5 (P#5)</pre></div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R39 KTextEditor</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D11487">https://phabricator.kde.org/D11487</a></div></div><br /><div><strong>To: </strong>jtamate, Frameworks, Kate, cullmann<br /><strong>Cc: </strong>anthonyfieroni, dhaumann, mwolff, cullmann, michaelh, kevinapavew, ngraham, demsking, sars<br /></div>