Feat add no instrucment function
All checks were successful
linux-mips64-gcc / linux-gcc-mips64el (Debug) (push) Successful in 2m3s
linux-mips64-gcc / linux-gcc-mips64el (Release) (push) Successful in 1m22s
linux-x64-gcc / linux-gcc (Debug) (push) Successful in 1m54s
linux-x64-gcc / linux-gcc (Release) (push) Successful in 1m16s
All checks were successful
linux-mips64-gcc / linux-gcc-mips64el (Debug) (push) Successful in 2m3s
linux-mips64-gcc / linux-gcc-mips64el (Release) (push) Successful in 1m22s
linux-x64-gcc / linux-gcc (Debug) (push) Successful in 1m54s
linux-x64-gcc / linux-gcc (Release) (push) Successful in 1m16s
This commit is contained in:
parent
5095516686
commit
17619b443b
@ -2,10 +2,11 @@
|
|||||||
#define SLED_DEBUGGING_DEMANGLE_H
|
#define SLED_DEBUGGING_DEMANGLE_H
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include "sled/lang/attributes.h"
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
namespace sled {
|
namespace sled {
|
||||||
bool Demangle(const char *mangled, char *out, size_t out_size);
|
bool SLED_NO_INSTRUMENT_FUNCTION Demangle(const char *mangled, char *out, size_t out_size);
|
||||||
std::string DemangleString(const char *mangled);
|
std::string SLED_NO_INSTRUMENT_FUNCTION DemangleString(const char *mangled);
|
||||||
}// namespace sled
|
}// namespace sled
|
||||||
#endif// SLED_DEBUGGING_DEMANGLE_H
|
#endif// SLED_DEBUGGING_DEMANGLE_H
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#include "sled/debugging/symbolize.h"
|
#include "sled/debugging/symbolize.h"
|
||||||
|
#include "sled/lang/attributes.h"
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
void
|
void
|
||||||
|
@ -10,6 +10,7 @@ namespace sled {
|
|||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
static std::string
|
static std::string
|
||||||
|
SLED_NO_INSTRUMENT_FUNCTION
|
||||||
GetSymbolString(const std::string &backtrace_line)
|
GetSymbolString(const std::string &backtrace_line)
|
||||||
{
|
{
|
||||||
// Example Backtrace lines:
|
// Example Backtrace lines:
|
||||||
@ -40,10 +41,12 @@ GetSymbolString(const std::string &backtrace_line)
|
|||||||
}// namespace
|
}// namespace
|
||||||
|
|
||||||
void
|
void
|
||||||
|
SLED_NO_INSTRUMENT_FUNCTION
|
||||||
InitializeSymbolizer(const char *argv0)
|
InitializeSymbolizer(const char *argv0)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
|
SLED_NO_INSTRUMENT_FUNCTION
|
||||||
Symbolize(const void *pc, char *out, int out_size)
|
Symbolize(const void *pc, char *out, int out_size)
|
||||||
{
|
{
|
||||||
if (out_size <= 0 || pc == nullptr) {
|
if (out_size <= 0 || pc == nullptr) {
|
||||||
|
@ -56,4 +56,6 @@
|
|||||||
#define SLED_UNLOCK_FUNCTION(...) SLED_THREAD_ANNOTATION_ATTRIBUTE__(unlock_function(__VA_ARGS__))
|
#define SLED_UNLOCK_FUNCTION(...) SLED_THREAD_ANNOTATION_ATTRIBUTE__(unlock_function(__VA_ARGS__))
|
||||||
#define SLED_ASSERT_EXCLUSIVE_LOCK(...) SLED_THREAD_ANNOTATION_ATTRIBUTE__(assert_exclusive_lock(__VA_ARGS__))
|
#define SLED_ASSERT_EXCLUSIVE_LOCK(...) SLED_THREAD_ANNOTATION_ATTRIBUTE__(assert_exclusive_lock(__VA_ARGS__))
|
||||||
|
|
||||||
|
#define SLED_NO_INSTRUMENT_FUNCTION SLED_THREAD_ANNOTATION_ATTRIBUTE__(no_instrument_function)
|
||||||
|
|
||||||
#endif// SLED_LANG_ATTRIBUTES_H
|
#endif// SLED_LANG_ATTRIBUTES_H
|
||||||
|
Loading…
x
Reference in New Issue
Block a user