summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--var/spack/repos/builtin/packages/intel-gtpin/package.py77
1 files changed, 77 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/intel-gtpin/package.py b/var/spack/repos/builtin/packages/intel-gtpin/package.py
new file mode 100644
index 0000000000..6b9ea61736
--- /dev/null
+++ b/var/spack/repos/builtin/packages/intel-gtpin/package.py
@@ -0,0 +1,77 @@
+# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack import *
+
+
+class IntelGtpin(Package):
+ """Intel(R) GtPin is a dynamic binary instrumentation framework for GEN
+ (Intel(R) graphics) Architecture. It is a unique SW platform for
+ profiling a code running on GEN Execution Units (EUs). GTPin
+ includes a binary instrumentation engine for Intel(R) GPUs EUs, along
+ with an API for developing analysis tools, and many sample
+ tools. GTPin allows you to capture a range of dynamic profiling
+ data at the finest granularity of the specific GPU EU instruction.
+ GTPin supports both compute and graphics workloads. It operates on
+ regular, real-world GPU applications, as well as on pre-captured
+ API streams. The technology enables fast and accurate dynamic
+ analysis of the code that is executing on the GPU EUs. GTPin opens
+ up new opportunities to perform dynamic, low level workload and HW
+ analysis on an Intel(R) GPU, with greater efficiency than other
+ current solutions. Some of the GTPin capabilities are integrated
+ into Intel(R) VTune(TM) Profiler, Intel(R) Advisor, and the Intel(R)
+ Graphics Performance Analyzers (Intel(R) GPA).
+
+ GTPin is available, along with a set of analysis tools based on
+ the GTPin framework. It also enables more advanced users to
+ develop their own analysis tools. GTPin can analyze any GPU
+ application. It also collects dynamic profiling data which the
+ application executes on the GPU.
+ """
+
+ homepage = "https://www.intel.com/content/www/us/en/developer/articles/tool/gtpin.html"
+ url = "https://downloadmirror.intel.com/686383/external-gtpin-2.19-linux.tar.xz"
+
+ maintainers = ['rashawnlk']
+
+ version('2.19', sha256='996cdfbcf7fbe736407d063e0ed1794e51bf31a72b50cf733a407af71118a304',
+ url='https://downloadmirror.intel.com/686383/external-gtpin-2.19-linux.tar.xz')
+
+ version('2.13', sha256='d715a55074147b73d51583bf684660b40f871e38e29af2bfc14dfe070fcbbada',
+ url='https://downloadmirror.intel.com/682776/external-gtpin-2.13-linux.tar.bz2')
+ version('2.12', sha256='432f1365bf4b3ff5847bb1059fb468ce6c7237ccd1489fbe8005f48e5a11e218',
+ url='https://downloadmirror.intel.com/682777/external-gtpin-2.12-linux.tar.bz2')
+ version('2.11.4', sha256='57f4d3aa67e8b7eb8a2456a4a770e60af770c599180cb2b6c3c8addd37311093',
+ url='https://downloadmirror.intel.com/682779/external-gtpin-2.11.4-linux.tar.bz2')
+
+ depends_on('patchelf', type='build')
+
+ # Gtpin only runs on linux/cray x86_64.
+ conflicts('platform=darwin', msg='intel-gtpin only runs on linux/cray')
+ conflicts('target=ppc64:', msg='intel-gtpin only runs on x86_64')
+ conflicts('target=ppc64le:', msg='intel-gtpin only runs on x86_64')
+ conflicts('target=aarch64:', msg='intel-gtpin only runs on x86_64')
+
+ # The gtbin tar file installs into Bin, Include, Lib directories.
+ @property
+ def command(self):
+ return Executable(self.prefix.Bin.gtpin)
+
+ @property
+ def headers(self):
+ return find_headers('gtpin', self.prefix.Include)
+
+ @property
+ def libs(self):
+ return find_libraries('libgtpin', self.prefix.Lib, recursive=True)
+
+ # The gtpin binary uses libraries from its own Lib directory but
+ # doesn't set rpath.
+ def install(self, spec, prefix):
+ patchelf = spec['patchelf'].command
+ patchelf('--set-rpath', join_path('$ORIGIN', '..', 'Lib', 'intel64'),
+ join_path('Bin', 'gtpin'))
+
+ install_tree('.', prefix)