Skip to content
Tcl Source Code History Of Ticket 2910094fffffffffffffffffffffffffffffffff
Login

History Of Ticket 2910094fffffffffffffffffffffffffffffffff

Artifacts Associated With Ticket 2910094fffffffffffffffffffffffffffffffff

  1. Ticket change [dd9ad2444f] (rid 114700) by msofer on 2009-12-07 16:14:34:

    1. assignee initialized to: "andreas_kupries"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      % proc stack {} {
          puts LEVEL:[set lev [info frame]]
          for {set i 1} {$i < $lev} {incr i} {
      puts [info frame $i]
          }
      }
      % stack
      LEVEL:2
      type eval line 1 cmd stack level 1
      % proc a {} stack
      % a
      LEVEL:3
      type eval line 1 cmd a level 2
      type proc line 1 cmd stack proc ::a level 1
      % coroutine aa a
      LEVEL:5
      bad level "1"
      
      
    4. foundin initialized to: "obsolete: 8.6b1.1"
    5. is_private initialized to: "0"
    6. priority initialized to: "8"
    7. resolution initialized to: "None"
    8. status initialized to: "Open"
    9. submitter initialized to: "msofer"
    10. subsystem initialized to: "17. Commands I-L"
    11. title initialized to: "[info frame] broken in coros"
    12. type initialized to: "Bug"
  2. Add attachment "infoframedebug.tcl" [cc44a495b9] (rid 95664) by andreas_kupries on 2009-12-08 02:18:23.

  3. Ticket change [457fe9c4a9] (rid 99360) by andreas_kupries on 2009-12-08 02:18:23:

    1. icomment:
      
      
      File Added - 354261: infoframedebug.tcl
      
      
      
    2. login: "andreas_kupries"
    3. mimetype: "text/plain"
    4. username: "andreas_kupries"
  4. Ticket change [b4cfbb0efa] (rid 125108) by andreas_kupries on 2009-12-08 02:53:54:

    1. icomment:
      I confirm, using my own frame dumper (which starts from the current from down to 1, so I am able to see some output before it croaks, my code is attached here). Output is
      
      andreask@gila:~/workbench/Coro280> ./install/tcl86/bin/tclsh8.6
      % source infoframedebug.tcl
      % debugframes
      FRAME   2 {type source line 6 file infoframedebug.tcl cmd {info frame $level} proc ::debugframes level 0}
      FRAME   1 {type eval line 1 cmd debugframes level 1}
      
      % proc a {} debugframes
      % a
      FRAME   3 {type source line 6 file infoframedebug.tcl cmd {info frame $level} proc ::debugframes level 0}
      FRAME   2 {type proc line 1 cmd debugframes proc ::a level 1}
      FRAME   1 {type eval line 1 cmd a level 2}
      
      % coroutine aa a
      FRAME   5 {type source line 6 file infoframedebug.tcl cmd {info frame $level} proc ::debugframes level 0}
      FRAME   4 {type proc line 1 cmd debugframes proc ::a level 1}
      FRAME   3 {type eval line 1 cmd a}
      FRAME   2 {type eval line 1 cmd {coroutine aa a} level 2}
      bad level "1"
      % exit
      
      It seems the trouble is where it tries to access the stack frames above the coroutine invokation.
      
      The bad level is either thrown for out of range, or, for in-range numbers, if the loop in lines 1142-1148 (tclCmIL.c, rev 1.174) is not finding a frame. That would indicate that the framePtr->nextPtr chain is broken at the point of main to coro transition.
      
      This is likely managed in the code switching between coros, right ?
      
      
      
    2. login: "andreas_kupries"
    3. mimetype: "text/plain"
    4. username: "andreas_kupries"
  5. Ticket change [0ece787398] (rid 94682) by andreas_kupries on 2009-12-08 02:53:59:

    1. icomment:
      I confirm, using my own frame dumper (which starts from the current from down to 1, so I am able to see some output before it croaks, my code is attached here). Output is
      
      andreask@gila:~/workbench/Coro280> ./install/tcl86/bin/tclsh8.6
      % source infoframedebug.tcl
      % debugframes
      FRAME   2 {type source line 6 file infoframedebug.tcl cmd {info frame $level} proc ::debugframes level 0}
      FRAME   1 {type eval line 1 cmd debugframes level 1}
      
      % proc a {} debugframes
      % a
      FRAME   3 {type source line 6 file infoframedebug.tcl cmd {info frame $level} proc ::debugframes level 0}
      FRAME   2 {type proc line 1 cmd debugframes proc ::a level 1}
      FRAME   1 {type eval line 1 cmd a level 2}
      
      % coroutine aa a
      FRAME   5 {type source line 6 file infoframedebug.tcl cmd {info frame $level} proc ::debugframes level 0}
      FRAME   4 {type proc line 1 cmd debugframes proc ::a level 1}
      FRAME   3 {type eval line 1 cmd a}
      FRAME   2 {type eval line 1 cmd {coroutine aa a} level 2}
      bad level "1"
      % exit
      
      It seems the trouble is where it tries to access the stack frames above the coroutine invokation.
      
      The bad level is either thrown for out of range, or, for in-range numbers, if the loop in lines 1142-1148 (tclCmIL.c, rev 1.174) is not finding a frame. That would indicate that the framePtr->nextPtr chain is broken at the point of main to coro transition.
      
      This is likely managed in the code switching between coros, right ?
      
      
      
    2. login: "andreas_kupries"
    3. mimetype: "text/plain"
    4. username: "andreas_kupries"
  6. Ticket change [d9c62b7c27] (rid 107670) by andreas_kupries on 2009-12-08 02:55:46:

    1. icomment:
      
      
      IP - Comment Removed: 204.244.102.2
      
      
      
    2. login: "andreas_kupries"
    3. mimetype: "text/plain"
    4. username: "andreas_kupries"
  7. Ticket change [0a85f27b51] (rid 113832) by andreas_kupries on 2009-12-08 02:57:20:

    1. icomment:
      An alternative is that the calculation of levels in the coroutine is off by one, i.e. that info frame should show only the coro stack up to what we see in my output as level 2.
      
      
    2. login: "andreas_kupries"
    3. mimetype: "text/plain"
    4. username: "andreas_kupries"
  8. Ticket change [478ef255d0] (rid 99723) by andreas_kupries on 2009-12-08 02:59:48:

    1. icomment:
      Assuming the alternative is true the fix would be to remove the +1 in line 1103 of file tclCmdIL.c, rev 1.174.
      
      
    2. login: "andreas_kupries"
    3. mimetype: "text/plain"
    4. username: "andreas_kupries"
  9. Ticket change [8a92ae0b3d] (rid 127414) by msofer on 2009-12-08 03:50:12:

    1. closedate changed to: "2009-12-07T20:50:12"
    2. closer changed to: "msofer"
    3. icomment:
      
      
      allow_comments - 1
      
      That did it; committed.
      
      
    4. login: "msofer"
    5. mimetype: "text/plain"
    6. resolution changed to: "Fixed"
    7. status changed to: "Closed"
    8. username: "msofer"