Current Path : /usr/local/lib/perl5/site_perl/5.8.9/mach/sys/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/local/lib/perl5/site_perl/5.8.9/mach/sys/time.ph |
require '_h2ph_pre.ph'; no warnings 'redefine'; unless(defined(&_SYS_TIME_H_)) { eval 'sub _SYS_TIME_H_ () {1;}' unless defined(&_SYS_TIME_H_); require 'sys/_timeval.ph'; require 'sys/types.ph'; require 'sys/timespec.ph'; eval 'sub DST_NONE () {0;}' unless defined(&DST_NONE); eval 'sub DST_USA () {1;}' unless defined(&DST_USA); eval 'sub DST_AUST () {2;}' unless defined(&DST_AUST); eval 'sub DST_WET () {3;}' unless defined(&DST_WET); eval 'sub DST_MET () {4;}' unless defined(&DST_MET); eval 'sub DST_EET () {5;}' unless defined(&DST_EET); eval 'sub DST_CAN () {6;}' unless defined(&DST_CAN); if((defined(&__BSD_VISIBLE) ? &__BSD_VISIBLE : undef)) { eval 'sub bintime_addx { my($bt,$x) = @_; eval q({ &uint64_t &u; &u = ($bt->{frac}); ($bt->{frac}) += $x; &if ( &u > ($bt->{frac})) ($bt->{sec})++; }); }' unless defined(&bintime_addx); eval 'sub bintime_add { my($bt,$bt2) = @_; eval q({ &uint64_t &u; &u = ($bt->{frac}); ($bt->{frac}) += ($bt2->{frac}); &if ( &u > ($bt->{frac})) ($bt->{sec})++; ($bt->{sec}) += ($bt2->{sec}); }); }' unless defined(&bintime_add); eval 'sub bintime_sub { my($bt,$bt2) = @_; eval q({ &uint64_t &u; &u = ($bt->{frac}); ($bt->{frac}) -= ($bt2->{frac}); &if ( &u < ($bt->{frac})) ($bt->{sec})--; ($bt->{sec}) -= ($bt2->{sec}); }); }' unless defined(&bintime_sub); eval 'sub bintime_mul { my($bt,$x) = @_; eval q({ &uint64_t &p1, &p2; &p1 = ( ($bt->{frac}) & 0xffffffff) * $x; &p2 = ( ($bt->{frac}) >> 32) * $x + ( &p1 >> 32); ($bt->{sec}) *= $x; ($bt->{sec}) += ( &p2 >> 32); ($bt->{frac}) = ( &p2 << 32) | ( &p1 & 0xffffffff); }); }' unless defined(&bintime_mul); eval 'sub bintime_clear { my($a) = @_; eval q((($a)-> &sec = ($a)-> &frac = 0)); }' unless defined(&bintime_clear); eval 'sub bintime_isset { my($a) = @_; eval q((($a)-> &sec || ($a)-> &frac)); }' unless defined(&bintime_isset); eval 'sub bintime_cmp { my($a, $b, $cmp) = @_; eval q(((($a)-> &sec == ($b)-> &sec) ? (($a)-> &frac $cmp ($b)-> &frac) : (($a)-> &sec $cmp ($b)-> &sec))); }' unless defined(&bintime_cmp); eval 'sub timespec2bintime { my($ts,$bt) = @_; eval q({ ($bt->{sec}) = ($ts->{tv_sec}); ($bt->{frac}) = ($ts->{tv_nsec}) * ( &uint64_t)18446744073; }); }' unless defined(×pec2bintime); eval 'sub bintime2timeval { my($bt,$tv) = @_; eval q({ ($tv->{tv_sec}) = ($bt->{sec}); ($tv->{tv_usec}) = (( &uint64_t)1000000* ( &uint32_t)( ($bt->{frac}) >> 32)) >> 32; }); }' unless defined(&bintime2timeval); eval 'sub timeval2bintime { my($tv,$bt) = @_; eval q({ ($bt->{sec}) = ($tv->{tv_sec}); ($bt->{frac}) = ($tv->{tv_usec}) * ( &uint64_t)18446744073709; }); }' unless defined(&timeval2bintime); } if(defined(&_KERNEL)) { eval 'sub timespecclear { my($tvp) = @_; eval q((($tvp)-> &tv_sec = ($tvp)-> &tv_nsec = 0)); }' unless defined(×pecclear); eval 'sub timespecisset { my($tvp) = @_; eval q((($tvp)-> &tv_sec || ($tvp)-> &tv_nsec)); }' unless defined(×pecisset); eval 'sub timespeccmp { my($tvp, $uvp, $cmp) = @_; eval q(((($tvp)-> &tv_sec == ($uvp)-> &tv_sec) ? (($tvp)-> &tv_nsec $cmp ($uvp)-> &tv_nsec) : (($tvp)-> &tv_sec $cmp ($uvp)-> &tv_sec))); }' unless defined(×peccmp); eval 'sub timespecadd { my($vvp, $uvp) = @_; eval q( &do { ($vvp)-> &tv_sec += ($uvp)-> &tv_sec; ($vvp)-> &tv_nsec += ($uvp)-> &tv_nsec; &if (($vvp)-> &tv_nsec >= 1000000000) { ($vvp)-> &tv_sec++; ($vvp)-> &tv_nsec -= 1000000000; } } &while (0)); }' unless defined(×pecadd); eval 'sub timespecsub { my($vvp, $uvp) = @_; eval q( &do { ($vvp)-> &tv_sec -= ($uvp)-> &tv_sec; ($vvp)-> &tv_nsec -= ($uvp)-> &tv_nsec; &if (($vvp)-> &tv_nsec < 0) { ($vvp)-> &tv_sec--; ($vvp)-> &tv_nsec += 1000000000; } } &while (0)); }' unless defined(×pecsub); eval 'sub timevalclear { my($tvp) = @_; eval q((($tvp)-> &tv_sec = ($tvp)-> &tv_usec = 0)); }' unless defined(&timevalclear); eval 'sub timevalisset { my($tvp) = @_; eval q((($tvp)-> &tv_sec || ($tvp)-> &tv_usec)); }' unless defined(&timevalisset); eval 'sub timevalcmp { my($tvp, $uvp, $cmp) = @_; eval q(((($tvp)-> &tv_sec == ($uvp)-> &tv_sec) ? (($tvp)-> &tv_usec $cmp ($uvp)-> &tv_usec) : (($tvp)-> &tv_sec $cmp ($uvp)-> &tv_sec))); }' unless defined(&timevalcmp); } unless(defined(&_KERNEL)) { eval 'sub timerclear { my($tvp) = @_; eval q((($tvp)-> &tv_sec = ($tvp)-> &tv_usec = 0)); }' unless defined(&timerclear); eval 'sub timerisset { my($tvp) = @_; eval q((($tvp)-> &tv_sec || ($tvp)-> &tv_usec)); }' unless defined(&timerisset); eval 'sub timercmp { my($tvp, $uvp, $cmp) = @_; eval q(((($tvp)-> &tv_sec == ($uvp)-> &tv_sec) ? (($tvp)-> &tv_usec $cmp ($uvp)-> &tv_usec) : (($tvp)-> &tv_sec $cmp ($uvp)-> &tv_sec))); }' unless defined(&timercmp); eval 'sub timeradd { my($tvp, $uvp, $vvp) = @_; eval q( &do { ($vvp)-> &tv_sec = ($tvp)-> &tv_sec + ($uvp)-> &tv_sec; ($vvp)-> &tv_usec = ($tvp)-> &tv_usec + ($uvp)-> &tv_usec; &if (($vvp)-> &tv_usec >= 1000000) { ($vvp)-> &tv_sec++; ($vvp)-> &tv_usec -= 1000000; } } &while (0)); }' unless defined(&timeradd); eval 'sub timersub { my($tvp, $uvp, $vvp) = @_; eval q( &do { ($vvp)-> &tv_sec = ($tvp)-> &tv_sec - ($uvp)-> &tv_sec; ($vvp)-> &tv_usec = ($tvp)-> &tv_usec - ($uvp)-> &tv_usec; &if (($vvp)-> &tv_usec < 0) { ($vvp)-> &tv_sec--; ($vvp)-> &tv_usec += 1000000; } } &while (0)); }' unless defined(&timersub); } eval 'sub ITIMER_REAL () {0;}' unless defined(&ITIMER_REAL); eval 'sub ITIMER_VIRTUAL () {1;}' unless defined(&ITIMER_VIRTUAL); eval 'sub ITIMER_PROF () {2;}' unless defined(&ITIMER_PROF); unless(defined(&CLOCK_REALTIME)) { eval 'sub CLOCK_REALTIME () {0;}' unless defined(&CLOCK_REALTIME); eval 'sub CLOCK_VIRTUAL () {1;}' unless defined(&CLOCK_VIRTUAL); eval 'sub CLOCK_PROF () {2;}' unless defined(&CLOCK_PROF); eval 'sub CLOCK_MONOTONIC () {4;}' unless defined(&CLOCK_MONOTONIC); eval 'sub CLOCK_UPTIME () {5;}' unless defined(&CLOCK_UPTIME); eval 'sub CLOCK_UPTIME_PRECISE () {7;}' unless defined(&CLOCK_UPTIME_PRECISE); eval 'sub CLOCK_UPTIME_FAST () {8;}' unless defined(&CLOCK_UPTIME_FAST); eval 'sub CLOCK_REALTIME_PRECISE () {9;}' unless defined(&CLOCK_REALTIME_PRECISE); eval 'sub CLOCK_REALTIME_FAST () {10;}' unless defined(&CLOCK_REALTIME_FAST); eval 'sub CLOCK_MONOTONIC_PRECISE () {11;}' unless defined(&CLOCK_MONOTONIC_PRECISE); eval 'sub CLOCK_MONOTONIC_FAST () {12;}' unless defined(&CLOCK_MONOTONIC_FAST); eval 'sub CLOCK_SECOND () {13;}' unless defined(&CLOCK_SECOND); eval 'sub CLOCK_THREAD_CPUTIME_ID () {14;}' unless defined(&CLOCK_THREAD_CPUTIME_ID); } unless(defined(&TIMER_ABSTIME)) { eval 'sub TIMER_RELTIME () {0x;}' unless defined(&TIMER_RELTIME); eval 'sub TIMER_ABSTIME () {0x1;}' unless defined(&TIMER_ABSTIME); } if(defined(&_KERNEL)) { } else { require 'time.ph'; require 'sys/cdefs.ph'; require 'sys/select.ph'; if((defined(&__BSD_VISIBLE) ? &__BSD_VISIBLE : undef)) { } if((defined(&__XSI_VISIBLE) ? &__XSI_VISIBLE : undef)) { } } } 1;