diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2022-08-04 16:58:50 +0200 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2022-08-05 12:02:11 +0200 |
commit | 007e23d6390af11582e55453269b7a51c723d2dd (patch) | |
tree | 8e8cff3ca23f5e56d9766a5ee6c6abb366611b07 /winsup/cygwin/profil.h | |
parent | 1e428bee1c5ef7c76ba4e46e6693b913edc9bbf3 (diff) | |
download | newlib-007e23d6390af11582e55453269b7a51c723d2dd.zip newlib-007e23d6390af11582e55453269b7a51c723d2dd.tar.gz newlib-007e23d6390af11582e55453269b7a51c723d2dd.tar.bz2 |
Cygwin: Reorganize cygwin source dir
Create subdirs and move files accordingly:
- DevDocs: doc files
- fhandler: fhandler sources, split fhandler.cc into base.cc and null.cc
- local_includes: local include files
- scripts: scripts called during build
- sec: security sources
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'winsup/cygwin/profil.h')
-rw-r--r-- | winsup/cygwin/profil.h | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/winsup/cygwin/profil.h b/winsup/cygwin/profil.h deleted file mode 100644 index cb1a092..0000000 --- a/winsup/cygwin/profil.h +++ /dev/null @@ -1,53 +0,0 @@ -/* profil.h: gprof profiling header file - -This file is part of Cygwin. - -This software is a copyrighted work licensed under the terms of the -Cygwin license. Please consult the file "CYGWIN_LICENSE" for -details. */ - -/* - * This file is taken from Cygwin distribution. Please keep it in sync. - * The differences should be within __MINGW32__ guard. - */ - -/* profiling frequency. (No larger than 1000) */ -#define PROF_HZ 100 - -/* convert an addr to an index */ -#define PROFIDX(pc, base, scale) \ - ({ \ - size_t i = (pc - base) / 2; \ - if (sizeof (unsigned long long int) > sizeof (size_t)) \ - i = (unsigned long long int) i * scale / 65536; \ - else \ - i = i / 65536 * scale + i % 65536 * scale / 65536; \ - i; \ - }) - -/* convert an index into an address */ -#define PROFADDR(idx, base, scale) \ - ((base) \ - + ((((unsigned long long)(idx) << 16) \ - / (unsigned long long)(scale)) << 1)) - -/* convert a bin size into a scale */ -#define PROFSCALE(range, bins) (((bins) << 16) / ((range) >> 1)) - -typedef void *_WINHANDLE; -#ifdef __MINGW32__ -#include <_bsd_types.h> -#endif /* __MINGW32__*/ - -struct profinfo { - _WINHANDLE targthr; /* thread to profile */ - _WINHANDLE profthr; /* profiling thread */ - _WINHANDLE quitevt; /* quit event */ - uint16_t *counter; /* profiling counters */ - size_t lowpc, highpc; /* range to be profiled */ - uint32_t scale; /* scale value of bins */ -}; - -int profile_ctl(struct profinfo *, char *, size_t, size_t, uint32_t); -int profil(char *, size_t, size_t, uint32_t); - |