[zorg] r335474 - Add a couple native arm builders to build armv7 and aarch64 clang.
Leandro Nunes via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 25 06:54:50 PDT 2018
Author: leandron
Date: Mon Jun 25 06:54:50 2018
New Revision: 335474
URL: http://llvm.org/viewvc/llvm-project?rev=335474&view=rev
Log:
Add a couple native arm builders to build armv7 and aarch64 clang.
- Generates clang tar.xz packages to be uploaded to Google Cloud
Storage and populate a build cache on a per-commit basis.
- Uses pixz to generate the packages quickly. (optional)
Modified:
zorg/trunk/buildbot/osuosl/master/config/builders.py
zorg/trunk/buildbot/osuosl/master/config/slaves.py
zorg/trunk/buildbot/osuosl/master/config/status.py
zorg/trunk/zorg/buildbot/builders/ClangBuilder.py
Modified: zorg/trunk/buildbot/osuosl/master/config/builders.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/buildbot/osuosl/master/config/builders.py?rev=335474&r1=335473&r2=335474&view=diff
==============================================================================
--- zorg/trunk/buildbot/osuosl/master/config/builders.py (original)
+++ zorg/trunk/buildbot/osuosl/master/config/builders.py Mon Jun 25 06:54:50 2018
@@ -762,6 +762,57 @@ def _get_clang_builders():
# '-GNinja',
# '-DLLVM_TARGETS_TO_BUILD=all',
# '-DLLVM_BINUTILS_INCDIR=/opt/binutils/include'])},
+
+ ## Armv7 build cache
+ {'name': "clang-armv7-linux-build-cache",
+ 'slavenames':["packet-linux-armv7-slave-1"],
+ 'builddir':"clang-armv7-linux-build-cache",
+ 'factory' : ClangBuilder.getClangCMakeGCSBuildFactory(
+ stage1_config='Release',
+ clean=True,
+ checkout_compiler_rt=False,
+ test=False,
+ useTwoStage=False,
+ runTestSuite=False,
+ checkout_lld=True,
+ checkout_libcxx=True,
+ checkout_clang_tools_extra=False,
+ use_pixz_compression=False,
+ xz_compression_factor=0,
+ #stage1_upload_directory='',
+ extra_cmake_args=[
+ "-DLLVM_TARGETS_TO_BUILD='ARM;AArch64;X86'",
+ "-DCMAKE_C_FLAGS='-mthumb'",
+ "-DCMAKE_CXX_FLAGS='-mthumb'",
+ ],
+ #env={'BUCKET': ''}
+ ),
+ 'category': 'clang'},
+
+ ## AArch64 build cache
+ {'name': "clang-aarch64-linux-build-cache",
+ 'slavenames':["packet-linux-aarch64-slave-1"],
+ 'builddir':"clang-aarch64-linux-build-cache",
+ 'factory' : ClangBuilder.getClangCMakeGCSBuildFactory(
+ stage1_config='Release',
+ clean=True,
+ checkout_compiler_rt=False,
+ test=False,
+ useTwoStage=False,
+ runTestSuite=False,
+ checkout_lld=True,
+ checkout_libcxx=True,
+ checkout_clang_tools_extra=False,
+ #stage1_upload_directory='',
+ use_pixz_compression=True,
+ extra_cmake_args=[
+ "-DLLVM_TARGETS_TO_BUILD='ARM;AArch64;X86'",
+ #"-DCMAKE_C_FLAGS=''",
+ #"-DCMAKE_CXX_FLAGS=''",
+ ],
+ #env={'BUCKET': ''}
+ ),
+ 'category': 'clang'},
]
# Polly builders.
Modified: zorg/trunk/buildbot/osuosl/master/config/slaves.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/buildbot/osuosl/master/config/slaves.py?rev=335474&r1=335473&r2=335474&view=diff
==============================================================================
--- zorg/trunk/buildbot/osuosl/master/config/slaves.py (original)
+++ zorg/trunk/buildbot/osuosl/master/config/slaves.py Mon Jun 25 06:54:50 2018
@@ -59,6 +59,13 @@ def get_build_slaves():
create_slave("linaro-armv8-01-aarch64-libcxx", properties={'jobs' : 1}, max_builds=1),
create_slave("linaro-armv8-01-aarch64-libcxx-noeh", properties={'jobs' : 1}, max_builds=1),
+ # ARMv7 build cache slave
+ create_slave("packet-linux-armv7-slave-1", properties={'jobs' : 64}, max_builds=1),
+
+ # AArch64 build cache slave
+ create_slave("packet-linux-aarch64-slave-1", properties={'jobs' : 64}, max_builds=1),
+
+
# AMD Athlon(tm) 64 X2 Dual Core 3800+, Ubuntu x86_64
create_slave("grosser1", properties={'jobs': 2}, max_builds=1),
Modified: zorg/trunk/buildbot/osuosl/master/config/status.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/buildbot/osuosl/master/config/status.py?rev=335474&r1=335473&r2=335474&view=diff
==============================================================================
--- zorg/trunk/buildbot/osuosl/master/config/status.py (original)
+++ zorg/trunk/buildbot/osuosl/master/config/status.py Mon Jun 25 06:54:50 2018
@@ -89,6 +89,15 @@ def get_status_targets(standard_builders
InformativeMailNotifier(
fromaddr = "llvm.buildmaster at lab.llvm.org",
sendToInterestedUsers= False,
+ extraRecipients = ["leandro.nunes at arm.com"],
+ subject="Build %(builder)s Failure",
+ mode = "failing",
+ builders = ["clang-aarch64-linux-build-cache", "clang-armv7-linux-build-cache"],
+ addLogs=False,
+ num_lines = 15),
+ InformativeMailNotifier(
+ fromaddr = "llvm.buildmaster at lab.llvm.org",
+ sendToInterestedUsers= False,
extraRecipients = ["gribozavr at gmail.com"],
subject="Build %(builder)s Failure",
mode = "failing",
Modified: zorg/trunk/zorg/buildbot/builders/ClangBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/ClangBuilder.py?rev=335474&r1=335473&r2=335474&view=diff
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/ClangBuilder.py (original)
+++ zorg/trunk/zorg/buildbot/builders/ClangBuilder.py Mon Jun 25 06:54:50 2018
@@ -396,7 +396,8 @@ def addSVNUpdateSteps(f,
workdir='llvm/projects/libunwind'))
def addGCSUploadSteps(f, package_name, install_prefix, gcs_directory, env,
- gcs_url_property=None):
+ gcs_url_property=None, use_pixz_compression=False,
+ xz_compression_factor=6):
"""
Add steps to upload to the Google Cloud Storage bucket.
@@ -414,6 +415,8 @@ def addGCSUploadSteps(f, package_name, i
gcs_url_fmt = ('gs://%(gcs_bucket)s/%(gcs_directory)s/'
'clang-r%(got_revision)s-t%(now)s-b%(buildnumber)s.tar.xz')
time_fmt = '%Y-%m-%d_%H-%M-%S'
+ output_file_name = '../install.tar.xz'
+
gcs_url = \
WithProperties(
gcs_url_fmt,
@@ -427,8 +430,15 @@ def addGCSUploadSteps(f, package_name, i
command=['echo', gcs_url],
property=gcs_url_property))
+ if use_pixz_compression:
+ # tweak the xz compression level to generate packages faster
+ tar_command = ['tar', '-Ipixz', '-cvf', output_file_name, '.']
+ else:
+ xz_command = 'xz -{0}'.format(xz_compression_factor)
+ tar_command = ['tar', '-I', xz_command, '-cvf', output_file_name, '.']
+
f.addStep(ShellCommand(name='package ' + package_name,
- command=['tar', 'cvfJ', '../install.tar.xz', '.'],
+ command=tar_command,
description='packaging ' + package_name + '...',
workdir=install_prefix,
env=env))
@@ -473,10 +483,16 @@ def getClangCMakeGCSBuildFactory(
checkout_clang_tools_extra=True,
checkout_compiler_rt=True,
checkout_lld=True,
+ checkout_libcxx=False,
# Upload artifacts to Google Cloud Storage (for the llvmbisect tool)
stage1_upload_directory=None,
+ # Use a lower compression level to generate the build-cache package faster.
+ # defuault is 6 according to xz documentation
+ xz_compression_factor=6,
+ use_pixz_compression=False,
+
# Triggers
trigger_after_stage1=[]):
return _getClangCMakeBuildFactory(
@@ -490,7 +506,10 @@ def getClangCMakeGCSBuildFactory(
checkout_clang_tools_extra=checkout_clang_tools_extra,
checkout_compiler_rt=checkout_compiler_rt,
checkout_lld=checkout_lld,
+ checkout_libcxx=checkout_libcxx,
stage1_upload_directory=stage1_upload_directory,
+ xz_compression_factor=xz_compression_factor,
+ use_pixz_compression=use_pixz_compression,
trigger_after_stage1=trigger_after_stage1)
def getClangCMakeBuildFactory(
@@ -579,6 +598,11 @@ def _getClangCMakeBuildFactory(
# Upload artifacts to Google Cloud Storage (for the llvmbisect tool)
stage1_upload_directory=None,
+ # Use a lower compression level to generate the build-cache package faster
+ # default is 6 according to documentation
+ xz_compression_factor=6,
+ use_pixz_compression=False,
+
# Triggers
trigger_after_stage1=[]):
@@ -681,7 +705,9 @@ def _getClangCMakeBuildFactory(
if stage1_upload_directory:
addGCSUploadSteps(f, 'stage 1', stage1_install, stage1_upload_directory,
- env, gcs_url_property='stage1_package_gcs_url')
+ env, gcs_url_property='stage1_package_gcs_url',
+ use_pixz_compression=use_pixz_compression,
+ xz_compression_factor=xz_compression_factor)
# Compute the cmake define flag to set the C and C++ compiler to clang. Use
# clang-cl if we used MSVC for stage1.
More information about the llvm-commits
mailing list