Skip to content

Commit 9018f82

Browse files
olsajirianakryiko
authored andcommitted
lib: Emit nop,no10 instructions combo for x86_64 arch
Now that we have no10 optimization support in kernel, let's emit nop,nop10 for usdt probe. We leave it up to the library to use desirable nop instruction. Signed-off-by: Jiri Olsa <jolsa@kernel.org>
1 parent b0144b0 commit 9018f82

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

usdt.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,8 @@ struct usdt_sema { volatile unsigned short active; };
312312
#ifndef USDT_NOP
313313
#if defined(__ia64__) || defined(__s390__) || defined(__s390x__)
314314
#define USDT_NOP nop 0
315+
#elif defined(__x86_64__)
316+
#define USDT_NOP .byte 0x90, 0x66, 0x2e, 0x0f, 0x1f, 0x84, 0x00, 0x00, 0x00, 0x00, 0x00 /* nop, nop10 */
315317
#else
316318
#define USDT_NOP nop
317319
#endif

0 commit comments

Comments
 (0)