Skip to content
Tcl Source Code History Of Ticket 2941443
Login

History Of Ticket 2941443

Artifacts Associated With Ticket 2941443

  1. Ticket change [def54f83f7] (rid 114935) by anonymous on 2010-01-28 06:59:41:

    1. assignee initialized to: "dkf"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      expr 9999999**9999999
      and tclsh/eggdrop hangs. :(
      
      But with pow is ok
      % expr pow(9999999,9999999)
      Inf
      
      On 8.6b1.1 works too.
      
    4. foundin initialized to: "obsolete: 8.5.8"
    5. is_private initialized to: "1"
    6. priority initialized to: "5 Medium"
    7. resolution initialized to: "None"
    8. status initialized to: "Open"
    9. subsystem initialized to: "16. Commands A-H"
    10. title initialized to: "expr 9999999**9999999 kills my progs"
    11. type initialized to: "Bug"
  2. Ticket change [6b3408bdbc] (rid 128280) by dkf on 2010-01-28 14:41:22:

    1. assignee changed to: "dgp"
    2. subsystem changed to: "48. Number Handling"
  3. Ticket change [3512917260] (rid 106859) by ferrieux on 2010-01-28 16:00:06:

    1. closedate changed to: "2010-01-28T09:00:06"
    2. closer changed to: "ferrieux"
    3. icomment:
      As stated in  expr.n,  integer operations are done in arbitrary precision (no overflow).
      This is the case of ** when both operands are integer.
      
      So Tcl is not hanging, it is just computing a very large number. You can verify that by monitoring the process's CPU (100%) and memory consumption (increasing regularly). Of course at some point it may exhaust your system's resources, but we can hardly blame Tcl for the hardware not being a true Turing bandwidth with infinite tape ;-)
      
      Hence closing as Invalid.
      
      
    4. login: "ferrieux"
    5. mimetype: "text/plain"
    6. resolution changed to: "Invalid"
    7. status changed to: "Closed"
    8. username: "ferrieux"
  4. Ticket change [105ee9094d] (rid 94965) by ferrieux on 2010-01-28 16:01:42:

    1. icomment:
      Heh, read "true Turing _machine_". So much for focus-follows-mouse ;-)
      
      
    2. login: "ferrieux"
    3. mimetype: "text/plain"
    4. username: "ferrieux"
  5. Ticket change [7344212802] (rid 105017) by anonymous on 2010-01-28 16:11:35:

    1. icomment:
      M... I think so. But if tcl can't calculate this expression for a whole day (and more, we test it more than 24 hours in different computers) it is a bug, IMHO. :)
      
      
    2. login: ""
    3. mimetype: "text/plain"
    4. username: ""
  6. Ticket change [9a759fd4bc] (rid 110945) by ferrieux on 2010-01-28 17:14:24:

    1. icomment:
      
      
      allow_comments - 1
      
      Nonsense. Some algorithms take time, period. If a computation requires a month of CPU and a terabyte of RAM on a helium-cooled supercomputer, giving it to your 3GHz desktop PC with 4G of RAM (and a terabyte of swap ;-) will take generations.
      
      Not a bug.
      
      
      
    2. login: "ferrieux"
    3. mimetype: "text/plain"
    4. username: "ferrieux"
  7. Ticket change [5d91bc8eef] (rid 115488) by dgp on 2010-02-02 01:45:59:

    1. icomment:
      
      Patience, grasshopper.
      
      % time {expr {9999999**9999999}} 1
      466843906 microseconds per iteration
      
      Not even 10 minutes.
      
      
    2. login: "dgp"
    3. mimetype: "text/plain"
    4. username: "dgp"
  8. Ticket change [ac45a799a0] (rid 101263) by ferrieux on 2010-02-02 04:24:35:

    1. icomment:
      Yeah, though converting it to decimal for display may take a while ;-)
      
      
    2. login: "ferrieux"
    3. mimetype: "text/plain"
    4. username: "ferrieux"