mirror of
https://github.com/wolfpld/tracy.git
synced 2026-08-30 23:18:27 +00:00
Cygwin support for callstack tracing.
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
#ifdef TRACY_HAS_CALLSTACK
|
||||
|
||||
#ifdef _WIN32
|
||||
#if defined _WIN32 || defined __CYGWIN__
|
||||
# ifndef MAXLONG
|
||||
enum { SYMOPT_LOAD_LINES = 0x00000010 };
|
||||
typedef struct _SYMBOL_INFO
|
||||
|
||||
@@ -1,10 +1,14 @@
|
||||
#ifndef __TRACYCALLSTACK_HPP__
|
||||
#define __TRACYCALLSTACK_HPP__
|
||||
|
||||
#ifdef _WIN32
|
||||
#if defined _WIN32 || defined __CYGWIN__
|
||||
# define TRACY_HAS_CALLSTACK
|
||||
# ifndef MAXLONG
|
||||
# ifdef __CYGWIN__
|
||||
extern "C" __declspec(dllimport) unsigned short __stdcall RtlCaptureStackBackTrace( unsigned int, unsigned int, void**, unsigned int* );
|
||||
# else
|
||||
extern "C" __declspec(dllimport) unsigned short __stdcall RtlCaptureStackBackTrace( unsigned long, unsigned long, void**, unsigned long* );
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@@ -27,7 +31,7 @@ struct CallstackEntry
|
||||
uint32_t line;
|
||||
};
|
||||
|
||||
#ifdef _WIN32
|
||||
#if defined _WIN32 || defined __CYGWIN__
|
||||
|
||||
void InitCallstack();
|
||||
CallstackEntry DecodeCallstackPtr( uint64_t ptr );
|
||||
|
||||
Reference in New Issue
Block a user