| delorie.com/archives/browse.cgi | search |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| X-Spam-Check-By: | sourceware.org |
| Message-ID: | <4783CF18.900@huarp.harvard.edu> |
| Date: | Tue, 08 Jan 2008 14:29:28 -0500 |
| From: | Norton Allen <allen AT huarp DOT harvard DOT edu> |
| User-Agent: | Thunderbird 2.0.0.9 (Windows/20071031) |
| MIME-Version: | 1.0 |
| To: | cygwin AT cygwin DOT com |
| Subject: | Re: Does clock() work? |
| References: | <4783B96D DOT 9060709 AT huarp DOT harvard DOT edu> <4783C3D9 DOT 6020303 AT sbcglobal DOT net> <4783CBDE DOT 8070201 AT huarp DOT harvard DOT edu> |
| In-Reply-To: | <4783CBDE.8070201@huarp.harvard.edu> |
| Received-SPF: | pass (ent.arp.harvard.edu: 10.0.0.122 is authenticated by a trusted mechanism) |
| X-IsSubscribed: | yes |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Id: | <cygwin.cygwin.com> |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| Sender: | cygwin-owner AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| Delivered-To: | mailing list cygwin AT cygwin DOT com |
Norton Allen wrote: > Greg Chicares wrote: >> I get similar results with the same program. According to >> C99 7.23.2.1/2, >> "The clock function determines the processor time used." >> so I'd guess that sleep() is consuming only wall-clock time. >> > Ah, good catch. Thank you. > Now, I am definitely interested in wall clock elapsed time. Is there > anything available that will give me real time at resolution greater > than one second? > I found gettimeofday() that seems to do the trick. -N -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |