Skip to content
Snippets Groups Projects
Commit ae0e824f authored by Claudio Fontana's avatar Claudio Fontana
Browse files

include/osv/trace.hh: ifdef x64-specific code


protect x64 machine code in #ifdef __x86_64__

Signed-off-by: default avatarClaudio Fontana <claudio.fontana@huawei.com>
parent d812d971
No related branches found
No related tags found
No related merge requests found
......@@ -299,6 +299,7 @@ public:
sig = signature();
}
void operator()(r_args... as) {
#ifdef __x86_64__
asm goto("1: .byte 0x0f, 0x1f, 0x44, 0x00, 0x00 \n\t" // 5-byte nop
".pushsection .tracepoint_patch_sites, \"a\", @progbits \n\t"
".quad %c[id] \n\t"
......@@ -309,6 +310,7 @@ public:
: : [type]"i"(&typeid(*this)), [id]"i"(_id) : : slow_path);
return;
slow_path:
#endif /* __x86_64__ */
trace_slow_path(assign(as...));
}
void trace_slow_path(std::tuple<s_args...> as) __attribute__((cold)) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment