Android-x86
Fork
Donation

  • R/O
  • HTTP
  • SSH
  • HTTPS

external-llvm: List of commits

external/llvm


RSS
Rev. Tiempo Autor
b36b39f pie-x86 q-x86 android-x86-9.0-r2 2019-12-29 23:05:42 Mauro Rossi

android: add 'Restat: true' to tblgenRule definition (llvm90)

Based on suggestion by Colin Cross, to avoid unnecessary rebuild of llvm90
in case of *.inc generated sources older than llvm90-tblgen binary.

When llvm90-tblgen binary is compiled and for some reason the build is interrupted,
the generated *.inc files will have a timestamp older than llvm90-tblgen binary,
at this point all libLLVM* targets depending on the *.inc files are always rebuilt.

'NINJA_ARGS="-d explain" make iso_img' command revealed the cause of the problem:

ninja explain: output out/soong/.intermediates/external/llvm90/llvm90-gen-attributes/gen/llvm/IR/Attributes.inc
older than most recent input out/soong/host/linux-x86/bin/llvm90-tblgen (1570914978 vs 1575285173)
ninja explain: out/soong/.intermediates/external/llvm90/llvm90-gen-attributes/gen/llvm/IR/Attributes.inc is dirty

Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>

13984ba 2019-10-05 21:36:03 Chih-Wei Huang

android: add CleanSpec.mk (llvm90)

Clean up older objects to rebuild everything.

3cd3c17 2019-10-05 16:11:39 Mauro Rossi

DO NOT MERGE: android: translate soong build rules for libLLVM90

These changes are applied to build external/llvm90 project
and avoid conflicts with external/llvm project
Changes in mesa main Android.mk are required for libLLVM90
shared library dependency and cflag -DHAVE_LLVM=0x0900

The changelog is described by means of modules and variables
which needed to be renamed:

#rename the target shared library and all static libraries
find . -type f -name "*.bp" -exec sed -i 's/libLLVM/libLLVM90/g' {} +

#rename the boostrap and contextual build paths
find . -type f -name "*.bp" -exec sed -i 's/soong\-llvm/\soong-llvm90/g' {} +
find . -type f -name "*.go" -exec sed -i 's/android\/soong\/llvm/android\/soong\/llvm90/g' {} +

#rename force_build_llvm_components type and module name
find . -type f -name '*.bp' -exec sed -i 's/force_build_llvm_components/force_build_llvm90_components/g' {} +
find . -type f -name '*.go' -exec sed -i 's/force_build_llvm_components/force_build_llvm90_components/g' {} +

#rename all module that gave 'already defined' error
find . -type f -name '*.bp' -exec sed -i 's/llvm-aarch64-defaults/llvm90-aarch64-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-aarch64-headers/llvm90-aarch64-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-amdgpu-defaults/llvm90-amdgpu-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-amdgpu-headers/llvm90-amdgpu-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-arm-defaults/llvm90-arm-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-arm-headers/llvm90-arm-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-defaults/llvm90-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-defaults-no-generated-headers/llvm90-defaults-no-generated-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-aarch64/llvm90-gen-aarch64/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-amdgpu/llvm90-gen-amdgpu/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-r600/llvm90-gen-r600/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-arm/llvm90-gen-arm/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-attributes/llvm90-gen-attributes/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-core/llvm90-gen-core/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-intrinsics/llvm90-gen-intrinsics/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-libdriver/llvm90-gen-libdriver/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-mips/llvm90-gen-mips/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-revision/llvm90-gen-revision/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-x86/llvm90-gen-x86/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-headers/llvm90-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-headers-no-generated-headers/llvm90-headers-no-generated-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-lib-defaults/llvm90-lib-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-mips-defaults/llvm90-mips-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-mips-headers/llvm90-mips-headers/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-tblgen/llvm90-tblgen/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-x86-defaults/llvm90-x86-defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm-x86-headers/llvm90-x86-headers/g' {} +

#rename llvm-gen-instcombine module
find . -type f -name '*.bp' -exec sed -i 's/llvm-gen-instcombine/llvm90-gen-instcombine/g' {} +

#rename the binaries
find . -type f -name '*.bp' -exec sed -i 's/LLVMHello/LLVM90Hello/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/LLVMgold/LLVM90gold/g' {} +

#rename the TableGen binary module and variable in different files
find . -type f -name '*.go' -exec sed -i 's/LLVM TableGen/LLVM90 TableGen/g' {} +
find . -type f -name '*.go' -exec sed -i 's/llvm-tblgen/llvm90-tblgen/g' {} +
find . -type f -name '*.go' -exec sed -i 's/llvmTblgen/llvm90Tblgen/g' {} +
find . -type f -name '*.go' -exec sed -i 's/tblgenRule/tblgenRule90/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/llvm_tblgen/llvm90_tblgen/g' {} +
find . -type f -name '*.go' -exec sed -i 's/llvm_tblgen/llvm90_tblgen/g' {} +
find . -type f -name 'tdtags' -exec sed -i 's/llvm-tblgen/llvm90-tblgen/g' {} +

#rename the include paths
find . -type f -name '*.bp' -exec sed -i 's/external\/llvm/external\/llvm90/g' {} +
find . -type f -name '*.go' -exec sed -i 's/external\/llvm/external\/llvm90/g' {} +

#rename package, registered types and llvm-config
find . -type f -name '*.go' -exec sed -i 's/package llvm/package llvm90/g' {} +
find . -type f -name '*.go' -exec sed -i 's/llvm_tblgen/llvm90_tblgen/g' {} +
find . -type f -name '*.go' -exec sed -i 's/llvm_defaults/llvm90_defaults/g' {} +
find . -type f -name '*.bp' -exec sed -i 's/ llvm-config / llvm90-config /g' {} +
find . -type f -name '*.bp' -exec sed -i 's/"llvm-config"/"llvm90-config"/g' {} +
find . -type f -name '*.go' -exec sed -i 's/"llvm-config"/"llvm90-config"/g' {} +

2ccdff5 2019-10-05 16:10:16 Mauro Rossi

android: update version in {config,llvm-config}.h headers

Version information is set to 9.0.0

b5e3785 2019-10-05 16:09:52 Mauro Rossi

android: Bitstream: add support for libLLVMBitstreamReader

To avoid following building errors:

external/llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp:570: error: undefined reference to 'llvm::BitstreamCursor::ReadBlockInfoBlock(bool)'
external/llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp:747: error: undefined reference to 'llvm::BitstreamCursor::EnterSubBlock(unsigned int, unsigned int*)'
...
external/llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp:974: error: undefined reference to 'llvm::BitstreamCursor::skipRecord(unsigned int)'
external/llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp:819: error: undefined reference to 'llvm::BitstreamCursor::ReadAbbrevRecord()'
external/llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp:831: error: undefined reference to 'llvm::BitstreamCursor::readRecord(unsigned int, llvm::SmallVectorImpl<unsigned long long>&, llvm::StringRef*)'
...
external/llvm/lib/Bitcode/Reader/BitcodeReader.cpp:6402: error: undefined reference to 'llvm::BitstreamCursor::skipRecord(unsigned int)'
external/llvm/lib/Bitcode/Reader/BitcodeReader.cpp:6252: error: undefined reference to 'llvm::BitstreamCursor::EnterSubBlock(unsigned int, unsigned int*)'
external/llvm/lib/Bitcode/Reader/BitcodeReader.cpp:6278: error: undefined reference to 'llvm::BitstreamCursor::readRecord(unsigned int, llvm::SmallVectorImpl<unsigned long long>&, llvm::StringRef*)'
...
external/llvm/lib/Bitcode/Reader/BitcodeReader.cpp:3041: error: undefined reference to 'llvm::BitstreamCursor::ReadBlockInfoBlock(bool)'
clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation)

3c20a30 2019-10-05 04:09:49 Mauro Rossi

android: Coroutines: add support for libLLVMCoroutines

Fixes the following building error with mesa 19.3 branch:

FAILED: out/target/product/x86_64/obj/SHARED_LIBRARIES/gallium_dri_intermediates/LINKED/gallium_dri.so
...
external/mesa/src/gallium/auxiliary/gallivm/lp_bld_init.c:137: error: undefined reference to 'LLVMAddCoroEarlyPass'
external/mesa/src/gallium/auxiliary/gallivm/lp_bld_init.c:138: error: undefined reference to 'LLVMAddCoroSplitPass'
external/mesa/src/gallium/auxiliary/gallivm/lp_bld_init.c:139: error: undefined reference to 'LLVMAddCoroElidePass'
external/mesa/src/gallium/auxiliary/gallivm/lp_bld_init.c:169: error: undefined reference to 'LLVMAddCoroCleanupPass'
clang.real: error: linker command failed with exit code 1 (use -v to see invocation)

f5bec1c 2019-09-22 21:36:30 Mauro Rossi

android: AMDGPU: add support for Disassembler target

Necessary for the new Valve ACO compiler in mesa 19.3

LLVMInitializeAMDGPUDisassembler() function exposed conditionally
to FORCE_BUILD_AMDGPU macro definition in mesa src/amd/Android.compiler.mk
as per other AMDGPU targets

Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>

22cc92c 2019-09-22 21:35:55 Mauro Rossi

Android: Fix soong building rules for llvm 9.0

The necessary static dependencies are added for Android blueprint build.

Changelog:
Build libLLVMJITLink static by adding lib/ExecutionEngine/JITLink/Android.bp
Build libLLVMRemarks static by adding lib/Remarks/Android.bp
Add libLLVMMIRParser, libLLVMJITLink and libLLVMRemarks dependencies in ./Android.bp

Fixes the following building errors at linking:

FAILED: out/soong/.intermediates/external/llvm/libLLVM/android_x86_core_shared/libLLVM.so
...
external/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp:1005: error: undefined reference to 'llvm::parseNamedRegisterReference(llvm::PerFunctionMIParsingState&, unsigned int&, llvm::StringRef, llvm::SMDiagnostic&)'
external/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp:1005: error: undefined reference to 'llvm::parseNamedRegisterReference(llvm::PerFunctionMIParsingState&, unsigned int&, llvm::StringRef, llvm::SMDiagnostic&)'
external/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp:1005: error: undefined reference to 'llvm::parseNamedRegisterReference(llvm::PerFunctionMIParsingState&, unsigned int&, llvm::StringRef, llvm::SMDiagnostic&)'
external/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp:1005: error: undefined reference to 'llvm::parseNamedRegisterReference(llvm::PerFunctionMIParsingState&, unsigned int&, llvm::StringRef, llvm::SMDiagnostic&)'
...
external/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp:1371: error: undefined reference to 'llvm::remarks::StringTable::serialize() const'
external/llvm/lib/IR/DiagnosticInfo.cpp:435: error: undefined reference to 'llvm::remarks::StringTable::add(llvm::StringRef)'
external/llvm/lib/IR/DiagnosticInfo.cpp:436: error: undefined reference to 'llvm::remarks::StringTable::add(llvm::StringRef)'
external/llvm/lib/IR/DiagnosticInfo.cpp:437: error: undefined reference to 'llvm::remarks::StringTable::add(llvm::StringRef)'
external/llvm/lib/IR/DiagnosticInfo.cpp:457: error: undefined reference to 'llvm::remarks::StringTable::add(llvm::StringRef)'
...
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:337: error: undefined reference to 'llvm::jitlink::jitLink(std::__1::unique_ptr<llvm::jitlink::JITLinkContext, std::__1::default_delete<llvm::jitlink::JITLinkContext> >)'
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:422: error: undefined reference to 'llvm::jitlink::createEHFrameRecorderPass(llvm::Triple const&, std::__1::function<void (unsigned long long)>)'
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:444: error: undefined reference to 'llvm::jitlink::registerEHFrameSection(void const*)'
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:457: error: undefined reference to 'llvm::jitlink::deregisterEHFrameSection(void const*)'
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:476: error: undefined reference to 'llvm::jitlink::deregisterEHFrameSection(void const*)'
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:25: error: undefined reference to 'llvm::jitlink::JITLinkContext::~JITLinkContext()'
external/llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp:25: error: undefined reference to 'llvm::jitlink::JITLinkContext::~JITLinkContext()'
out/soong/.intermediates/external/llvm/lib/ExecutionEngine/Orc/libLLVMOrcJIT/android_x86_core_static/libLLVMOrcJIT.a(ObjectLinkingLayer.o):ObjectLinkingLayer.cpp:vtable for llvm::orc::ObjectLinkingLayerJITLinkContext: error: undefined reference to 'llvm::jitlink::JITLinkContext::shouldAddDefaultTargetPasses(llvm::Triple const&) const'
clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation)

Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>

3ffa488 2019-09-22 21:35:54 Dan Willemsen

Add SourceFileGenerator.GeneratedDeps()

To clean up unnecessary dependencies when using generated headers,
GeneratedDeps() should return a single file from every build entry.
GeneratedSourceFiles() used to be used from this, but now if you create
one build rule with multiple outputs, it's valid to only return a single
output file.

In this case, ModuleBuild is called once per source file, each
outputing a single output file, so all of them still need to be listed.

Bug: 73745773
Test: diff out/soong/build.ninja
Test: diff out/soong/Android-aosp_arm.mk
Test: rm -rf out; m
Change-Id: I073e3be7ecd9545f4002ad94d3da44f1a6652baa

c510447 2019-09-22 21:35:53 Mauro Rossi

android: utils: remove redundant Android.bp

To avoid build errors with pie-x86

Implemented via following commands:

rm utils/count/Android.bp
rm utils/FileCheck/Android.bp
rm utils/yaml-bench/Android.bp
rm utils/not/Android.bp

a898d95 2019-09-22 21:35:53 Mauro Rossi

android: tools: remove redundant Android.bp

To avoid build errors in pie-x86 due to collision with external/llvm ones

Implemented via following commands:

cd tools
find . -type f -name 'Android.bp' -exec rm {} +

b46f11e 2019-09-22 21:35:52 Mauro Rossi

android: config.h: Add option to disable minidumps, default it to off

Porting of commit
7e4b0fae ("Add cmake option to disable minidumps, default it to off")

plus some other options that are to be set on (1) or off (0)

Fixes the following building error:

external/llvm80/lib/Support/Process.cpp:88:35:
error: use of undeclared identifier 'LLVM_ENABLE_CRASH_DUMPS'
static bool coreFilesPrevented = !LLVM_ENABLE_CRASH_DUMPS;
^
1 error generated.

9507f4b 2019-09-22 21:35:52 Mauro Rossi

android: update version in {config,llvm-config}.h headers

Version information is set to 8.0.0

c522e0f 2019-09-22 21:35:51 Chih-Wei Huang

Android: fix a possible building error

The .git/logs/HEAD doesn't always exist. In a new created repo, it may
cause the error:

error: external/llvm/Android.bp:157:1: module "llvm-gen-revision": source path external/llvm/.git/logs/HEAD does not exist

Use wildcard to avoid that.

8b407b6 2019-09-22 21:35:51 Mauro Rossi

android: Support: add genrule for VCSRevision.h header

Cmake build generates the header, in Android blueprint we need to add
a new "llvm-gen-revision" genrule to launch command script that will
generate "llvm/Support/VCSRevision.h" header.
For simplification the new genrule is added to "llvm-headers" library
which is already used to generate attributes and intrinsics headers.
Mesa python script git_sha1_gen.py is added to external/llvm top path,
with the only changes being the relative git_dir path at line 16 that
is changed from '..' to '.' and the content of generated header.

eabeddf 2019-09-22 21:35:50 Mauro Rossi

android: AMDGPU: Make getTgtMemIntrinsic table-driven for resource-based intrinsics

Reference:
e821893513
("AMDGPU: Make getTgtMemIntrinsic table-driven for resource-based intrinsics")

7c44ad2 2019-09-22 21:35:49 Mauro Rossi

android: Add a Microsoft Demangler.

Reference: 42e40ea33e ("Add a Microsoft Demangler.")

f1c4704 2019-09-22 21:35:49 Mauro Rossi

android: [InstCombine] Introducing Aggressive Instruction Combine pass

Reference:
594d89a614
[InstCombine] Introducing Aggressive Instruction Combine pass (-aggressive-instcombine).

22bedd6 2019-09-22 21:35:48 Mauro Rossi

android: InstCombine: add support for InstCombineTable.inc TableGen rules

Reference:
commit 7f7cea5306
("InstCombine/AMDGPU: Add dimension-aware image intrinsics to SimplifyDemanded")

327f065 2019-09-22 21:35:48 Mauro Rossi

android: AMDGPU: Separate R600 and GCN TableGen files

Reference:
cba2181e77 ("AMDGPU: Separate R600 and GCN TableGen files")

272cfe0 2019-09-22 21:35:47 Mauro Rossi

android: [IR] Split Intrinsics.inc into enums and implementations

Reference:
af7c445 ("[IR] Split Intrinsics.inc into enums and implementations")

ca7dc82 2019-09-22 21:35:46 Mauro Rossi

android: Rename {Attributes,Intrinsics}.gen to {Attributes,Intrinsics}.inc

Reference:
ea0775ec4a ("Rename Attributes.gen, Intrinsics.gen to Attributes.inc, Intrinsics.inc")

c50f8ed 2019-09-22 21:35:46 Mauro Rossi

android: [ARM] Unify handling of M-Class system registers

Reference:
683224ecbd ("[ARM] Unify handling of M-Class system registers")

89df43a 2019-09-22 21:35:45 Mauro Rossi

android: [mips][rtdyld] Move MIPS relocation resolution to a subclass

Reference: 2762dbad70
"[mips][rtdyld] Move MIPS relocation resolution to a subclass and implment N32 relocations"

59c9f3d 2019-09-22 21:35:45 Mauro Rossi

android: [PM] Create a separate library for high-level pass management code.

Reference:
2349136630 ("[PM] Create a separate library for high-level pass management code.")

2235966 2019-09-22 21:35:44 Mauro Rossi

android: [MSF] add support for libLLVMDebugInfoMSF

Reference:
5e117855c3 ([msf] Resubmit "Rename Msf -> MSF".)

d3a682a 2019-09-22 21:35:43 Mauro Rossi

android: NFC: Rename (PDB) RawSession to NativeSession

Reference:
11e1d83ce5 ("NFC: Rename (PDB) RawSession to NativeSession")

37126f4 2019-09-22 21:35:43 Mauro Rossi

android: Move Object format code to lib/BinaryFormat.

Reference:
19ca2b0f9d ("Move Object format code to lib/BinaryFormat.")

7491d6f 2019-09-22 21:35:42 Mauro Rossi

android: [X86][GlobalISel] Initial implementation , select G_ADD gpr, gpr

Reference:
8ae3570fa804
("[X86][GlobalISel] Initial implementation , select G_ADD gpr, gpr")

f61644f 2019-09-22 21:35:42 Mauro Rossi

android: [X86][AVX512] Adding new LLVM TableGen for EVEX2VEX tables

Reference:
b59d8041db [X86][AVX512] Adding new LLVM TableGen backend which
generates the EVEX2VEX compressing tables.

Show on old repository browser