Changes:
- $Id: util.c 5126 2006-07-12 22:55:05Z twisti $
+ $Id: util.c 5252 2006-08-18 13:07:21Z twisti $
*/
#include <errno.h>
#include <stdarg.h>
#include <unistd.h>
-#include <sys/time.h>
#include "vm/types.h"
}
-/* util_current_time_millis ****************************************************
-
- Return the current time in milliseconds.
-
-*******************************************************************************/
-
-s8 util_current_time_millis(void)
-{
- struct timeval tv;
- s8 result;
-
- if (gettimeofday(&tv, NULL) == -1)
- vm_abort("gettimeofday failed: %s", strerror(errno));
-
- result = (s8) tv.tv_sec;
- result *= 1000;
- result += (tv.tv_usec / 1000);
-
- return result;
-}
-
-
/*
* These are local overrides for various environment variables in Emacs.
* Please do not remove this and leave it at the end of the file, where
Changes:
- $Id: util.h 5104 2006-07-10 17:22:18Z twisti $
+ $Id: util.h 5252 2006-08-18 13:07:21Z twisti $
*/
char *_Jv_getcwd(void);
int get_variable_message_length(const char *fmt, va_list ap);
-s8 util_current_time_millis(void);
#endif /* _UTIL_H */
# include "threads/native/threads.h"
#endif
-#include "toolbox/util.h"
#include "vm/classcache.h"
#include "vm/exceptions.h"
#include "vm/finalizer.h"
/* set the VM starttime */
- _Jv_jvm->starttime = util_current_time_millis();
+ _Jv_jvm->starttime = builtin_currenttimemillis();
/* get stuff from the environment *****************************************/