summaryrefslogtreecommitdiff
path: root/lang/libLLVM
diff options
context:
space:
mode:
authoradam <adam>2017-03-17 22:38:17 +0000
committeradam <adam>2017-03-17 22:38:17 +0000
commit3d581a0edaadbb1ff00255215faef65061a3a750 (patch)
tree3b2ed547f668606f7f14e3f812890ed21effcdcd /lang/libLLVM
parentd1bd18cc0ce17be78bec4c8412e8694009ef5516 (diff)
downloadpkgsrc-3d581a0edaadbb1ff00255215faef65061a3a750.tar.gz
LLVM 4.0.0:
The minimum compiler version required for building LLVM has been raised to 4.8 for GCC and 2015 for Visual Studio. The C API functions LLVMAddFunctionAttr, LLVMGetFunctionAttr, LLVMRemoveFunctionAttr, LLVMAddAttribute, LLVMRemoveAttribute, LLVMGetAttribute, LLVMAddInstrAttribute and LLVMRemoveInstrAttribute have been removed. The C API enum LLVMAttribute has been deleted. The definition and uses of LLVM_ATRIBUTE_UNUSED_RESULT in the LLVM source were replaced with LLVM_NODISCARD, which matches the C++17 [[nodiscard]] semantics rather than gcc’s __attribute__((warn_unused_result)). The Timer related APIs now expect a Name and Description. When upgrading code the previously used names should become descriptions and a short name in the style of a programming language identifier should be added. LLVM now handles invariant.group across different basic blocks, which makes it possible to devirtualize virtual calls inside loops. The aggressive dead code elimination phase (“adce”) now removes branches which do not effect program behavior. Loops are retained by default since they may be infinite but these can also be removed with LLVM option -adce-remove-loops when the loop body otherwise has no live operations. The llvm-cov tool can now export coverage data as json. Its html output mode has also improved.
Diffstat (limited to 'lang/libLLVM')
-rw-r--r--lang/libLLVM/Makefile4
-rw-r--r--lang/libLLVM/PLIST152
-rw-r--r--lang/libLLVM/distinfo22
-rw-r--r--lang/libLLVM/patches/patch-cmake_modules_AddLLVM.cmake47
-rw-r--r--lang/libLLVM/patches/patch-cmake_modules_CMakeLists.txt6
-rw-r--r--lang/libLLVM/patches/patch-cmake_modules_TableGen.cmake18
-rw-r--r--lang/libLLVM/patches/patch-include_llvm_Support_Host.h12
-rw-r--r--lang/libLLVM/patches/patch-tools_llvm-config_llvm-config.cpp16
-rw-r--r--lang/libLLVM/patches/patch-tools_llvm-shlib_CMakeLists.txt6
9 files changed, 179 insertions, 104 deletions
diff --git a/lang/libLLVM/Makefile b/lang/libLLVM/Makefile
index 8245f9d4c4c..f34a5e1ea25 100644
--- a/lang/libLLVM/Makefile
+++ b/lang/libLLVM/Makefile
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.18 2017/01/16 21:56:35 brook Exp $
+# $NetBSD: Makefile,v 1.19 2017/03/17 22:38:18 adam Exp $
-DISTNAME= llvm-3.9.1.src
+DISTNAME= llvm-4.0.0.src
PKGNAME= ${DISTNAME:S/llvm/libLLVM/:S/.src//}
CATEGORIES= lang devel
MASTER_SITES= http://llvm.org/releases/${PKGVERSION_NOREV}/
diff --git a/lang/libLLVM/PLIST b/lang/libLLVM/PLIST
index 2cd8b5708c5..93b592566e5 100644
--- a/lang/libLLVM/PLIST
+++ b/lang/libLLVM/PLIST
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.8 2016/11/14 20:15:33 ryoon Exp $
+@comment $NetBSD: PLIST,v 1.9 2017/03/17 22:38:18 adam Exp $
include/libLLVM/llvm-c/Analysis.h
include/libLLVM/llvm-c/BitReader.h
include/libLLVM/llvm-c/BitWriter.h
@@ -24,9 +24,11 @@ include/libLLVM/llvm-c/lto.h
include/libLLVM/llvm/ADT/APFloat.h
include/libLLVM/llvm/ADT/APInt.h
include/libLLVM/llvm/ADT/APSInt.h
+include/libLLVM/llvm/ADT/AllocatorList.h
include/libLLVM/llvm/ADT/ArrayRef.h
include/libLLVM/llvm/ADT/BitVector.h
include/libLLVM/llvm/ADT/BitmaskEnum.h
+include/libLLVM/llvm/ADT/CachedHashString.h
include/libLLVM/llvm/ADT/DAGDeltaAlgorithm.h
include/libLLVM/llvm/ADT/DeltaAlgorithm.h
include/libLLVM/llvm/ADT/DenseMap.h
@@ -58,6 +60,7 @@ include/libLLVM/llvm/ADT/PriorityQueue.h
include/libLLVM/llvm/ADT/PriorityWorklist.h
include/libLLVM/llvm/ADT/SCCIterator.h
include/libLLVM/llvm/ADT/STLExtras.h
+include/libLLVM/llvm/ADT/ScopeExit.h
include/libLLVM/llvm/ADT/ScopedHashTable.h
include/libLLVM/llvm/ADT/Sequence.h
include/libLLVM/llvm/ADT/SetOperations.h
@@ -83,9 +86,14 @@ include/libLLVM/llvm/ADT/UniqueVector.h
include/libLLVM/llvm/ADT/VariadicFunction.h
include/libLLVM/llvm/ADT/edit_distance.h
include/libLLVM/llvm/ADT/ilist.h
+include/libLLVM/llvm/ADT/ilist_base.h
+include/libLLVM/llvm/ADT/ilist_iterator.h
include/libLLVM/llvm/ADT/ilist_node.h
+include/libLLVM/llvm/ADT/ilist_node_base.h
+include/libLLVM/llvm/ADT/ilist_node_options.h
include/libLLVM/llvm/ADT/iterator.h
include/libLLVM/llvm/ADT/iterator_range.h
+include/libLLVM/llvm/ADT/simple_ilist.h
include/libLLVM/llvm/Analysis/AliasAnalysis.h
include/libLLVM/llvm/Analysis/AliasAnalysisEvaluator.h
include/libLLVM/llvm/Analysis/AliasSetTracker.h
@@ -124,16 +132,17 @@ include/libLLVM/llvm/Analysis/IntervalIterator.h
include/libLLVM/llvm/Analysis/IntervalPartition.h
include/libLLVM/llvm/Analysis/IteratedDominanceFrontier.h
include/libLLVM/llvm/Analysis/LazyBlockFrequencyInfo.h
+include/libLLVM/llvm/Analysis/LazyBranchProbabilityInfo.h
include/libLLVM/llvm/Analysis/LazyCallGraph.h
include/libLLVM/llvm/Analysis/LazyValueInfo.h
include/libLLVM/llvm/Analysis/Lint.h
include/libLLVM/llvm/Analysis/Loads.h
include/libLLVM/llvm/Analysis/LoopAccessAnalysis.h
+include/libLLVM/llvm/Analysis/LoopAnalysisManager.h
include/libLLVM/llvm/Analysis/LoopInfo.h
include/libLLVM/llvm/Analysis/LoopInfoImpl.h
include/libLLVM/llvm/Analysis/LoopIterator.h
include/libLLVM/llvm/Analysis/LoopPass.h
-include/libLLVM/llvm/Analysis/LoopPassManager.h
include/libLLVM/llvm/Analysis/LoopUnrollAnalyzer.h
include/libLLVM/llvm/Analysis/MemoryBuiltins.h
include/libLLVM/llvm/Analysis/MemoryDependenceAnalysis.h
@@ -174,11 +183,12 @@ include/libLLVM/llvm/Analysis/VectorUtils.h
include/libLLVM/llvm/AsmParser/Parser.h
include/libLLVM/llvm/AsmParser/SlotMapping.h
include/libLLVM/llvm/Bitcode/BitCodes.h
+include/libLLVM/llvm/Bitcode/BitcodeReader.h
+include/libLLVM/llvm/Bitcode/BitcodeWriter.h
include/libLLVM/llvm/Bitcode/BitcodeWriterPass.h
include/libLLVM/llvm/Bitcode/BitstreamReader.h
include/libLLVM/llvm/Bitcode/BitstreamWriter.h
include/libLLVM/llvm/Bitcode/LLVMBitCodes.h
-include/libLLVM/llvm/Bitcode/ReaderWriter.h
include/libLLVM/llvm/CodeGen/Analysis.h
include/libLLVM/llvm/CodeGen/AsmPrinter.h
include/libLLVM/llvm/CodeGen/AtomicExpandUtils.h
@@ -202,11 +212,17 @@ include/libLLVM/llvm/CodeGen/GCs.h
include/libLLVM/llvm/CodeGen/GlobalISel/CallLowering.h
include/libLLVM/llvm/CodeGen/GlobalISel/GISelAccessor.h
include/libLLVM/llvm/CodeGen/GlobalISel/IRTranslator.h
+include/libLLVM/llvm/CodeGen/GlobalISel/InstructionSelect.h
+include/libLLVM/llvm/CodeGen/GlobalISel/InstructionSelector.h
+include/libLLVM/llvm/CodeGen/GlobalISel/Legalizer.h
+include/libLLVM/llvm/CodeGen/GlobalISel/LegalizerHelper.h
+include/libLLVM/llvm/CodeGen/GlobalISel/LegalizerInfo.h
include/libLLVM/llvm/CodeGen/GlobalISel/MachineIRBuilder.h
include/libLLVM/llvm/CodeGen/GlobalISel/RegBankSelect.h
include/libLLVM/llvm/CodeGen/GlobalISel/RegisterBank.h
include/libLLVM/llvm/CodeGen/GlobalISel/RegisterBankInfo.h
include/libLLVM/llvm/CodeGen/GlobalISel/Types.h
+include/libLLVM/llvm/CodeGen/GlobalISel/Utils.h
include/libLLVM/llvm/CodeGen/ISDOpcodes.h
include/libLLVM/llvm/CodeGen/IntrinsicLowering.h
include/libLLVM/llvm/CodeGen/LatencyPriorityQueue.h
@@ -221,6 +237,7 @@ include/libLLVM/llvm/CodeGen/LiveRangeEdit.h
include/libLLVM/llvm/CodeGen/LiveRegMatrix.h
include/libLLVM/llvm/CodeGen/LiveStackAnalysis.h
include/libLLVM/llvm/CodeGen/LiveVariables.h
+include/libLLVM/llvm/CodeGen/LowLevelType.h
include/libLLVM/llvm/CodeGen/MIRParser/MIRParser.h
include/libLLVM/llvm/CodeGen/MIRYamlMapping.h
include/libLLVM/llvm/CodeGen/MachORelocation.h
@@ -233,7 +250,6 @@ include/libLLVM/llvm/CodeGen/MachineDominanceFrontier.h
include/libLLVM/llvm/CodeGen/MachineDominators.h
include/libLLVM/llvm/CodeGen/MachineFrameInfo.h
include/libLLVM/llvm/CodeGen/MachineFunction.h
-include/libLLVM/llvm/CodeGen/MachineFunctionAnalysis.h
include/libLLVM/llvm/CodeGen/MachineFunctionInitializer.h
include/libLLVM/llvm/CodeGen/MachineFunctionPass.h
include/libLLVM/llvm/CodeGen/MachineInstr.h
@@ -299,42 +315,47 @@ include/libLLVM/llvm/Config/AsmParsers.def
include/libLLVM/llvm/Config/AsmPrinters.def
include/libLLVM/llvm/Config/Disassemblers.def
include/libLLVM/llvm/Config/Targets.def
+include/libLLVM/llvm/Config/abi-breaking.h
include/libLLVM/llvm/Config/llvm-config.h
-include/libLLVM/llvm/DebugInfo/CodeView/ByteStream.h
+include/libLLVM/llvm/DebugInfo/CodeView/CVDebugRecord.h
include/libLLVM/llvm/DebugInfo/CodeView/CVRecord.h
include/libLLVM/llvm/DebugInfo/CodeView/CVSymbolTypes.def
include/libLLVM/llvm/DebugInfo/CodeView/CVSymbolVisitor.h
+include/libLLVM/llvm/DebugInfo/CodeView/CVTypeDumper.h
include/libLLVM/llvm/DebugInfo/CodeView/CVTypeVisitor.h
include/libLLVM/llvm/DebugInfo/CodeView/CodeView.h
include/libLLVM/llvm/DebugInfo/CodeView/CodeViewError.h
-include/libLLVM/llvm/DebugInfo/CodeView/CodeViewOStream.h
+include/libLLVM/llvm/DebugInfo/CodeView/CodeViewRecordIO.h
include/libLLVM/llvm/DebugInfo/CodeView/EnumTables.h
-include/libLLVM/llvm/DebugInfo/CodeView/FieldListRecordBuilder.h
include/libLLVM/llvm/DebugInfo/CodeView/FunctionId.h
include/libLLVM/llvm/DebugInfo/CodeView/Line.h
-include/libLLVM/llvm/DebugInfo/CodeView/ListRecordBuilder.h
-include/libLLVM/llvm/DebugInfo/CodeView/MemoryTypeTableBuilder.h
-include/libLLVM/llvm/DebugInfo/CodeView/MethodListRecordBuilder.h
include/libLLVM/llvm/DebugInfo/CodeView/ModuleSubstream.h
include/libLLVM/llvm/DebugInfo/CodeView/ModuleSubstreamVisitor.h
include/libLLVM/llvm/DebugInfo/CodeView/RecordSerialization.h
-include/libLLVM/llvm/DebugInfo/CodeView/StreamArray.h
-include/libLLVM/llvm/DebugInfo/CodeView/StreamInterface.h
-include/libLLVM/llvm/DebugInfo/CodeView/StreamReader.h
-include/libLLVM/llvm/DebugInfo/CodeView/StreamRef.h
-include/libLLVM/llvm/DebugInfo/CodeView/StreamWriter.h
+include/libLLVM/llvm/DebugInfo/CodeView/SymbolDeserializer.h
include/libLLVM/llvm/DebugInfo/CodeView/SymbolDumpDelegate.h
include/libLLVM/llvm/DebugInfo/CodeView/SymbolDumper.h
include/libLLVM/llvm/DebugInfo/CodeView/SymbolRecord.h
+include/libLLVM/llvm/DebugInfo/CodeView/SymbolRecordMapping.h
+include/libLLVM/llvm/DebugInfo/CodeView/SymbolSerializer.h
+include/libLLVM/llvm/DebugInfo/CodeView/SymbolVisitorCallbackPipeline.h
+include/libLLVM/llvm/DebugInfo/CodeView/SymbolVisitorCallbacks.h
include/libLLVM/llvm/DebugInfo/CodeView/SymbolVisitorDelegate.h
-include/libLLVM/llvm/DebugInfo/CodeView/TypeDumper.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeDatabase.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeDatabaseVisitor.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeDeserializer.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeDumpVisitor.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeDumperBase.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeIndex.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeRecord.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeRecordBuilder.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeRecordMapping.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeRecords.def
+include/libLLVM/llvm/DebugInfo/CodeView/TypeSerializer.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeStreamMerger.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeSymbolEmitter.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeTableBuilder.h
+include/libLLVM/llvm/DebugInfo/CodeView/TypeVisitorCallbackPipeline.h
include/libLLVM/llvm/DebugInfo/CodeView/TypeVisitorCallbacks.h
include/libLLVM/llvm/DebugInfo/DIContext.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFAbbreviationDeclaration.h
@@ -349,13 +370,29 @@ include/libLLVM/llvm/DebugInfo/DWARF/DWARFDebugInfoEntry.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFDebugLine.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFDebugLoc.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFDebugMacro.h
+include/libLLVM/llvm/DebugInfo/DWARF/DWARFDebugPubTable.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFDebugRangeList.h
+include/libLLVM/llvm/DebugInfo/DWARF/DWARFDie.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFFormValue.h
+include/libLLVM/llvm/DebugInfo/DWARF/DWARFGdbIndex.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFRelocMap.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFSection.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFTypeUnit.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFUnit.h
include/libLLVM/llvm/DebugInfo/DWARF/DWARFUnitIndex.h
+include/libLLVM/llvm/DebugInfo/MSF/ByteStream.h
+include/libLLVM/llvm/DebugInfo/MSF/IMSFFile.h
+include/libLLVM/llvm/DebugInfo/MSF/MSFBuilder.h
+include/libLLVM/llvm/DebugInfo/MSF/MSFCommon.h
+include/libLLVM/llvm/DebugInfo/MSF/MSFError.h
+include/libLLVM/llvm/DebugInfo/MSF/MSFStreamLayout.h
+include/libLLVM/llvm/DebugInfo/MSF/MappedBlockStream.h
+include/libLLVM/llvm/DebugInfo/MSF/SequencedItemStream.h
+include/libLLVM/llvm/DebugInfo/MSF/StreamArray.h
+include/libLLVM/llvm/DebugInfo/MSF/StreamInterface.h
+include/libLLVM/llvm/DebugInfo/MSF/StreamReader.h
+include/libLLVM/llvm/DebugInfo/MSF/StreamRef.h
+include/libLLVM/llvm/DebugInfo/MSF/StreamWriter.h
include/libLLVM/llvm/DebugInfo/PDB/ConcreteSymbolEnumerator.h
include/libLLVM/llvm/DebugInfo/PDB/DIA/DIADataStream.h
include/libLLVM/llvm/DebugInfo/PDB/DIA/DIAEnumDebugStreams.h
@@ -414,20 +451,14 @@ include/libLLVM/llvm/DebugInfo/PDB/PDBSymbolUsingNamespace.h
include/libLLVM/llvm/DebugInfo/PDB/PDBTypes.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/DbiStream.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/DbiStreamBuilder.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/DirectoryStreamData.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/EnumTables.h
+include/libLLVM/llvm/DebugInfo/PDB/Raw/GlobalsStream.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/Hash.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/IPDBFile.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/IPDBStreamData.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/ISectionContribVisitor.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/IndexedStreamData.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/InfoStream.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/InfoStreamBuilder.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/MappedBlockStream.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/ModInfo.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/ModStream.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/MsfBuilder.h
-include/libLLVM/llvm/DebugInfo/PDB/Raw/MsfCommon.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/NameHashTable.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/NameMap.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/NameMapBuilder.h
@@ -439,15 +470,18 @@ include/libLLVM/llvm/DebugInfo/PDB/Raw/RawError.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/RawSession.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/RawTypes.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/SymbolStream.h
+include/libLLVM/llvm/DebugInfo/PDB/Raw/TpiHashing.h
include/libLLVM/llvm/DebugInfo/PDB/Raw/TpiStream.h
+include/libLLVM/llvm/DebugInfo/PDB/Raw/TpiStreamBuilder.h
include/libLLVM/llvm/DebugInfo/Symbolize/DIPrinter.h
include/libLLVM/llvm/DebugInfo/Symbolize/SymbolizableModule.h
include/libLLVM/llvm/DebugInfo/Symbolize/Symbolize.h
+include/libLLVM/llvm/Demangle/Demangle.h
include/libLLVM/llvm/ExecutionEngine/ExecutionEngine.h
include/libLLVM/llvm/ExecutionEngine/GenericValue.h
include/libLLVM/llvm/ExecutionEngine/Interpreter.h
include/libLLVM/llvm/ExecutionEngine/JITEventListener.h
-include/libLLVM/llvm/ExecutionEngine/JITSymbolFlags.h
+include/libLLVM/llvm/ExecutionEngine/JITSymbol.h
include/libLLVM/llvm/ExecutionEngine/MCJIT.h
include/libLLVM/llvm/ExecutionEngine/OProfileWrapper.h
include/libLLVM/llvm/ExecutionEngine/ObjectCache.h
@@ -459,10 +493,8 @@ include/libLLVM/llvm/ExecutionEngine/Orc/GlobalMappingLayer.h
include/libLLVM/llvm/ExecutionEngine/Orc/IRCompileLayer.h
include/libLLVM/llvm/ExecutionEngine/Orc/IRTransformLayer.h
include/libLLVM/llvm/ExecutionEngine/Orc/IndirectionUtils.h
-include/libLLVM/llvm/ExecutionEngine/Orc/JITSymbol.h
include/libLLVM/llvm/ExecutionEngine/Orc/LambdaResolver.h
include/libLLVM/llvm/ExecutionEngine/Orc/LazyEmittingLayer.h
-include/libLLVM/llvm/ExecutionEngine/Orc/LogicalDylib.h
include/libLLVM/llvm/ExecutionEngine/Orc/NullResolver.h
include/libLLVM/llvm/ExecutionEngine/Orc/ObjectLinkingLayer.h
include/libLLVM/llvm/ExecutionEngine/Orc/ObjectTransformLayer.h
@@ -471,8 +503,9 @@ include/libLLVM/llvm/ExecutionEngine/Orc/OrcError.h
include/libLLVM/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h
include/libLLVM/llvm/ExecutionEngine/Orc/OrcRemoteTargetRPCAPI.h
include/libLLVM/llvm/ExecutionEngine/Orc/OrcRemoteTargetServer.h
-include/libLLVM/llvm/ExecutionEngine/Orc/RPCChannel.h
+include/libLLVM/llvm/ExecutionEngine/Orc/RPCSerialization.h
include/libLLVM/llvm/ExecutionEngine/Orc/RPCUtils.h
+include/libLLVM/llvm/ExecutionEngine/Orc/RawByteChannel.h
include/libLLVM/llvm/ExecutionEngine/OrcMCJITReplacement.h
include/libLLVM/llvm/ExecutionEngine/RTDyldMemoryManager.h
include/libLLVM/llvm/ExecutionEngine/RuntimeDyld.h
@@ -480,8 +513,8 @@ include/libLLVM/llvm/ExecutionEngine/RuntimeDyldChecker.h
include/libLLVM/llvm/ExecutionEngine/SectionMemoryManager.h
include/libLLVM/llvm/IR/Argument.h
include/libLLVM/llvm/IR/AssemblyAnnotationWriter.h
+include/libLLVM/llvm/IR/Attributes.gen
include/libLLVM/llvm/IR/Attributes.h
-include/libLLVM/llvm/IR/Attributes.inc
include/libLLVM/llvm/IR/Attributes.td
include/libLLVM/llvm/IR/AutoUpgrade.h
include/libLLVM/llvm/IR/BasicBlock.h
@@ -548,6 +581,7 @@ include/libLLVM/llvm/IR/Metadata.h
include/libLLVM/llvm/IR/Module.h
include/libLLVM/llvm/IR/ModuleSlotTracker.h
include/libLLVM/llvm/IR/ModuleSummaryIndex.h
+include/libLLVM/llvm/IR/ModuleSummaryIndexYAML.h
include/libLLVM/llvm/IR/NoFolder.h
include/libLLVM/llvm/IR/OperandTraits.h
include/libLLVM/llvm/IR/Operator.h
@@ -574,7 +608,10 @@ include/libLLVM/llvm/IR/ValueSymbolTable.h
include/libLLVM/llvm/IR/Verifier.h
include/libLLVM/llvm/IRReader/IRReader.h
include/libLLVM/llvm/InitializePasses.h
+include/libLLVM/llvm/LTO/Caching.h
+include/libLLVM/llvm/LTO/Config.h
include/libLLVM/llvm/LTO/LTO.h
+include/libLLVM/llvm/LTO/LTOBackend.h
include/libLLVM/llvm/LTO/legacy/LTOCodeGenerator.h
include/libLLVM/llvm/LTO/legacy/LTOModule.h
include/libLLVM/llvm/LTO/legacy/ThinLTOCodeGenerator.h
@@ -586,6 +623,7 @@ include/libLLVM/llvm/LinkAllPasses.h
include/libLLVM/llvm/Linker/IRMover.h
include/libLLVM/llvm/Linker/Linker.h
include/libLLVM/llvm/MC/ConstantPools.h
+include/libLLVM/llvm/MC/LaneBitmask.h
include/libLLVM/llvm/MC/MCAsmBackend.h
include/libLLVM/llvm/MC/MCAsmInfo.h
include/libLLVM/llvm/MC/MCAsmInfoCOFF.h
@@ -658,6 +696,7 @@ include/libLLVM/llvm/Object/ArchiveWriter.h
include/libLLVM/llvm/Object/Binary.h
include/libLLVM/llvm/Object/COFF.h
include/libLLVM/llvm/Object/COFFImportFile.h
+include/libLLVM/llvm/Object/Decompressor.h
include/libLLVM/llvm/Object/ELF.h
include/libLLVM/llvm/Object/ELFObjectFile.h
include/libLLVM/llvm/Object/ELFTypes.h
@@ -666,12 +705,15 @@ include/libLLVM/llvm/Object/IRObjectFile.h
include/libLLVM/llvm/Object/MachO.h
include/libLLVM/llvm/Object/MachOUniversal.h
include/libLLVM/llvm/Object/ModuleSummaryIndexObjectFile.h
+include/libLLVM/llvm/Object/ModuleSymbolTable.h
include/libLLVM/llvm/Object/ObjectFile.h
include/libLLVM/llvm/Object/RelocVisitor.h
include/libLLVM/llvm/Object/StackMapParser.h
include/libLLVM/llvm/Object/SymbolSize.h
include/libLLVM/llvm/Object/SymbolicFile.h
+include/libLLVM/llvm/Object/Wasm.h
include/libLLVM/llvm/ObjectYAML/COFFYAML.h
+include/libLLVM/llvm/ObjectYAML/DWARFYAML.h
include/libLLVM/llvm/ObjectYAML/ELFYAML.h
include/libLLVM/llvm/ObjectYAML/MachOYAML.h
include/libLLVM/llvm/ObjectYAML/ObjectYAML.h
@@ -717,6 +759,7 @@ include/libLLVM/llvm/Support/COM.h
include/libLLVM/llvm/Support/CachePruning.h
include/libLLVM/llvm/Support/Capacity.h
include/libLLVM/llvm/Support/Casting.h
+include/libLLVM/llvm/Support/Chrono.h
include/libLLVM/llvm/Support/CodeGen.h
include/libLLVM/llvm/Support/CodeGenCWrappers.h
include/libLLVM/llvm/Support/CommandLine.h
@@ -726,7 +769,6 @@ include/libLLVM/llvm/Support/ConvertUTF.h
include/libLLVM/llvm/Support/CrashRecoveryContext.h
include/libLLVM/llvm/Support/DOTGraphTraits.h
include/libLLVM/llvm/Support/DataExtractor.h
-include/libLLVM/llvm/Support/DataStream.h
include/libLLVM/llvm/Support/DataTypes.h
include/libLLVM/llvm/Support/Debug.h
include/libLLVM/llvm/Support/Dwarf.def
@@ -743,6 +785,7 @@ include/libLLVM/llvm/Support/ELFRelocs/Lanai.def
include/libLLVM/llvm/Support/ELFRelocs/Mips.def
include/libLLVM/llvm/Support/ELFRelocs/PowerPC.def
include/libLLVM/llvm/Support/ELFRelocs/PowerPC64.def
+include/libLLVM/llvm/Support/ELFRelocs/RISCV.def
include/libLLVM/llvm/Support/ELFRelocs/Sparc.def
include/libLLVM/llvm/Support/ELFRelocs/SystemZ.def
include/libLLVM/llvm/Support/ELFRelocs/WebAssembly.def
@@ -759,10 +802,16 @@ include/libLLVM/llvm/Support/FileOutputBuffer.h
include/libLLVM/llvm/Support/FileSystem.h
include/libLLVM/llvm/Support/FileUtilities.h
include/libLLVM/llvm/Support/Format.h
+include/libLLVM/llvm/Support/FormatAdapters.h
+include/libLLVM/llvm/Support/FormatCommon.h
+include/libLLVM/llvm/Support/FormatProviders.h
+include/libLLVM/llvm/Support/FormatVariadic.h
+include/libLLVM/llvm/Support/FormatVariadicDetails.h
include/libLLVM/llvm/Support/FormattedStream.h
include/libLLVM/llvm/Support/GCOV.h
include/libLLVM/llvm/Support/GenericDomTree.h
include/libLLVM/llvm/Support/GenericDomTreeConstruction.h
+include/libLLVM/llvm/Support/GlobPattern.h
include/libLLVM/llvm/Support/GraphWriter.h
include/libLLVM/llvm/Support/Host.h
include/libLLVM/llvm/Support/JamCRC.h
@@ -778,10 +827,10 @@ include/libLLVM/llvm/Support/ManagedStatic.h
include/libLLVM/llvm/Support/MathExtras.h
include/libLLVM/llvm/Support/Memory.h
include/libLLVM/llvm/Support/MemoryBuffer.h
-include/libLLVM/llvm/Support/MemoryObject.h
include/libLLVM/llvm/Support/MipsABIFlags.h
include/libLLVM/llvm/Support/Mutex.h
include/libLLVM/llvm/Support/MutexGuard.h
+include/libLLVM/llvm/Support/NativeFormatting.h
include/libLLVM/llvm/Support/OnDiskHashTable.h
include/libLLVM/llvm/Support/Options.h
include/libLLVM/llvm/Support/Path.h
@@ -806,26 +855,27 @@ include/libLLVM/llvm/Support/Signals.h
include/libLLVM/llvm/Support/Solaris.h
include/libLLVM/llvm/Support/SourceMgr.h
include/libLLVM/llvm/Support/SpecialCaseList.h
-include/libLLVM/llvm/Support/StreamingMemoryObject.h
include/libLLVM/llvm/Support/StringPool.h
include/libLLVM/llvm/Support/StringSaver.h
include/libLLVM/llvm/Support/SwapByteOrder.h
include/libLLVM/llvm/Support/SystemUtils.h
+include/libLLVM/llvm/Support/TarWriter.h
include/libLLVM/llvm/Support/TargetParser.h
include/libLLVM/llvm/Support/TargetRegistry.h
include/libLLVM/llvm/Support/TargetSelect.h
include/libLLVM/llvm/Support/ThreadLocal.h
include/libLLVM/llvm/Support/ThreadPool.h
include/libLLVM/llvm/Support/Threading.h
-include/libLLVM/llvm/Support/TimeValue.h
include/libLLVM/llvm/Support/Timer.h
include/libLLVM/llvm/Support/ToolOutputFile.h
include/libLLVM/llvm/Support/TrailingObjects.h
+include/libLLVM/llvm/Support/TrigramIndex.h
include/libLLVM/llvm/Support/TypeName.h
include/libLLVM/llvm/Support/Unicode.h
include/libLLVM/llvm/Support/UnicodeCharRanges.h
include/libLLVM/llvm/Support/UniqueLock.h
include/libLLVM/llvm/Support/Valgrind.h
+include/libLLVM/llvm/Support/Wasm.h
include/libLLVM/llvm/Support/Watchdog.h
include/libLLVM/llvm/Support/Win64EH.h
include/libLLVM/llvm/Support/WindowsError.h
@@ -837,6 +887,7 @@ include/libLLVM/llvm/Support/raw_ostream.h
include/libLLVM/llvm/Support/raw_sha1_ostream.h
include/libLLVM/llvm/Support/thread.h
include/libLLVM/llvm/Support/type_traits.h
+include/libLLVM/llvm/Support/xxhash.h
include/libLLVM/llvm/TableGen/Error.h
include/libLLVM/llvm/TableGen/Main.h
include/libLLVM/llvm/TableGen/Record.h
@@ -851,6 +902,7 @@ include/libLLVM/llvm/Target/Target.td
include/libLLVM/llvm/Target/TargetCallingConv.h
include/libLLVM/llvm/Target/TargetCallingConv.td
include/libLLVM/llvm/Target/TargetFrameLowering.h
+include/libLLVM/llvm/Target/TargetGlobalISel.td
include/libLLVM/llvm/Target/TargetInstrInfo.h
include/libLLVM/llvm/Target/TargetIntrinsicInfo.h
include/libLLVM/llvm/Target/TargetItinerary.td
@@ -860,13 +912,14 @@ include/libLLVM/llvm/Target/TargetMachine.h
include/libLLVM/llvm/Target/TargetOpcodes.def
include/libLLVM/llvm/Target/TargetOpcodes.h
include/libLLVM/llvm/Target/TargetOptions.h
-include/libLLVM/llvm/Target/TargetRecip.h
include/libLLVM/llvm/Target/TargetRegisterInfo.h
include/libLLVM/llvm/Target/TargetSchedule.td
include/libLLVM/llvm/Target/TargetSelectionDAG.td
include/libLLVM/llvm/Target/TargetSubtargetInfo.h
+include/libLLVM/llvm/Transforms/Coroutines.h
include/libLLVM/llvm/Transforms/GCOVProfiler.h
include/libLLVM/llvm/Transforms/IPO.h
+include/libLLVM/llvm/Transforms/IPO/AlwaysInliner.h
include/libLLVM/llvm/Transforms/IPO/ConstantMerge.h
include/libLLVM/llvm/Transforms/IPO/CrossDSOCFI.h
include/libLLVM/llvm/Transforms/IPO/DeadArgumentElimination.h
@@ -876,8 +929,9 @@ include/libLLVM/llvm/Transforms/IPO/FunctionAttrs.h
include/libLLVM/llvm/Transforms/IPO/FunctionImport.h
include/libLLVM/llvm/Transforms/IPO/GlobalDCE.h
include/libLLVM/llvm/Transforms/IPO/GlobalOpt.h
+include/libLLVM/llvm/Transforms/IPO/GlobalSplit.h
include/libLLVM/llvm/Transforms/IPO/InferFunctionAttrs.h
-include/libLLVM/llvm/Transforms/IPO/InlinerPass.h
+include/libLLVM/llvm/Transforms/IPO/Inliner.h
include/libLLVM/llvm/Transforms/IPO/Internalize.h
include/libLLVM/llvm/Transforms/IPO/LowerTypeTests.h
include/libLLVM/llvm/Transforms/IPO/PartialInlining.h
@@ -903,48 +957,66 @@ include/libLLVM/llvm/Transforms/Scalar/DeadStoreElimination.h
include/libLLVM/llvm/Transforms/Scalar/EarlyCSE.h
include/libLLVM/llvm/Transforms/Scalar/Float2Int.h
include/libLLVM/llvm/Transforms/Scalar/GVN.h
+include/libLLVM/llvm/Transforms/Scalar/GVNExpression.h
include/libLLVM/llvm/Transforms/Scalar/GuardWidening.h
+include/libLLVM/llvm/Transforms/Scalar/IVUsersPrinter.h
include/libLLVM/llvm/Transforms/Scalar/IndVarSimplify.h
include/libLLVM/llvm/Transforms/Scalar/JumpThreading.h
include/libLLVM/llvm/Transforms/Scalar/LICM.h
+include/libLLVM/llvm/Transforms/Scalar/LoopAccessAnalysisPrinter.h
+include/libLLVM/llvm/Transforms/Scalar/LoopDataPrefetch.h
include/libLLVM/llvm/Transforms/Scalar/LoopDeletion.h
include/libLLVM/llvm/Transforms/Scalar/LoopDistribute.h
include/libLLVM/llvm/Transforms/Scalar/LoopIdiomRecognize.h
include/libLLVM/llvm/Transforms/Scalar/LoopInstSimplify.h
+include/libLLVM/llvm/Transforms/Scalar/LoopPassManager.h
include/libLLVM/llvm/Transforms/Scalar/LoopRotation.h
include/libLLVM/llvm/Transforms/Scalar/LoopSimplifyCFG.h
+include/libLLVM/llvm/Transforms/Scalar/LoopStrengthReduce.h
+include/libLLVM/llvm/Transforms/Scalar/LoopUnrollPass.h
include/libLLVM/llvm/Transforms/Scalar/LowerAtomic.h
include/libLLVM/llvm/Transforms/Scalar/LowerExpectIntrinsic.h
+include/libLLVM/llvm/Transforms/Scalar/LowerGuardIntrinsic.h
include/libLLVM/llvm/Transforms/Scalar/MemCpyOptimizer.h
include/libLLVM/llvm/Transforms/Scalar/MergedLoadStoreMotion.h
+include/libLLVM/llvm/Transforms/Scalar/NaryReassociate.h
+include/libLLVM/llvm/Transforms/Scalar/NewGVN.h
include/libLLVM/llvm/Transforms/Scalar/PartiallyInlineLibCalls.h
include/libLLVM/llvm/Transforms/Scalar/Reassociate.h
include/libLLVM/llvm/Transforms/Scalar/SCCP.h
include/libLLVM/llvm/Transforms/Scalar/SROA.h
include/libLLVM/llvm/Transforms/Scalar/SimplifyCFG.h
include/libLLVM/llvm/Transforms/Scalar/Sink.h
+include/libLLVM/llvm/Transforms/Scalar/SpeculativeExecution.h
include/libLLVM/llvm/Transforms/Scalar/TailRecursionElimination.h
include/libLLVM/llvm/Transforms/Utils/ASanStackFrameLayout.h
include/libLLVM/llvm/Transforms/Utils/AddDiscriminators.h
include/libLLVM/llvm/Transforms/Utils/BasicBlockUtils.h
+include/libLLVM/llvm/Transforms/Utils/BreakCriticalEdges.h
include/libLLVM/llvm/Transforms/Utils/BuildLibCalls.h
include/libLLVM/llvm/Transforms/Utils/BypassSlowDivision.h
include/libLLVM/llvm/Transforms/Utils/Cloning.h
include/libLLVM/llvm/Transforms/Utils/CmpInstAnalysis.h
include/libLLVM/llvm/Transforms/Utils/CodeExtractor.h
include/libLLVM/llvm/Transforms/Utils/CtorUtils.h
+include/libLLVM/llvm/Transforms/Utils/EscapeEnumerator.h
include/libLLVM/llvm/Transforms/Utils/Evaluator.h
+include/libLLVM/llvm/Transforms/Utils/FunctionComparator.h
include/libLLVM/llvm/Transforms/Utils/FunctionImportUtils.h
include/libLLVM/llvm/Transforms/Utils/GlobalStatus.h
+include/libLLVM/llvm/Transforms/Utils/ImportedFunctionsInliningStatistics.h
include/libLLVM/llvm/Transforms/Utils/IntegerDivision.h
include/libLLVM/llvm/Transforms/Utils/LCSSA.h
+include/libLLVM/llvm/Transforms/Utils/LibCallsShrinkWrap.h
include/libLLVM/llvm/Transforms/Utils/Local.h
include/libLLVM/llvm/Transforms/Utils/LoopSimplify.h
include/libLLVM/llvm/Transforms/Utils/LoopUtils.h
include/libLLVM/llvm/Transforms/Utils/LoopVersioning.h
+include/libLLVM/llvm/Transforms/Utils/LowerInvoke.h
include/libLLVM/llvm/Transforms/Utils/Mem2Reg.h
include/libLLVM/llvm/Transforms/Utils/MemorySSA.h
include/libLLVM/llvm/Transforms/Utils/ModuleUtils.h
+include/libLLVM/llvm/Transforms/Utils/NameAnonGlobals.h
include/libLLVM/llvm/Transforms/Utils/PromoteMemToReg.h
include/libLLVM/llvm/Transforms/Utils/SSAUpdater.h
include/libLLVM/llvm/Transforms/Utils/SSAUpdaterImpl.h
@@ -962,13 +1034,25 @@ include/libLLVM/llvm/Transforms/Vectorize/LoopVectorize.h
include/libLLVM/llvm/Transforms/Vectorize/SLPVectorizer.h
${PLIST.notdylib}lib/libLLVM/libLLVM-${LLVM_MAJOR_MINOR}.${SOEXT}
${PLIST.notdylib}lib/libLLVM/libLLVM-${PKGVERSION}.${SOEXT}
+include/libLLVM/llvm/XRay/Trace.h
+include/libLLVM/llvm/XRay/XRayRecord.h
+include/libLLVM/llvm/XRay/YAMLXRayRecord.h
lib/libLLVM/libLLVM.${SOEXT}
+libexec/libLLVM/llvm-cat
libexec/libLLVM/llvm-config
+libexec/libLLVM/llvm-cxxfilt
+libexec/libLLVM/llvm-lto2
+libexec/libLLVM/llvm-modextract
+libexec/libLLVM/llvm-opt-report
+libexec/libLLVM/llvm-strings
+libexec/libLLVM/llvm-xray
share/libLLVM/cmake/AddLLVM.cmake
share/libLLVM/cmake/AddLLVMDefinitions.cmake
share/libLLVM/cmake/AddOCaml.cmake
share/libLLVM/cmake/AddSphinxTarget.cmake
+share/libLLVM/cmake/CheckAtomic.cmake
share/libLLVM/cmake/CheckCompilerVersion.cmake
+share/libLLVM/cmake/CheckLinkerFlag.cmake
share/libLLVM/cmake/ChooseMSVCCRT.cmake
share/libLLVM/cmake/CrossCompile.cmake
share/libLLVM/cmake/DetermineGCCCompatible.cmake
diff --git a/lang/libLLVM/distinfo b/lang/libLLVM/distinfo
index 44e26924ce3..6e0c310d0d1 100644
--- a/lang/libLLVM/distinfo
+++ b/lang/libLLVM/distinfo
@@ -1,15 +1,15 @@
-$NetBSD: distinfo,v 1.8 2017/03/09 12:45:56 jperkin Exp $
+$NetBSD: distinfo,v 1.9 2017/03/17 22:38:18 adam Exp $
-SHA1 (llvm-3.9.1.src.tar.xz) = ce801cf456b8dacd565ce8df8288b4d90e7317ff
-RMD160 (llvm-3.9.1.src.tar.xz) = b0a3c68cfec83a2b4dad6922316b71c0dc25c40a
-SHA512 (llvm-3.9.1.src.tar.xz) = 50cbe8ee911080f586e77861c442348701bd02e2de0c090c54c34f82ac275ecfcd712af0f41e387c33b4a6057778a4258a27554292fe68ab4af3fd9dd6d90683
-Size (llvm-3.9.1.src.tar.xz) = 18130436 bytes
+SHA1 (llvm-4.0.0.src.tar.xz) = aee4524e2407f9fe5afc6f70c753180b907011d0
+RMD160 (llvm-4.0.0.src.tar.xz) = 468ae2502ba523b35c5e8340724ddaa50b31ccb5
+SHA512 (llvm-4.0.0.src.tar.xz) = cf681f0626ef6d568d951cdc3e143471a1d7715a0ba11e52aa273cf5d8d421e1357ef2645cc85879eaefcd577e99e74d07b01566825b3d0461171ef2cbfc7704
+Size (llvm-4.0.0.src.tar.xz) = 21016340 bytes
SHA1 (patch-CMakeLists.txt) = 770e0bc00a987430b6c6be7e4141f33e5be54a8f
-SHA1 (patch-cmake_modules_AddLLVM.cmake) = 1fd7598a55eede8b1ef50556ab8d7277fe5b2f43
-SHA1 (patch-cmake_modules_CMakeLists.txt) = bf31e9d3914e2041a7d435390b63ad67282b272f
+SHA1 (patch-cmake_modules_AddLLVM.cmake) = d9d9b8f9d33ddc3ef8ef55832aeed038500b6de8
+SHA1 (patch-cmake_modules_CMakeLists.txt) = 69514dafb36794eb6923a39ef219bdc7b09c37ee
SHA1 (patch-cmake_modules_HandleLLVMOptions.cmake) = 271e6f5a8cebf8162c4e3b758e96f451b434269b
-SHA1 (patch-cmake_modules_TableGen.cmake) = d548208577f45fbb6c8f7b43548c399cc63c7887
-SHA1 (patch-include_llvm_Support_Host.h) = ad6ac520f15bba96ab887c962fb717e22aaee7bf
+SHA1 (patch-cmake_modules_TableGen.cmake) = 105aece4014c473a21ec6b427893239bbe881f89
+SHA1 (patch-include_llvm_Support_Host.h) = a4e19a72714084b211b0182c04ccc51bd606e150
SHA1 (patch-lib_Support_Unix_Program.inc) = 49f09e05858243ca57f14b1fdb2fec49c935dfeb
-SHA1 (patch-tools_llvm-config_llvm-config.cpp) = 44835bfcd2bddc16e0b93628fafb627889091f85
-SHA1 (patch-tools_llvm-shlib_CMakeLists.txt) = 8faddae24e937ce0b60a7b6a69370c56b9ff7fe3
+SHA1 (patch-tools_llvm-config_llvm-config.cpp) = 4988cd94074cb08dbb5a3606ea2376b42ae8c75f
+SHA1 (patch-tools_llvm-shlib_CMakeLists.txt) = 18e6ec7b8895e55ecdf93c9d4781e92052a6fcb1
diff --git a/lang/libLLVM/patches/patch-cmake_modules_AddLLVM.cmake b/lang/libLLVM/patches/patch-cmake_modules_AddLLVM.cmake
index e3e46aac61b..a7be4502711 100644
--- a/lang/libLLVM/patches/patch-cmake_modules_AddLLVM.cmake
+++ b/lang/libLLVM/patches/patch-cmake_modules_AddLLVM.cmake
@@ -1,60 +1,53 @@
-$NetBSD: patch-cmake_modules_AddLLVM.cmake,v 1.3 2016/11/14 20:15:33 ryoon Exp $
+$NetBSD: patch-cmake_modules_AddLLVM.cmake,v 1.4 2017/03/17 22:38:18 adam Exp $
Disable library install rules. Handled manually.
Make sure llvm-config goes in libexec/libLLVM to avoid conflict.
Don't use non-portable -z discard-unused on SunOS.
---- cmake/modules/AddLLVM.cmake.orig 2016-07-10 02:43:47.000000000 +0000
+--- cmake/modules/AddLLVM.cmake.orig 2017-01-17 21:47:58.000000000 +0000
+++ cmake/modules/AddLLVM.cmake
-@@ -174,9 +174,9 @@ function(add_link_opts target_name)
+@@ -182,9 +182,6 @@ function(add_link_opts target_name)
# ld64's implementation of -dead_strip breaks tools that use plugins.
set_property(TARGET ${target_name} APPEND_STRING PROPERTY
LINK_FLAGS " -Wl,-dead_strip")
- elseif(${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
- set_property(TARGET ${target_name} APPEND_STRING PROPERTY
- LINK_FLAGS " -Wl,-z -Wl,discard-unused=sections")
-+# elseif(${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
-+# set_property(TARGET ${target_name} APPEND_STRING PROPERTY
-+# LINK_FLAGS " -Wl,-z -Wl,discard-unused=sections")
elseif(NOT WIN32 AND NOT LLVM_LINKER_IS_GOLD)
# Object files are compiled with -ffunction-data-sections.
# Versions of bfd ld < 2.23.1 have a bug in --gc-sections that breaks
-@@ -558,10 +558,12 @@ macro(add_llvm_library name)
- set(install_type ARCHIVE)
+@@ -591,10 +588,6 @@ macro(add_llvm_library name)
+ set_property(GLOBAL PROPERTY LLVM_HAS_EXPORTS True)
endif()
-+ if (false)
- install(TARGETS ${name}
- EXPORT LLVMExports
- ${install_type} DESTINATION ${install_dir}
- COMPONENT ${name})
-+ endif()
+- install(TARGETS ${name}
+- ${export_to_llvmexports}
+- ${install_type} DESTINATION ${install_dir}
+- COMPONENT ${name})
if (NOT CMAKE_CONFIGURATION_TYPES)
add_custom_target(install-${name}
-@@ -592,10 +594,12 @@ macro(add_llvm_loadable_module name)
- else()
- set(dlldir "lib${LLVM_LIBDIR_SUFFIX}")
+@@ -632,10 +625,6 @@ macro(add_llvm_loadable_module name)
+ set_property(GLOBAL PROPERTY LLVM_HAS_EXPORTS True)
endif()
-+ if (false)
- install(TARGETS ${name}
- EXPORT LLVMExports
- LIBRARY DESTINATION ${dlldir}
- ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
-+ endif()
+
+- install(TARGETS ${name}
+- ${export_to_llvmexports}
+- LIBRARY DESTINATION ${dlldir}
+- ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
endif()
set_property(GLOBAL APPEND PROPERTY LLVM_EXPORTS ${name})
endif()
-@@ -770,7 +774,7 @@ macro(add_llvm_tool name)
- if( LLVM_BUILD_TOOLS )
+@@ -823,7 +812,7 @@ macro(add_llvm_tool name)
+
install(TARGETS ${name}
- EXPORT LLVMExports
+ ${export_to_llvmexports}
- RUNTIME DESTINATION ${LLVM_TOOLS_INSTALL_DIR}
+ RUNTIME DESTINATION libexec/libLLVM
COMPONENT ${name})
if (NOT CMAKE_CONFIGURATION_TYPES)
-@@ -811,7 +815,7 @@ macro(add_llvm_utility name)
+@@ -864,7 +853,7 @@ macro(add_llvm_utility name)
set_target_properties(${name} PROPERTIES FOLDER "Utils")
if( LLVM_INSTALL_UTILS AND LLVM_BUILD_UTILS )
install (TARGETS ${name}
diff --git a/lang/libLLVM/patches/patch-cmake_modules_CMakeLists.txt b/lang/libLLVM/patches/patch-cmake_modules_CMakeLists.txt
index f0e83e12f97..e3dc3d02cad 100644
--- a/lang/libLLVM/patches/patch-cmake_modules_CMakeLists.txt
+++ b/lang/libLLVM/patches/patch-cmake_modules_CMakeLists.txt
@@ -1,12 +1,12 @@
-$NetBSD: patch-cmake_modules_CMakeLists.txt,v 1.2 2016/11/14 20:15:33 ryoon Exp $
+$NetBSD: patch-cmake_modules_CMakeLists.txt,v 1.3 2017/03/17 22:38:18 adam Exp $
Make sure cmake rules go in own directory to avoid conflicts.
---- cmake/modules/CMakeLists.txt.orig 2016-06-22 21:01:19.000000000 +0000
+--- cmake/modules/CMakeLists.txt.orig 2016-11-08 05:02:18.000000000 +0000
+++ cmake/modules/CMakeLists.txt
@@ -1,4 +1,4 @@
-set(LLVM_INSTALL_PACKAGE_DIR lib${LLVM_LIBDIR_SUFFIX}/cmake/llvm)
+set(LLVM_INSTALL_PACKAGE_DIR share/libLLVM/cmake)
set(llvm_cmake_builddir "${LLVM_BINARY_DIR}/${LLVM_INSTALL_PACKAGE_DIR}")
- get_property(LLVM_EXPORTS GLOBAL PROPERTY LLVM_EXPORTS)
+ # First for users who use an installed LLVM, create the LLVMExports.cmake file.
diff --git a/lang/libLLVM/patches/patch-cmake_modules_TableGen.cmake b/lang/libLLVM/patches/patch-cmake_modules_TableGen.cmake
index fcb2e2eeaf0..91542a9c397 100644
--- a/lang/libLLVM/patches/patch-cmake_modules_TableGen.cmake
+++ b/lang/libLLVM/patches/patch-cmake_modules_TableGen.cmake
@@ -1,15 +1,15 @@
-$NetBSD: patch-cmake_modules_TableGen.cmake,v 1.2 2016/11/14 20:15:33 ryoon Exp $
+$NetBSD: patch-cmake_modules_TableGen.cmake,v 1.3 2017/03/17 22:38:18 adam Exp $
Disable install of llvm-tblgen, provided by lang/llvm.
---- cmake/modules/TableGen.cmake.orig 2016-06-08 21:19:26.000000000 +0000
+--- cmake/modules/TableGen.cmake.orig 2016-12-06 17:09:29.000000000 +0000
+++ cmake/modules/TableGen.cmake
-@@ -138,7 +138,7 @@ macro(add_tablegen target project)
- set_target_properties(${target} PROPERTIES LINK_FLAGS -Wl,--stack,16777216)
- endif(CMAKE_SIZEOF_VOID_P MATCHES "8")
- endif( MINGW )
+@@ -134,7 +134,7 @@ macro(add_tablegen target project)
+ endif()
+ endif()
+
- if (${project} STREQUAL LLVM AND NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
+ if (${project} STREQUAL LLVM AND NOT LLVM_INSTALL_TOOLCHAIN_ONLY AND false)
- install(TARGETS ${target}
- EXPORT LLVMExports
- RUNTIME DESTINATION ${LLVM_TOOLS_INSTALL_DIR})
+ if(${target} IN_LIST LLVM_DISTRIBUTION_COMPONENTS OR
+ NOT LLVM_DISTRIBUTION_COMPONENTS)
+ set(export_to_llvmexports EXPORT LLVMExports)
diff --git a/lang/libLLVM/patches/patch-include_llvm_Support_Host.h b/lang/libLLVM/patches/patch-include_llvm_Support_Host.h
index fe847f628c9..c10ff6f1a0f 100644
--- a/lang/libLLVM/patches/patch-include_llvm_Support_Host.h
+++ b/lang/libLLVM/patches/patch-include_llvm_Support_Host.h
@@ -1,19 +1,18 @@
-$NetBSD: patch-include_llvm_Support_Host.h,v 1.2 2016/11/14 20:15:33 ryoon Exp $
+$NetBSD: patch-include_llvm_Support_Host.h,v 1.3 2017/03/17 22:38:18 adam Exp $
Fix lack of machine/endian.h on solaris
http://permalink.gmane.org/gmane.comp.compilers.llvm.devel/63225
---- include/llvm/Support/Host.h.orig 2016-02-26 17:01:45.000000000 +0000
+--- include/llvm/Support/Host.h.orig 2016-10-13 17:43:20.000000000 +0000
+++ include/llvm/Support/Host.h
-@@ -18,6 +18,20 @@
-
- #if defined(__linux__) || defined(__GNU__) || defined(__HAIKU__)
+@@ -20,6 +20,18 @@
#include <endian.h>
+ #elif defined(_AIX)
+ #include <sys/machine.h>
+#elif defined(__sun) & defined(__SVR4)
+# ifndef BYTE_ORDER
+# define LITTLE_ENDIAN 1234
+# define BIG_ENDIAN 4321
-+# if defined(__sun) & defined(__SVR4)
+# include <sys/isa_defs.h>
+# ifdef _LITTLE_ENDIAN
+# define BYTE_ORDER LITTLE_ENDIAN
@@ -21,7 +20,6 @@ http://permalink.gmane.org/gmane.comp.compilers.llvm.devel/63225
+# ifdef _BIG_ENDIAN
+# define BYTE_ORDER BIG_ENDIAN
+# endif
-+# endif /* sun */
+# endif /* BYTE_ORDER */
#else
#if !defined(BYTE_ORDER) && !defined(LLVM_ON_WIN32)
diff --git a/lang/libLLVM/patches/patch-tools_llvm-config_llvm-config.cpp b/lang/libLLVM/patches/patch-tools_llvm-config_llvm-config.cpp
index 89750748018..8d15a4228dc 100644
--- a/lang/libLLVM/patches/patch-tools_llvm-config_llvm-config.cpp
+++ b/lang/libLLVM/patches/patch-tools_llvm-config_llvm-config.cpp
@@ -1,12 +1,12 @@
-$NetBSD: patch-tools_llvm-config_llvm-config.cpp,v 1.2 2016/11/14 20:15:33 ryoon Exp $
+$NetBSD: patch-tools_llvm-config_llvm-config.cpp,v 1.3 2017/03/17 22:38:18 adam Exp $
-avoid conflict with lang/clang.
+Avoid conflict with lang/clang.
Use -lLLVM-3.8 instead of -lLLVM-3.8.0 so we don't break unnecessarily
on patch updates.
---- tools/llvm-config/llvm-config.cpp.orig 2016-03-14 21:39:58.000000000 +0000
+--- tools/llvm-config/llvm-config.cpp.orig 2017-01-12 19:47:38.000000000 +0000
+++ tools/llvm-config/llvm-config.cpp
-@@ -327,9 +327,9 @@ int main(int argc, char **argv) {
+@@ -332,9 +332,9 @@ int main(int argc, char **argv) {
("-I" + ActiveIncludeDir + " " + "-I" + ActiveObjRoot + "/include");
} else {
ActivePrefix = CurrentExecPrefix;
@@ -15,10 +15,10 @@ on patch updates.
ActiveBinDir = ActivePrefix + "/bin";
- ActiveLibDir = ActivePrefix + "/lib" + LLVM_LIBDIR_SUFFIX;
+ ActiveLibDir = "@PREFIX@/lib/libLLVM";
+ ActiveCMakeDir = ActiveLibDir + "/cmake/llvm";
ActiveIncludeOption = "-I" + ActiveIncludeDir;
}
-
-@@ -363,14 +363,14 @@ int main(int argc, char **argv) {
+@@ -370,14 +370,14 @@ int main(int argc, char **argv) {
StaticDir = ActiveLibDir;
} else if (HostTriple.isOSDarwin()) {
SharedExt = "dylib";
@@ -35,7 +35,7 @@ on patch updates.
StaticExt = "a";
StaticDir = SharedDir = ActiveLibDir;
StaticPrefix = SharedPrefix = "lib";
-@@ -383,7 +383,7 @@ int main(int argc, char **argv) {
+@@ -390,7 +390,7 @@ int main(int argc, char **argv) {
bool DyLibExists = false;
const std::string DyLibName =
@@ -44,7 +44,7 @@ on patch updates.
// If LLVM_LINK_DYLIB is ON, the single shared library will be returned
// for "--libs", etc, if they exist. This behaviour can be overridden with
-@@ -474,7 +474,7 @@ int main(int argc, char **argv) {
+@@ -491,7 +491,7 @@ int main(int argc, char **argv) {
OS << ActiveIncludeOption << ' ' << LLVM_CXXFLAGS << '\n';
} else if (Arg == "--ldflags") {
OS << ((HostTriple.isWindowsMSVCEnvironment()) ? "-LIBPATH:" : "-L")
diff --git a/lang/libLLVM/patches/patch-tools_llvm-shlib_CMakeLists.txt b/lang/libLLVM/patches/patch-tools_llvm-shlib_CMakeLists.txt
index a5c8ce5c029..aa17cda1810 100644
--- a/lang/libLLVM/patches/patch-tools_llvm-shlib_CMakeLists.txt
+++ b/lang/libLLVM/patches/patch-tools_llvm-shlib_CMakeLists.txt
@@ -1,14 +1,14 @@
-$NetBSD: patch-tools_llvm-shlib_CMakeLists.txt,v 1.2 2017/03/09 12:45:56 jperkin Exp $
+$NetBSD: patch-tools_llvm-shlib_CMakeLists.txt,v 1.3 2017/03/17 22:38:18 adam Exp $
Use the Linux style linking everywhere except Darwin and SunOS.
--- tools/llvm-shlib/CMakeLists.txt.orig 2016-05-26 04:35:35.000000000 +0000
+++ tools/llvm-shlib/CMakeLists.txt
-@@ -39,11 +39,12 @@ endif()
+@@ -37,11 +37,12 @@ endif()
add_llvm_library(LLVM SHARED DISABLE_LLVM_LINK_LLVM_DYLIB SONAME ${SOURCES})
list(REMOVE_DUPLICATES LIB_NAMES)
--if("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux") # FIXME: It should be "GNU ld for elf"
+-if("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux" OR MINGW) # FIXME: It should be "GNU ld for elf"
- # GNU ld doesn't resolve symbols in the version script.
- set(LIB_NAMES -Wl,--whole-archive ${LIB_NAMES} -Wl,--no-whole-archive)
-elseif("${CMAKE_SYSTEM_NAME}" STREQUAL "Darwin")