summaryrefslogtreecommitdiff
path: root/libc/string/x86_64/_glibc_inc.h
blob: f14b23c942d0a9ca337693e6a706adb37e9136dc (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
/*
 * Setup some glibc defines so we can just drop in the
 * asm files from glibc without any modification.
 */

#include <features.h>
#include <bits/wordsize.h>

#if __WORDSIZE == 32
# define ENTRY_ALIGN 4
#else
# define ENTRY_ALIGN 2
#endif

#define ENTRY(sym) \
	.global sym; \
	.align  ENTRY_ALIGN; \
	.type   sym,%function; \
	sym:

#define BP_SYM(sym) sym

#define L(sym) LOC(sym)
#define LOC(sym) \
	.L ## sym

#define END(sym) \
	.size sym,.-sym;

#undef weak_alias
#define weak_alias(sym, alias) \
	.weak alias; \
    alias = sym;