1 # Powerpc64 specific build options.
2 # this is ./sysdeps/powerpc/powerpc64/Makefile
4 # Each TOC entry takes 8 bytes and the TOC holds up to 2^16 bytes,
6 # If -fpic is not specified, the latest gcc-3.2.1 now generates
7 # different code for call stubs (without the TOC reload).
8 # Shared objects need the TOC reload so specify -fpic.
9 ifeq (yes
,$(build-shared
))
13 # These flags prevent FPU or Altivec registers from being used,
14 # for code called in contexts that is not allowed to touch those registers.
15 # Stupid GCC requires us to pass all these ridiculous switches. We need to
16 # pass the -mno-* switches as well to prevent the compiler from attempting
17 # to emit altivec or vsx instructions, especially when the registers aren't
19 no-special-regs
:= $(sort $(foreach n
,40 41 50 51 60 61 62 63 \
20 $(foreach m
,2 3 4 5 6 7 8 9, \
23 $(sort $(foreach n
,$(foreach m
,0 1 2 3 4 5 6 7 8 9,\
26 -ffixed-vrsave
-ffixed-vscr
-mno-altivec
-mno-vsx
28 # Need to prevent gcc from using fprs in code used during dynamic linking.
30 CFLAGS-dl-runtime.os
= $(no-special-regs
)
31 CFLAGS-dl-lookup.os
= $(no-special-regs
)
32 CFLAGS-dl-misc.os
= $(no-special-regs
)
33 CFLAGS-rtld-mempcpy.os
= $(no-special-regs
)
34 CFLAGS-rtld-memmove.os
= $(no-special-regs
)
35 CFLAGS-rtld-memchr.os
= $(no-special-regs
)
36 CFLAGS-rtld-strnlen.os
= $(no-special-regs
)
39 sysdep_routines
+= hp-timing
40 elide-routines.os
+= hp-timing
44 # help gcc inline asm code from dl-machine.h
45 +cflags += -finline-limit
=2000
49 # The assembly functions assume that fp arg regs are not trashed.
50 # Compiling with -msoft-float ensures that fp regs are not used
51 # for moving memory around.
52 CFLAGS-mcount.c
+= $(no-special-regs
)
53 sysdep_routines
+= ppc-mcount