r280672 - Add support for targeting armv6-unknown-cloudabi-eabihf.
Ed Schouten via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 5 11:38:34 PDT 2016
Author: ed
Date: Mon Sep 5 13:38:34 2016
New Revision: 280672
URL: http://llvm.org/viewvc/llvm-project?rev=280672&view=rev
Log:
Add support for targeting armv6-unknown-cloudabi-eabihf.
I'm in the progress of adding ARMv6 support to CloudABI. On the compiler
side, everything seems to work properly with this tiny change applied.
Modified:
cfe/trunk/lib/Basic/Targets.cpp
cfe/trunk/test/Preprocessor/init.c
Modified: cfe/trunk/lib/Basic/Targets.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/Targets.cpp?rev=280672&r1=280671&r2=280672&view=diff
==============================================================================
--- cfe/trunk/lib/Basic/Targets.cpp (original)
+++ cfe/trunk/lib/Basic/Targets.cpp Mon Sep 5 13:38:34 2016
@@ -8261,6 +8261,8 @@ static TargetInfo *AllocateTarget(const
return new DarwinARMTargetInfo(Triple, Opts);
switch (os) {
+ case llvm::Triple::CloudABI:
+ return new CloudABITargetInfo<ARMleTargetInfo>(Triple, Opts);
case llvm::Triple::Linux:
return new LinuxTargetInfo<ARMleTargetInfo>(Triple, Opts);
case llvm::Triple::FreeBSD:
Modified: cfe/trunk/test/Preprocessor/init.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Preprocessor/init.c?rev=280672&r1=280671&r2=280672&view=diff
==============================================================================
--- cfe/trunk/test/Preprocessor/init.c (original)
+++ cfe/trunk/test/Preprocessor/init.c Mon Sep 5 13:38:34 2016
@@ -1975,6 +1975,11 @@
// ARMEABIHARDFP:#define __arm 1
// ARMEABIHARDFP:#define __arm__ 1
+// RUN: %clang_cc1 -E -dM -ffreestanding -triple=armv6-unknown-cloudabi-eabihf < /dev/null | FileCheck -match-full-lines -check-prefix ARMV6-CLOUDABI %s
+//
+// ARMV6-CLOUDABI:#define __CloudABI__ 1
+// ARMV6-CLOUDABI:#define __arm__ 1
+
// RUN: %clang_cc1 -E -dM -ffreestanding -triple=arm-netbsd-eabi < /dev/null | FileCheck -match-full-lines -check-prefix ARM-NETBSD %s
//
// ARM-NETBSD-NOT:#define _LP64
More information about the cfe-commits
mailing list