Loading ...
Sorry, an error occurred while loading the content.

Re: Vim eats 100% CPU on loss of tty

Expand Messages
  • Aron Griffis
    Hello Bram, Bram Moolenaar wrote: [Sat Feb 2 2002, 6:03:25AM EST] ... Good call, it seems to work fine when the Python interpreter isn t included. However
    Message 1 of 9 , Feb 2, 2002
    • 0 Attachment
      Hello Bram,

      Bram Moolenaar wrote: [Sat Feb 2 2002, 6:03:25AM EST]
      > I'm not convinced this is a problem in Vim itself. It's possibly a
      > problem in a library function. Did you try compiling without python?

      Good call, it seems to work fine when the Python interpreter isn't
      included. However Gentoo Linux developers generally prefer Python over
      other interpreters, so it seems a shame to leave it out. Do you know
      how it should be fixed, or at least band-aid the problem?

      IMHO, these kinds of bugs are pretty important to fix (even if
      ultimately the problem lies in Python). Vim is made much more powerful
      by the ability to script it in multiple languages.

      There is also a bug in the tcl interpreter that I've noticed, so I leave
      it out of the Gentoo build. When I use --enable-tclinterp, then the
      following command never returns:

      VIMINIT='let OS = system("uname -s")' vim

      Thanks,
      Aron

      --
      Aron Griffis
      Tru64 UNIX LAN Drivers
      Compaq Computer Corporation, ZKO3-3/T30
    • Bram Moolenaar
      ... I can t reproduce the problem (on FreeBSD), so at least it depends on the system. It has something to do with threads and signals. Using the python
      Message 2 of 9 , Feb 2, 2002
      • 0 Attachment
        Aron Griffis wrote:

        > Bram Moolenaar wrote: [Sat Feb 2 2002, 6:03:25AM EST]
        > > I'm not convinced this is a problem in Vim itself. It's possibly a
        > > problem in a library function. Did you try compiling without python?
        >
        > Good call, it seems to work fine when the Python interpreter isn't
        > included. However Gentoo Linux developers generally prefer Python over
        > other interpreters, so it seems a shame to leave it out. Do you know
        > how it should be fixed, or at least band-aid the problem?

        I can't reproduce the problem (on FreeBSD), so at least it depends on
        the system. It has something to do with threads and signals. Using the
        python interface introduces threads.

        > IMHO, these kinds of bugs are pretty important to fix (even if
        > ultimately the problem lies in Python). Vim is made much more powerful
        > by the ability to script it in multiple languages.

        It might not be so easy to fix this bug. Perhaps there is a version of
        Python without threads? Or a thread-safe version of the libraries? On
        my system I must compile with "-pthread" to avoid problems.

        > There is also a bug in the tcl interpreter that I've noticed, so I leave
        > it out of the Gentoo build. When I use --enable-tclinterp, then the
        > following command never returns:
        >
        > VIMINIT='let OS = system("uname -s")' vim

        Works fine for me (on FreeBSD again).

        --
        hundred-and-one symptoms of being an internet addict:
        161. You get up before the sun rises to check your e-mail, and you
        find yourself in the very same chair long after the sun has set.

        /// Bram Moolenaar -- Bram@... -- http://www.moolenaar.net \\\
        ((( Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim )))
        \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org ///
      • Aron Griffis
        Bram Moolenaar wrote: [Sat Feb 2 2002, 1:37:18PM EST] ... I ll investigate these questions. Gcc doesn t have a -pthread option. I know that leaving threads
        Message 3 of 9 , Feb 2, 2002
        • 0 Attachment
          Bram Moolenaar wrote: [Sat Feb 2 2002, 1:37:18PM EST]
          > It might not be so easy to fix this bug. Perhaps there is a version of
          > Python without threads? Or a thread-safe version of the libraries? On
          > my system I must compile with "-pthread" to avoid problems.

          I'll investigate these questions. Gcc doesn't have a -pthread option.
          I know that leaving threads out would be unfortunate for my friend who
          writes Python-based threaded Vim plugins. :-)

          Does the Perl interpreter not have this problem, even when threads are
          enabled? If not, I wonder what the difference is.

          > > There is also a bug in the tcl interpreter that I've noticed, so I leave
          > > it out of the Gentoo build. When I use --enable-tclinterp, then the
          > > following command never returns:
          > >
          > > VIMINIT='let OS = system("uname -s")' vim
          >
          > Works fine for me (on FreeBSD again).

          I spent a while trying to debug this on Linux and didn't get that far.
          But I didn't care much about the tcl interpreter, so finally I just left
          it out of the Gentoo ebuild.

          Thanks,
          Aron

          --
          Aron Griffis
          Tru64 UNIX LAN Drivers
          Compaq Computer Corporation, ZKO3-3/T30
        • Matthew Hawkins
          ... It does on FreeBSD, where it signals that ld should link with the reentrant version of libc instead of the non-reentrant version. This is because the
          Message 4 of 9 , Feb 2, 2002
          • 0 Attachment
            On Sat, 02 Feb 2002, Aron Griffis wrote:
            > I'll investigate these questions. Gcc doesn't have a -pthread option.

            It does on FreeBSD, where it signals that ld should link with the
            reentrant version of libc instead of the non-reentrant version.
            This is because the pthread library functions are in the reentrant
            version of libc and not a separate pthread library. It also supposedly
            alters a few other library functions so they are thread safe.

            I've seen the problem here on a Linux box twice in the past month or
            so, it's also an SMP system so I don't know if that matters or not.
            I never ssh into my freebsd box so I've never noticed it on that
            platform. I haven't seen it happen on Solaris either, though that's
            through lack of trying ;)

            --
            Matt
          • Denis Perelyubskiy
            ... [...] actually, my vim is -python , and i recently saw the same thing.... sorry, did not attach to the process. will do the next time it happens... denis
            Message 5 of 9 , Feb 10, 2002
            • 0 Attachment
              * Aron Griffis <agriffis@...> [02-Feb-02 10:15 -0800]:
              >
              >Hello Bram,
              >
              >Bram Moolenaar wrote: [Sat Feb 2 2002, 6:03:25AM EST]
              >> I'm not convinced this is a problem in Vim itself. It's possibly a
              >> problem in a library function. Did you try compiling without python?
              >
              >Good call, it seems to work fine when the Python interpreter isn't
              >included. However Gentoo Linux developers generally prefer Python over
              >other interpreters, so it seems a shame to leave it out. Do you know
              >how it should be fixed, or at least band-aid the problem?
              [...]

              actually, my vim is '-python', and i recently saw the same
              thing.... sorry, did not attach to the process. will do the
              next time it happens...

              denis

              --
              // mailto: Denis Perelyubskiy <denisp@...>
              // icq : 12359698
              // PGP : http://www.cs.ucla.edu/~denisp/files/pgp.asc
            Your message has been successfully submitted and would be delivered to recipients shortly.