all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: eggert@cs.ucla.edu
Cc: 9000@debbugs.gnu.org
Subject: bug#9000: patch for higher-resolution time stamps
Date: Sat, 23 Jun 2012 13:48:41 +0300	[thread overview]
Message-ID: <83txy2b8xi.fsf@gnu.org> (raw)
In-Reply-To: <83vciibewj.fsf@gnu.org>

> Date: Sat, 23 Jun 2012 11:39:40 +0300
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 9000@debbugs.gnu.org
> 
> > Date: Fri, 22 Jun 2012 14:21:50 -0700
> > From: Paul Eggert <eggert@cs.ucla.edu>
> > CC: Eli Zaretskii <eliz@gnu.org>
> > 
> > No further comment and the patch seems ripe
> > so I installed it into the trunk as bzr 108687
> > and am marking this bug as done.  I'll CC: this
> > to Eli as it affects the Microsoft ports.
> 
> This badly broke the MS-Windows build.  I'm working on fixing it.

I think I fixed this in revision 108698, MS-Windows users please see
if there are any leftovers.  In particular, any feature that uses
system time or file time or 'select' (i.e. subprocesses) is suspect.
I only did some minimal testing.

Paul, please note that I needed changes in 3 gnulib headers:
utimens.h, timespec.h, and stat-time.h.  The change is to include
sys/time.h, because that's where the Windows build defines
'struct timespec' (time.h cannot be used for that).  I hope you can
make these changes in upstream gnulib.

I'm OK with any other solution to this conundrum, which will be
compatible with the following conditions:

 . do not assume that 'struct timespec' is defined on time.h, or on
   any other MS-Windows system header
 . do not use gnulib's time.h (as that requires Sed to edit time.in.h)

It is OK to add headers to Emacs's nt/inc/ directory in order to solve
this, provided that they do not shadow system headers (since MSVC does
not have include_next or its equivalent).

Finally, I see compiler warnings due to the changes in revno 108687:

  dispnew.c: In function `Fsleep_for':
  dispnew.c:5960: warning: comparison is always true due to limited range of data type
  dispnew.c: In function `sit_for':
  dispnew.c:6008: warning: comparison is always true due to limited range of data type

  keyboard.c: In function `kbd_buffer_get_event':
  keyboard.c:3861: warning: comparison is always true due to limited range of data type

  process.c: In function `Faccept_process_output':
  process.c:3999: warning: comparison is always true due to limited range of data type

They all come from snippets such as this one:

    min (EMACS_SECS (t), INTMAX_MAX)

I think any host with a signed 32-bit time_t will see this warning.
Can this annoyance be fixed, please?






  reply	other threads:[~2012-06-23 10:48 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-05  6:40 bug#9000: patch for higher-resolution time stamps Paul Eggert
2011-07-05  6:57 ` bug#9000: More-compatible proposal, using (HIGH LOW USEC PSEC) " Paul Eggert
2011-07-06 17:00   ` bug#9000: Update time patch for Frandom, pthread_sigmask, etc Paul Eggert
2012-05-04 20:52 ` bug#9000: 2012-05-04 version of patch Paul Eggert
2012-05-27  3:08   ` Paul Eggert
2012-06-22 21:21 ` bug#9000: patch for higher-resolution time stamps Paul Eggert
2012-06-23  8:39   ` Eli Zaretskii
2012-06-23 10:48     ` Eli Zaretskii [this message]
2012-06-23 17:57       ` Paul Eggert
2012-06-23 19:09         ` Eli Zaretskii
2012-06-23 19:42           ` Eli Zaretskii
2012-06-23 22:45             ` Paul Eggert
2012-06-24  2:57               ` Eli Zaretskii
2012-06-24  4:31                 ` Paul Eggert
2012-06-24 19:26                   ` Eli Zaretskii
2012-06-23 18:55       ` Paul Eggert
2012-06-23 19:08         ` Eli Zaretskii
2012-06-23 22:34           ` Paul Eggert
2012-06-24 17:23             ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83txy2b8xi.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=9000@debbugs.gnu.org \
    --cc=eggert@cs.ucla.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.