Skip to content
Tcl Source Code History Of Ticket 1693802
Login

History Of Ticket 1693802

Artifacts Associated With Ticket 1693802

  1. Ticket change [3fa8480ee8] (rid 121500) by msofer on 2007-04-03 17:51:10:

    1. assignee initialized to: "msofer"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      Attached a patch that avoids calling out to TEOVi when possible.
      
    4. foundin initialized to: "None"
    5. is_private initialized to: "0"
    6. priority initialized to: "5 Medium"
    7. resolution initialized to: "None"
    8. status initialized to: "Open"
    9. submitter initialized to: "msofer"
    10. subsystem initialized to: "47. Bytecode Compiler"
    11. title initialized to: "INST_INVOKE speedup"
    12. type initialized to: "Patch"
  2. Add attachment "instInvoke.patch" [0e60ac7241] (rid 94605) by msofer on 2007-04-04 00:51:10.

  3. Ticket change [7e3fed1165] (rid 97377) by msofer on 2007-04-04 00:51:12:

    1. icomment:
      
      
      File Added - 223596: instInvoke.patch
      
      
      
    2. login: "msofer"
    3. mimetype: "text/plain"
    4. username: "msofer"
  4. Ticket change [8a53cdffc4] (rid 127378) by msofer on 2007-04-04 05:55:57:

    1. closedate changed to: "2007-04-03T22:55:57"
    2. closer changed to: "msofer"
    3. resolution changed to: "Accepted"
    4. status changed to: "Closed"
  5. Ticket change [8e39930868] (rid 120071) by dgp on 2007-04-04 11:06:35:

    1. icomment:
      Logged In: YES 
      user_id=80530
      Originator: NO
      
      
      I dislike this.  Adding another
      command dispatch location just
      invites divergence, leading to
      more problems like 582506.
      
      I assume the speedup must be
      compelling for you to go ahead
      with this anyway.  Which suggests
      it's our old mystery of "why do
      function calls out of TEBC cost
      so much?"  When the genie next grants
      us wishes, I'd rather we figure that
      out and solve that, than do things like this.
      
      If you stick with this commit, at
      least add some comments in
      the TEOVI routine that any changes
      made there need to be examined for
      possible copying over to the
      INST_INVOKE area.
      
      
      
      
    2. login: "dgp"
    3. mimetype: "text/plain"
    4. username: "dgp"
  6. Ticket change [5898841795] (rid 117834) by msofer on 2007-04-04 20:21:29:

    1. icomment:
      Logged In: YES 
      user_id=148712
      Originator: YES
      
      Those comments will be added, thank you.
      
      I did not run the full benchmark suite, but did see 10-20% speed improvements in the OO microbenchmarks for different OO systems.
      
      As to the mistery about "calling out of TEBC is expensive", my comments are:
      
      (1) that is surely a bad explanation: the new code does one function call out of TEBC (possibly more), just like the old one
      
      (2) here we are inlining a very specialised version of TEOvI: flags==0, no traces, the Command is already known to exist and known. IOW, we are replacing a 100+ loc function (assuming ~50% comments) with 10 loc in TEBC. In Chuck Moore's manner of speaking: we are deciding many things at edit time (like flags=0) instead of checking at run time.
      
      (3) Very aggressive refactoring could be a different way of attaining similar results, but I am not sure that TEOvI_reallyInternalCircle0Ex() would be an addition that would make maintenance much easier ;)
      
      My guess is that (2) has positive effects on cache behaviour, possibly depending on how clever the compiler/cpu combination is about prefetching. The effect might also be obtained with good compiler hints, but those tend to be non-portable (eg, gcc's __builtin_expect for branches) and also harder to maintain.
      
      
    2. login: "msofer"
    3. mimetype: "text/plain"
    4. username: "msofer"