diff options
-rw-r--r-- | Android.mk | 6 | ||||
-rw-r--r-- | host/include/llvm/Config/config.h | 4 | ||||
-rw-r--r-- | include/llvm/Target/TargetOptions.h | 53 | ||||
-rw-r--r-- | lib/ExecutionEngine/Android.mk | 18 | ||||
-rw-r--r-- | lib/ExecutionEngine/MCJIT/Android.mk | 16 | ||||
-rw-r--r-- | lib/ExecutionEngine/RuntimeDyld/Android.mk | 18 | ||||
-rw-r--r-- | lib/MC/MCDisassembler/Android.mk | 15 | ||||
-rw-r--r-- | llvm.mk | 2 | ||||
-rw-r--r-- | shared_llvm.mk | 10 |
9 files changed, 137 insertions, 5 deletions
@@ -11,7 +11,10 @@ subdirs := \ lib/AsmParser \ lib/Bitcode/Reader \ lib/Bitcode/Writer \ + lib/ExecutionEngine \ + lib/ExecutionEngine/RuntimeDyld \ lib/ExecutionEngine/JIT \ + lib/ExecutionEngine/MCJIT \ lib/CodeGen \ lib/CodeGen/AsmPrinter \ lib/CodeGen/SelectionDAG \ @@ -19,6 +22,7 @@ subdirs := \ lib/IRReader \ lib/Linker \ lib/MC \ + lib/MC/MCDisassembler \ lib/MC/MCParser \ lib/Object \ lib/Option \ @@ -70,7 +74,7 @@ subdirs += tools/llvm-dis subdirs += tools/llvm-link #subdirs += tools/opt - include $(LOCAL_PATH)/llvm.mk include $(LOCAL_PATH)/shared_llvm.mk + include $(addprefix $(LOCAL_PATH)/,$(addsuffix /Android.mk, $(subdirs))) diff --git a/host/include/llvm/Config/config.h b/host/include/llvm/Config/config.h index bb93b37..c889158 100644 --- a/host/include/llvm/Config/config.h +++ b/host/include/llvm/Config/config.h @@ -679,13 +679,13 @@ #define PACKAGE_NAME "LLVM" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "LLVM 3.1svn" +#define PACKAGE_STRING "LLVM 3.3" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "llvm" /* Define to the version of this package. */ -#define PACKAGE_VERSION "3.1svn" +#define PACKAGE_VERSION "3.3" /* Define as the return type of signal handlers (`int' or `void'). */ #define RETSIGTYPE void diff --git a/include/llvm/Target/TargetOptions.h b/include/llvm/Target/TargetOptions.h index d9c8651..e77be0e 100644 --- a/include/llvm/Target/TargetOptions.h +++ b/include/llvm/Target/TargetOptions.h @@ -54,6 +54,59 @@ namespace llvm { FloatABIType(FloatABI::Default), AllowFPOpFusion(FPOpFusion::Standard) {} + TargetOptions(const TargetOptions& rhs) + : PrintMachineCode(rhs.PrintMachineCode), + NoFramePointerElim(rhs.NoFramePointerElim), + LessPreciseFPMADOption(rhs.LessPreciseFPMADOption), + UnsafeFPMath(rhs.UnsafeFPMath), + NoInfsFPMath(rhs.NoInfsFPMath), + NoNaNsFPMath(rhs.NoNaNsFPMath), + HonorSignDependentRoundingFPMathOption(rhs.HonorSignDependentRoundingFPMathOption), + UseSoftFloat(rhs.UseSoftFloat), + NoZerosInBSS(rhs.NoZerosInBSS), + JITEmitDebugInfo(rhs.JITEmitDebugInfo), + JITEmitDebugInfoToDisk(rhs.JITEmitDebugInfoToDisk), + GuaranteedTailCallOpt(rhs.GuaranteedTailCallOpt), + DisableTailCalls(rhs.DisableTailCalls), + StackAlignmentOverride(rhs.StackAlignmentOverride), + EnableFastISel(rhs.EnableFastISel), + PositionIndependentExecutable(rhs.PositionIndependentExecutable), + EnableSegmentedStacks(rhs.EnableSegmentedStacks), + UseInitArray(rhs.UseInitArray), + TrapFuncName(rhs.TrapFuncName), + FloatABIType(rhs.FloatABIType), + AllowFPOpFusion(rhs.AllowFPOpFusion) + {} + + TargetOptions& operator =(const TargetOptions& rhs) + { + if (&rhs == this) + return *this; + + PrintMachineCode = rhs.PrintMachineCode; + NoFramePointerElim = rhs.NoFramePointerElim; + LessPreciseFPMADOption = rhs.LessPreciseFPMADOption; + UnsafeFPMath = rhs.UnsafeFPMath; + NoInfsFPMath = rhs.NoInfsFPMath; + NoNaNsFPMath = rhs.NoNaNsFPMath; + HonorSignDependentRoundingFPMathOption = rhs.HonorSignDependentRoundingFPMathOption; + UseSoftFloat = rhs.UseSoftFloat; + NoZerosInBSS = rhs.NoZerosInBSS; + JITEmitDebugInfo = rhs.JITEmitDebugInfo; + JITEmitDebugInfoToDisk = rhs.JITEmitDebugInfoToDisk; + GuaranteedTailCallOpt = rhs.GuaranteedTailCallOpt; + DisableTailCalls = rhs.DisableTailCalls; + StackAlignmentOverride = rhs.StackAlignmentOverride; + EnableFastISel = rhs.EnableFastISel; + PositionIndependentExecutable = rhs.PositionIndependentExecutable; + EnableSegmentedStacks = rhs.EnableSegmentedStacks; + UseInitArray = rhs.UseInitArray; + TrapFuncName = rhs.TrapFuncName; + FloatABIType = rhs.FloatABIType; + AllowFPOpFusion = rhs.AllowFPOpFusion; + return *this; + } + /// PrintMachineCode - This flag is enabled when the -print-machineinstrs /// option is specified on the command line, and should enable debugging /// output from the code generator. diff --git a/lib/ExecutionEngine/Android.mk b/lib/ExecutionEngine/Android.mk new file mode 100644 index 0000000..9f1befd --- /dev/null +++ b/lib/ExecutionEngine/Android.mk @@ -0,0 +1,18 @@ +LOCAL_PATH:= $(call my-dir) + +# For the host +# ===================================================== +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := \ + ExecutionEngineBindings.cpp \ + ExecutionEngine.cpp \ + RTDyldMemoryManager.cpp \ + TargetSelect.cpp + +LOCAL_MODULE:= libLLVMExecutionEngine + +LOCAL_MODULE_TAGS := optional + +include $(LLVM_HOST_BUILD_MK) +include $(BUILD_HOST_STATIC_LIBRARY) diff --git a/lib/ExecutionEngine/MCJIT/Android.mk b/lib/ExecutionEngine/MCJIT/Android.mk new file mode 100644 index 0000000..0314958 --- /dev/null +++ b/lib/ExecutionEngine/MCJIT/Android.mk @@ -0,0 +1,16 @@ +LOCAL_PATH:= $(call my-dir) + +# For the host +# ===================================================== +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := \ + MCJIT.cpp \ + SectionMemoryManager.cpp + +LOCAL_MODULE:= libLLVMMCJIT + +LOCAL_MODULE_TAGS := optional + +include $(LLVM_HOST_BUILD_MK) +include $(BUILD_HOST_STATIC_LIBRARY) diff --git a/lib/ExecutionEngine/RuntimeDyld/Android.mk b/lib/ExecutionEngine/RuntimeDyld/Android.mk new file mode 100644 index 0000000..e98e80a --- /dev/null +++ b/lib/ExecutionEngine/RuntimeDyld/Android.mk @@ -0,0 +1,18 @@ +LOCAL_PATH:= $(call my-dir) + +# For the host +# ===================================================== +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := \ + GDBRegistrar.cpp \ + RuntimeDyld.cpp \ + RuntimeDyldELF.cpp \ + RuntimeDyldMachO.cpp + +LOCAL_MODULE:= libLLVMRuntimeDyld + +LOCAL_MODULE_TAGS := optional + +include $(LLVM_HOST_BUILD_MK) +include $(BUILD_HOST_STATIC_LIBRARY) diff --git a/lib/MC/MCDisassembler/Android.mk b/lib/MC/MCDisassembler/Android.mk new file mode 100644 index 0000000..7f73df3 --- /dev/null +++ b/lib/MC/MCDisassembler/Android.mk @@ -0,0 +1,15 @@ +LOCAL_PATH:= $(call my-dir) + +# For the host +# ===================================================== +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := \ + Disassembler.cpp + +LOCAL_MODULE:= libLLVMMCDisassembler + +LOCAL_MODULE_TAGS := optional + +include $(LLVM_HOST_BUILD_MK) +include $(BUILD_HOST_STATIC_LIBRARY) @@ -2,8 +2,6 @@ ifeq ($(LLVM_ROOT_PATH),) $(error Must set variable LLVM_ROOT_PATH before including this! $(LOCAL_PATH)) endif -TBLGEN := $(BUILD_OUT_EXECUTABLES)/tblgen$(BUILD_EXECUTABLE_SUFFIX) - CLEAR_TBLGEN_VARS := $(LLVM_ROOT_PATH)/clear_tblgen_vars.mk LLVM_HOST_BUILD_MK := $(LLVM_ROOT_PATH)/llvm-host-build.mk LLVM_DEVICE_BUILD_MK := $(LLVM_ROOT_PATH)/llvm-device-build.mk diff --git a/shared_llvm.mk b/shared_llvm.mk index 0a438a2..dd10a7d 100644 --- a/shared_llvm.mk +++ b/shared_llvm.mk @@ -56,6 +56,14 @@ llvm_post_static_libraries := \ libLLVMSupport \ libLLVMVectorize +llvm_host_static_libraries := \ + libLLVMExecutionEngine \ + libLLVMMCDisassembler \ + libLLVMRuntimeDyld \ + libLLVMJIT \ + libLLVMMCJIT + +ifeq (true,$(FORCE_BUILD_LLVM_COMPONENTS)) # HOST LLVM shared library build include $(CLEAR_VARS) LOCAL_IS_HOST_MODULE := true @@ -70,6 +78,7 @@ LOCAL_WHOLE_STATIC_LIBRARIES := \ $(llvm_arm_static_libraries) \ $(llvm_x86_static_libraries) \ $(llvm_mips_static_libraries) \ + $(llvm_host_static_libraries) \ $(llvm_post_static_libraries) ifeq ($(HOST_OS),windows) @@ -80,6 +89,7 @@ endif include $(LLVM_HOST_BUILD_MK) include $(BUILD_HOST_SHARED_LIBRARY) +endif #TODOArm64: Enable llvm build ifneq ($(TARGET_ARCH),arm64) |