Add time_update().

This commit is contained in:
Cameron Evans
2016-02-02 21:52:08 -08:00
committed by Jason Evans
parent f829009929
commit e5d5a4a517
7 changed files with 97 additions and 2 deletions

View File

@@ -356,6 +356,7 @@ typedef unsigned szind_t;
# define VARIABLE_ARRAY(type, name, count) type name[(count)]
#endif
#include "jemalloc/internal/time.h"
#include "jemalloc/internal/valgrind.h"
#include "jemalloc/internal/util.h"
#include "jemalloc/internal/atomic.h"
@@ -384,6 +385,7 @@ typedef unsigned szind_t;
/******************************************************************************/
#define JEMALLOC_H_STRUCTS
#include "jemalloc/internal/time.h"
#include "jemalloc/internal/valgrind.h"
#include "jemalloc/internal/util.h"
#include "jemalloc/internal/atomic.h"
@@ -469,6 +471,7 @@ void jemalloc_prefork(void);
void jemalloc_postfork_parent(void);
void jemalloc_postfork_child(void);
#include "jemalloc/internal/time.h"
#include "jemalloc/internal/valgrind.h"
#include "jemalloc/internal/util.h"
#include "jemalloc/internal/atomic.h"
@@ -497,6 +500,7 @@ void jemalloc_postfork_child(void);
/******************************************************************************/
#define JEMALLOC_H_INLINES
#include "jemalloc/internal/time.h"
#include "jemalloc/internal/valgrind.h"
#include "jemalloc/internal/util.h"
#include "jemalloc/internal/atomic.h"

View File

@@ -61,4 +61,12 @@ isblank(int c)
#endif
#include <fcntl.h>
#include <sys/time.h>
#ifdef _WIN32
struct timespec {
time_t tv_sec;
long tv_nsec;
};
#endif
#endif /* JEMALLOC_INTERNAL_H */

View File

@@ -460,6 +460,7 @@ tcaches_get
tcache_stats_merge
thread_allocated_cleanup
thread_deallocated_cleanup
time_update
tsd_arena_get
tsd_arena_set
tsd_boot

View File

@@ -0,0 +1,22 @@
#define JEMALLOC_CLOCK_GETTIME defined(_POSIX_MONOTONIC_CLOCK) \
&& _POSIX_MONOTONIC_CLOCK >= 0
/******************************************************************************/
#ifdef JEMALLOC_H_TYPES
#endif /* JEMALLOC_H_TYPES */
/******************************************************************************/
#ifdef JEMALLOC_H_STRUCTS
#endif /* JEMALLOC_H_STRUCTS */
/******************************************************************************/
#ifdef JEMALLOC_H_EXTERNS
bool time_update(struct timespec *time);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/
#ifdef JEMALLOC_H_INLINES
#endif /* JEMALLOC_H_INLINES */
/******************************************************************************/