home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.sgi
- Path: sparky!uunet!charon.amdahl.com!pacbell.com!sgiblab!sgigate!odin!bubba.wpd.sgi.com!probins
- From: probins@bubba.wpd.sgi.com (Paul Robins)
- Subject: Re: how to interrogate ftimer status from a program?
- Message-ID: <1992Nov6.213506.12264@odin.corp.sgi.com>
- Sender: news@odin.corp.sgi.com (Net News)
- Nntp-Posting-Host: bubba.wpd.sgi.com
- Reply-To: probins@wpd.sgi.com
- Organization: Silicon Graphics, Inc.
- References: <23907@hacgate.SCG.HAC.COM>
- Date: Fri, 6 Nov 1992 21:35:06 GMT
- Lines: 35
-
- In article <23907@hacgate.SCG.HAC.COM>, lee@luke.rsg.hac.com (C. Lee) writes:
- |> From the shell, I can type /etc/ftimer to see the status of the fast
- |> clock. From a program, how can I find out the status of the fast
- |> clock?
- |>
- |> Also, man ftimer says enabling and using fast itimers increases system
- |> overhead. What about enabling the fast clock?
- |>
- |> Thanks.
-
-
- Here is a code fragment that can help.
-
-
- #include <sys/syssgi.h>
-
- /* check whether fastclock and timer were on before I started */
- /* note that there is no way to query the fastclock is on, */
- /* but the timer cannot be on if the fastclock is not. */
-
- ftimerwasoff = !syssgi(SGI_QUERY_FTIMER);
-
- Fast clock does not incur nearly the overhead of timers, but I don't have a
- relative number. I've been assured that it is of neglible impact.
-
-
-
-
- --
-
- --bubba
-
- hakuna matata
-
- 390-1282 Mail stop 9U-510
-