Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 45e5943db5b84be8de8d727e7eb14767c4755ca1
Ticket: 716b427f76f8f97a8d9a06043903c53bb2b592c2
Suboptimal bytecode for $a[unset a]
User & Date: sebres on 2017-05-30 16:35:07
Changes

  1. icomment:
    Indeed it is pretty reproduceable (almost 2 times slower):
    
    <code><pre>
    % timerate -calibrate {}
    % proc foo {a} { upvar 1 $a[unset a] b }
    % timerate {foo x}
    0.535961 µs/# 1715950 # 1865807 #/sec 919.682 nett-ms
    </pre></code>
    
    If I recompile it with change "#if 1" as "#if 0" (from [fc9ed1e751180816384d569101950c1f8c4582ad]):
    
    <code><pre>
    % timerate -calibrate {}
    % proc foo {a} { upvar 1 $a[unset a] b }
    % timerate {foo x}
    0.333065 µs/# 2635747 # 3002417 #/sec 877.875 nett-ms
    </pre></code>
    
  2. login: "sebres"
  3. mimetype: "text/x-fossil-wiki"