aboutsummaryrefslogtreecommitdiffstats
path: root/examples/performance-thread/common/arch/x86/ctx.h
blob: c6a46c52913f138b55ad884f420c0a00941f0a74 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/* SPDX-License-Identifier: BSD-3-Clause
 * Copyright(c) 2015 Intel Corporation
 */


#ifndef CTX_H
#define CTX_H

#ifdef __cplusplus
extern "C" {
#endif

/*
 * CPU context registers
 */
struct ctx {
	void	*rsp;		/* 0  */
	void	*rbp;		/* 8  */
	void	*rip;		/* 16 */
	void	*rbx;		/* 24 */
	void	*r12;		/* 32 */
	void	*r13;		/* 40 */
	void	*r14;		/* 48 */
	void	*r15;		/* 56 */
};


void
ctx_switch(struct ctx *new_ctx, struct ctx *curr_ctx);


#ifdef __cplusplus
}
#endif

#endif /* RTE_CTX_H_ */