mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-18 09:05:10 +00:00
Inline assembly is very convenient if a couple of instructions is used but when it grows better to move it out of wrapper C code and write in plain assembly, after all we need a very precise control in bootstrap code. Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
24 lines
359 B
C
24 lines
359 B
C
#ifndef LINKAGE_H_
|
|
#define LINKAGE_H_
|
|
|
|
#ifdef __ASSEMBLY__
|
|
|
|
#define __ALIGN .align 4, 0x90
|
|
#define __ALIGN_STR ".align 4, 0x90"
|
|
|
|
#define GLOBAL(name) \
|
|
.globl name; \
|
|
name:
|
|
|
|
#define ENTRY(name) \
|
|
.globl name; \
|
|
.type name, @function; \
|
|
__ALIGN; \
|
|
name:
|
|
|
|
#define END(sym) \
|
|
.size sym, . - sym
|
|
|
|
#endif /* __ASSEMBLY__ */
|
|
|
|
#endif /* LINKAGE_H_ */
|