unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Several problems
@ 2014-07-28 11:24 David Kastrup
  2014-07-28 12:09 ` Dmitry Antipov
  2014-07-28 12:32 ` martin rudalics
  0 siblings, 2 replies; 19+ messages in thread
From: David Kastrup @ 2014-07-28 11:24 UTC (permalink / raw)
  To: emacs-devel


Current master (as of

    commit c7dc7052d94a19476bd8037d680162fd7f51c361
    Merge: 399fe8b aab3459
    Author: Glenn Morris <rgm@gnu.org>
    Date:   Mon Jul 28 05:39:09 2014 -0400

        Merge from emacs-24; up to r117412

in the Git mirror) has several problems for me.  Gnus startup fails to
connect to my POP server (via TLS/SSL) as well as the NNTP server at
news.gmane.org.  I can go through with C-g, go from *Group* into
*Server* with ^, then open the NNTP server from *there*.

Reverting

    commit 4c19675328d0de84cc3181cfc118973f591e8243
    Author: Dmitry Antipov <dmantipov@yandex.ru>
    Date:   Mon Jul 28 10:28:15 2014 +0400

        On GNU/Linux, use timerfd for asynchronous timers.
        * configure.ac (toplevel): Check whether GNU/Linux-specific
        timerfd functions and macros are available.
        * m4/clock_time.m4 (gl_CLOCK_TIME): Check for clock_getres as well.
        * src/atimer.c (toplevel) [HAVE_TIMERFD]: Include sys/timerfd.h.
        (toplevel): Rename alarm_timer_ok to special_timer_available.
        [HAVE_TIMERFD]: Declare timerfd.
        [HAVE_CLOCK_GETRES]: Declare resolution.
        (start_atimer) [HAVE_CLOCK_GETRES]: Round up timestamp to
        system timer resolution.
        (set_alarm) [HAVE_TIMERFD]: Use timerfd_settime.
        (timerfd_callback) [HAVE_TIMERFD]: New function.
        (atimer_result, debug_timer_callback, Fdebug_timer_check)
        [ENABLE_CHECKING]: New function for the sake of automated tests.
        (init_atimer) [HAVE_TIMERFD]: Setup timerfd.
        [HAVE_CLOCK_GETRES]: Likewise for system timer resolution.
        [ENABLE_CHECKING]: Defsubr test function.
        * src/atimer.h (timerfd_callback) [HAVE_TIMERFD]: Add prototype.
        * src/lisp.h (add_timer_wait_descriptor) [HAVE_TIMERFD]: Likewise.
        * src/process.c (add_timer_wait_descriptor) [HAVE_TIMERFD]: New function.
        * test/automated/timer-tests.el (timer-tests-debug-timer-check): New test.

might have done the trick here, but I only was able to do very few
experiments because of the horizontal scroll bar code crashing on me
whenever I restore the desktop (which involves restoring the window
configuration).

_That_ crash would have been

(gdb) bt
#0  0xb7fdd424 in __kernel_vsyscall ()
#1  0xb69460c6 in raise (sig=sig@entry=6)
    at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:37
#2  0x08124299 in terminate_due_to_signal (sig=sig@entry=6, 
    backtrace_limit=backtrace_limit@entry=40) at ../../emacs/src/emacs.c:387
#3  0x0813cef7 in emacs_abort () at ../../emacs/src/sysdep.c:2198
#4  0x080f3e38 in XTredeem_scroll_bar (w=0x8752f30)
    at ../../emacs/src/xterm.c:5948
#5  0x0809dd4a in redisplay_window (window=window@entry=141897525, 
    just_this_one_p=just_this_one_p@entry=false)
    at ../../emacs/src/xdisp.c:16839
#6  0x080a16be in redisplay_window_0 (window=141897525)
    at ../../emacs/src/xdisp.c:14250
#7  0x0819280a in internal_condition_case_1 (
    bfun=0x80a1690 <redisplay_window_0>, arg=141897525, handlers=139030854, 
    hfun=0x806cd10 <redisplay_window_error>) at ../../emacs/src/eval.c:1371
#8  0x0807133d in redisplay_windows (window=6) at ../../emacs/src/xdisp.c:14230
#9  0x080901ac in redisplay_internal () at ../../emacs/src/xdisp.c:13829
#10 0x08091d45 in redisplay () at ../../emacs/src/xdisp.c:13115
#11 0x0812e40d in read_char (commandflag=1, map=map@entry=156740206, 
    prev_event=139049922, used_mouse_menu=used_mouse_menu@entry=0xbfffee6b, 
    end_time=end_time@entry=0x0) at ../../emacs/src/keyboard.c:2560
#12 0x0812fd80 in read_key_sequence (keybuf=keybuf@entry=0xbfffef08, 
    prompt=139049922, dont_downcase_last=dont_downcase_last@entry=false, 
    can_return_switch_frame=can_return_switch_frame@entry=true, 
    fix_current_buffer=fix_current_buffer@entry=true, 
    prevent_redisplay=prevent_redisplay@entry=false, bufsize=30)
    at ../../emacs/src/keyboard.c:9120
#13 0x08131796 in command_loop_1 () at ../../emacs/src/keyboard.c:1438
#14 0x08192713 in internal_condition_case (
    bfun=bfun@entry=0x81315e0 <command_loop_1>, handlers=139083250, 
    hfun=hfun@entry=0x8128c50 <cmd_error>) at ../../emacs/src/eval.c:1347
#15 0x081246b5 in command_loop_2 (ignore=139049922)
    at ../../emacs/src/keyboard.c:1169
#16 0x08192643 in internal_catch (tag=139077146, 
    func=func@entry=0x8124690 <command_loop_2>, arg=139049922)
    at ../../emacs/src/eval.c:1111
#17 0x081288b2 in command_loop () at ../../emacs/src/keyboard.c:1148
#18 recursive_edit_1 () at ../../emacs/src/keyboard.c:769
#19 0x08128b99 in Frecursive_edit () at ../../emacs/src/keyboard.c:840
#20 0x08059768 in main (argc=<optimized out>, argv=0xbffff154)
    at ../../emacs/src/emacs.c:1650

My Emacs is configured to use GTK but --without-toolkit-scroll-bars.
For now I've rewound my Emacs version to before the horizontal
scroll-bar commit since I would not be able to get any work done
otherwise.

I fully realize that both of these error reports, particularly the
timer-related one, are flimsy on facts, and I would not bet my life
savings on the first one being reliably dependent on the timer code commit.

They probably will be worth acting upon mostly when other reports
solidify their findings.  Since the state of Emacs current master gives
me is too fragile for working because of _several_ problems, I'm not
likely going to be able to contribute much more useful info.

Sorry.

-- 
David Kastrup




^ permalink raw reply	[flat|nested] 19+ messages in thread
* Re: Several problems
@ 2014-07-30 20:02 Ted Zlatanov
  2014-07-30 20:10 ` Ted Zlatanov
  2014-07-31  4:22 ` Dmitry Antipov
  0 siblings, 2 replies; 19+ messages in thread
From: Ted Zlatanov @ 2014-07-30 20:02 UTC (permalink / raw)
  To: emacs-devel; +Cc: Dmitry Antipov

Hello David and Dmitry,

I see the following situation (using the Git mirror):

* Dmitry's commit 4c19675328d0de84cc3181cfc118973f591e8243 broke GnuTLS
  connections and possibly more. I couldn't even do the initial
  connection.

* the followup fix was good for the initial connection, but larger
  amounts of data fail:

commit 85113e79cb92f1d2798db5754a9edd54567d2b0e
Author: Dmitry Antipov <dmantipov@yandex.ru>
Date:   Mon Jul 28 18:50:55 2014 +0400

    Fix Gnus-related issues reported by David Kastrup <dak@gnu.org> in
    <http://lists.gnu.org/archive/html/emacs-devel/2014-07/msg00370.html>.
    * atimer.c (timerfd_callback): Always read expiration data.
    Add comment.
    (turn_on_atimers) [HAVE_TIMERFD]: Disarm timerfd timer.
    * process.c (add_timer_wait_descriptor): Add timer descriptor
    to input_wait_mask and non_process_wait_mask as well.

I've only tested with GnuTLS connections.

The symptom seems to be that GnuTLS will read data, then gets a retry,
and finally hangs forever. I can duplicate it by trying to read the last
200 messages in emacs-devel and I believe even as little as 16K will
trigger the behavior. But if I read the last 1 message only (`C-u 1
RET') then things work.  If this is indeed a timer problem, it will be
hard to replicate but I hope this is enough data.

It would be nice if we could automate the testing of this behavior.  It
can probably be done with a TLS server (`gnutls-serv' for instance) but
in my experience that's a very tricky type of test that tends to throw
spurious errors.  So it may just be something we live with.

I have probably missed the discussion about this timerfd feature (having
just come back from vacation), so please forgive my ignorance, but is
this something that should always be enabled, or can it be configurable?
If it interferes with GnuTLS connections, maybe it should be disabled
for them?

I am following up to emacs-devel instead of opening a bug report because
that's where David Kastrup posted initially.  If you prefer a bug
report, let me know.

Thanks!
Ted




^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2014-08-06  9:41 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-28 11:24 Several problems David Kastrup
2014-07-28 12:09 ` Dmitry Antipov
2014-07-28 12:32 ` martin rudalics
2014-08-01  9:43   ` Nicolas Avrutin
2014-08-01 10:30     ` martin rudalics
2014-08-01 13:06     ` martin rudalics
2014-08-02  4:10       ` Nicolas Avrutin
2014-08-02  6:57         ` Eli Zaretskii
2014-08-02  7:28           ` Nicolas Avrutin
2014-08-02  7:39             ` Eli Zaretskii
2014-08-02  8:06           ` martin rudalics
2014-08-04 17:22       ` martin rudalics
2014-08-04 21:54         ` Nicolas Avrutin
2014-08-05  8:36           ` martin rudalics
2014-08-05 19:08             ` Faried Nawaz
2014-08-06  9:41               ` martin rudalics
  -- strict thread matches above, loose matches on Subject: below --
2014-07-30 20:02 Ted Zlatanov
2014-07-30 20:10 ` Ted Zlatanov
2014-07-31  4:22 ` Dmitry Antipov

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).