名前空間
変種
操作

clock

提供: cppreference.com
< c‎ | chrono

 
 
日付と時間のユーティリティ
機能します
Original:
Functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
時間操作
Original:
Time manipulation
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
difftime
time
clock
フォーマット変換
Original:
Format conversions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
asctime
ctime
strftime
wcsftime
gmtime
localtime
mktime
定数
Original:
Constants
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
CLOCKS_PER_SEC
タイプ
Original:
Types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
tm
time_t
clock_t
 
Defined in header <time.h>
clock_t clock();
プログラムの実行に関連する実装定義の時代の始まり以来、プロセスで使用されるおおよそのプロセッサ時間を返します。秒に結果の値を変換するにはCLOCKS_PER_SECで割ります。 clock時代の始まりは、プログラムの開始と一致する必要がないため、clockに別の呼び出しによって返された二つの値の間の唯一の違いは意味があります。 CPUが他のプロセスによって共有されている場合、clock時間は壁時計より遅く進むことができる。現在のプロセスがマルチスレッド化されており、複数の実行コアが使用可能な場合は、clock時間は速く壁時計よりも前進することが.
Original:
Returns the approximate processor time used by the process since the beginning of an implementation-defined era related to the program's execution. To convert result value to seconds divide it by CLOCKS_PER_SEC. Because the beginning of the clock era does not have to coincide with the start of the program, only the difference between two values returned by different calls to clock is meaningful. If the CPU is shared by other processes, clock time may advance slower than wall clock. If the current process is multithreaded and more than one execution core is available, clock time may advance faster than wall clock.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

目次

[編集] パラメータ

(なし)
Original:
(none)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[編集] 値を返します

その情報が利用できない場合、これまで(clock_t)(-1)またはプログラムによって使用されるプロセッサー時間.
Original:
Processor time used by the program so far or (clock_t)(-1) if that information is unavailable.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[編集] ノート

POSIX準拠のシステムでは、システム時計イドCLOCK_PROCESS_CPUTIME_IDとclock_gettimeは良好な分解能を提供しています.
Original:
On POSIX-compatible systems, clock_gettime with clock id CLOCK_PROCESS_CPUTIME_ID offers better resolution.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
clock()によって返される値は、いくつかの実装で折り返すことがあります。たとえば、32ビットclock_tを積んだマシンで、それは2147秒または36分後にラップ.
Original:
The value returned by clock() may wrap around on some implementations. For example, on a machine with 32-bit clock_t, it wraps after 2147 seconds or 36 minutes.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
clock()は、スレッドセーフである必要はありません.
Original:
clock() is not required to be thread-safe.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[編集]

[編集] も参照してください

テキスト表現にtmオブジェクトを変換します
Original:
converts a tm object to a textual representation
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(機能) [edit]
エポックからの経過時間など、システムの現在時刻を返します
Original:
returns the current time of the system as time since epoch
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(機能) [edit]