[llvm-branch-commits] [cfe-branch] r287093 - Merge r280672, per bug 30839:
Author: ed Date: Wed Nov 16 04:18:17 2016 New Revision: 287093 URL: http://llvm.org/viewvc/llvm-project?rev=287093&view=rev Log: Merge r280672, per bug 30839: 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/branches/release_39/ (props changed) cfe/branches/release_39/lib/Basic/Targets.cpp cfe/branches/release_39/test/Preprocessor/init.c Propchange: cfe/branches/release_39/ -- --- svn:mergeinfo (original) +++ svn:mergeinfo Wed Nov 16 04:18:17 2016 @@ -1,4 +1,4 @@ /cfe/branches/type-system-rewrite:134693-134817 -/cfe/trunk:275880,275967,276102,276350,276361,276473,276653,276716,276887,276891,276900,276979,276983,277095,277138,277141,277221,277307,277522,277743,277783,277796-277797,277852,277866,277889,277900,278139,278156,278234-278235,278393,278395,278763,278786,278988,284110,284229,286103,286106,286129,286584,286944,286953,287025 +/cfe/trunk:275880,275967,276102,276350,276361,276473,276653,276716,276887,276891,276900,276979,276983,277095,277138,277141,277221,277307,277522,277743,277783,277796-277797,277852,277866,277889,277900,278139,278156,278234-278235,278393,278395,278763,278786,278988,280672,284110,284229,286103,286106,286129,286584,286944,286953,287025 /cfe/trunk/test:170344 /cfe/trunk/test/SemaTemplate:126920 Modified: cfe/branches/release_39/lib/Basic/Targets.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/branches/release_39/lib/Basic/Targets.cpp?rev=287093&r1=287092&r2=287093&view=diff == --- cfe/branches/release_39/lib/Basic/Targets.cpp (original) +++ cfe/branches/release_39/lib/Basic/Targets.cpp Wed Nov 16 04:18:17 2016 @@ -8170,6 +8170,8 @@ static TargetInfo *AllocateTarget(const return new DarwinARMTargetInfo(Triple, Opts); switch (os) { +case llvm::Triple::CloudABI: + return new CloudABITargetInfo(Triple, Opts); case llvm::Triple::Linux: return new LinuxTargetInfo(Triple, Opts); case llvm::Triple::FreeBSD: Modified: cfe/branches/release_39/test/Preprocessor/init.c URL: http://llvm.org/viewvc/llvm-project/cfe/branches/release_39/test/Preprocessor/init.c?rev=287093&r1=287092&r2=287093&view=diff == --- cfe/branches/release_39/test/Preprocessor/init.c (original) +++ cfe/branches/release_39/test/Preprocessor/init.c Wed Nov 16 04:18:17 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 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits
[llvm-branch-commits] [llvm-branch] r287133 - Merging r283427:
Author: tstellar Date: Wed Nov 16 12:48:06 2016 New Revision: 287133 URL: http://llvm.org/viewvc/llvm-project?rev=287133&view=rev Log: Merging r283427: r283427 | nunoplopes | 2016-10-06 02:32:16 -0700 (Thu, 06 Oct 2016) | 3 lines fix build on cygwin Cygwin has dlfcn.h, but no Dl_info Modified: llvm/branches/release_39/lib/Support/Unix/Signals.inc Modified: llvm/branches/release_39/lib/Support/Unix/Signals.inc URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_39/lib/Support/Unix/Signals.inc?rev=287133&r1=287132&r2=287133&view=diff == --- llvm/branches/release_39/lib/Support/Unix/Signals.inc (original) +++ llvm/branches/release_39/lib/Support/Unix/Signals.inc Wed Nov 16 12:48:06 2016 @@ -412,7 +412,7 @@ void llvm::sys::PrintStackTrace(raw_ostr if (printSymbolizedStackTrace(Argv0, StackTrace, depth, OS)) return; -#if HAVE_DLFCN_H && __GNUG__ +#if HAVE_DLFCN_H && __GNUG__ && !defined(__CYGWIN__) int width = 0; for (int i = 0; i < depth; ++i) { Dl_info dlinfo; ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits
[llvm-branch-commits] [llvm-branch] r287137 - Merging r280599:
Author: tstellar Date: Wed Nov 16 12:59:55 2016 New Revision: 287137 URL: http://llvm.org/viewvc/llvm-project?rev=287137&view=rev Log: Merging r280599: r280599 | mehdi.amini | 2016-09-03 14:12:33 -0700 (Sat, 03 Sep 2016) | 10 lines Fix ThinLTO crash with debug info Because the recent change about ODR type uniquing in the context, we can reach types defined in another module during IR linking. This triggered some assertions in case we IR link without starting from an empty module. To alleviate that, we can self-map metadata defined in the destination module so that they won't be visited. Differential Revision: https://reviews.llvm.org/D23841 Added: llvm/branches/release_39/test/ThinLTO/X86/Inputs/crash_debuginfo.ll llvm/branches/release_39/test/ThinLTO/X86/crash_debuginfo.ll Modified: llvm/branches/release_39/include/llvm/IR/TypeFinder.h llvm/branches/release_39/lib/Linker/IRMover.cpp Modified: llvm/branches/release_39/include/llvm/IR/TypeFinder.h URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_39/include/llvm/IR/TypeFinder.h?rev=287137&r1=287136&r2=287137&view=diff == --- llvm/branches/release_39/include/llvm/IR/TypeFinder.h (original) +++ llvm/branches/release_39/include/llvm/IR/TypeFinder.h Wed Nov 16 12:59:55 2016 @@ -59,6 +59,8 @@ public: StructType *&operator[](unsigned Idx) { return StructTypes[Idx]; } + DenseSet &getVisitedMetadata() { return VisitedMetadata; } + private: /// incorporateType - This method adds the type to the list of used /// structures if it's not in there already. Modified: llvm/branches/release_39/lib/Linker/IRMover.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_39/lib/Linker/IRMover.cpp?rev=287137&r1=287136&r2=287137&view=diff == --- llvm/branches/release_39/lib/Linker/IRMover.cpp (original) +++ llvm/branches/release_39/lib/Linker/IRMover.cpp Wed Nov 16 12:59:55 2016 @@ -1343,6 +1343,12 @@ IRMover::IRMover(Module &M) : Composite( else IdentifiedStructTypes.addNonOpaque(Ty); } + // Self-map metadatas in the destination module. This is needed when + // DebugTypeODRUniquing is enabled on the LLVMContext, since metadata in the + // destination module may be reached from the source module. + for (auto *MD : StructTypes.getVisitedMetadata()) { +SharedMDs[MD].reset(const_cast(MD)); + } } Error IRMover::move( Added: llvm/branches/release_39/test/ThinLTO/X86/Inputs/crash_debuginfo.ll URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_39/test/ThinLTO/X86/Inputs/crash_debuginfo.ll?rev=287137&view=auto == --- llvm/branches/release_39/test/ThinLTO/X86/Inputs/crash_debuginfo.ll (added) +++ llvm/branches/release_39/test/ThinLTO/X86/Inputs/crash_debuginfo.ll Wed Nov 16 12:59:55 2016 @@ -0,0 +1,33 @@ +; ModuleID = 'test/ThinLTO/X86/Inputs/crash_debuginfo.ll' +source_filename = "src.bc" +target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" +target triple = "x86_64-apple-macosx10.7.0" + +%another_type = type { i32 } + +define void @bar(i32 %arg) { + %tmp = add i32 %arg, 0, !dbg !7 + unreachable +} + +!llvm.dbg.cu = !{!0} +!llvm.module.flags = !{!6} + +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, producer: "Apple LLVM version 8.0.0 (clang-800.0.25.1)", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, retainedTypes: !2, globals: !3, imports: !2) +!1 = !DIFile(filename: "2.cpp", directory: "some_dir") +!2 = !{} +!3 = !{!4} +!4 = distinct !DIGlobalVariable(name: "a_global", linkageName: "a_global", scope: null, line: 52, type: !5, isLocal: true, isDefinition: true, variable: %another_type** undef) +!5 = !DISubroutineType(types: !2) +!6 = !{i32 2, !"Debug Info Version", i32 3} +!7 = distinct !DILocation(line: 728, column: 71, scope: !8, inlinedAt: !14) +!8 = distinct !DISubprogram(name: "baz", linkageName: "baz", scope: !9, file: !1, line: 726, type: !5, isLocal: false, isDefinition: true, scopeLine: 727, flags: DIFlagPrototyped, isOptimized: true, unit: !0, declaration: !10, variables: !11) +!9 = distinct !DICompositeType(tag: DW_TAG_class_type, name: "some_other_class", scope: !1, file: !1, line: 197, size: 192, align: 64, elements: !2, templateParams: !2, identifier: "some_other_class") +!10 = !DISubprogram(name: "baz", linkageName: "baz", scope: !9, file: !1, line: 726, type: !5, isLocal: false, isDefinition: false, scopeLine: 726, flags: DIFlagPrototyped, isOptimized: true) +!11 = !{!12} +!12 = !DILocalVariable(name: "caster", scope: !8, file: !1, line: 728, type: !13) +!13 = distinct !DICompositeType(tag: DW_TAG_union_type, scope: !8, file: