[PATCH 3/9] ppc: add predefines __LONGDOUBLE128 & __LONG_DOUBLE_128__

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On powerpc, if long double is 128-bit width, then
'__LONGDOUBLE128' & '__LONG_DOUBLE_128__' should be defined.

So do this in the target specific file.

Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
---
 target-ppc.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/target-ppc.c b/target-ppc.c
index c0d6068f436a..dede8917cbd6 100644
--- a/target-ppc.c
+++ b/target-ppc.c
@@ -14,6 +14,10 @@ static void predefine_ppc(const struct target *self)
 	predefine("_ARCH_PPC", 1, "1");
 	if (arch_big_endian)
 		predefine("_BIG_ENDIAN", 1, "1");
+	if (ldouble_ctype.bit_size == 128) {
+		predefine("__LONGDOUBLE128", 1, "1");
+		predefine("__LONG_DOUBLE_128__", 1, "1");
+	}
 }
 
 static const char *asm_constraint_ppc(struct asm_operand *op, int c, const char *str)
-- 
2.27.0




[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux