taucmdr 1.7.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- taucmdr-1.7.0/.dockerignore +12 -0
- taucmdr-1.7.0/.testfiles/blockmatrix-coarray.f90 +83 -0
- taucmdr-1.7.0/.testfiles/firstprime.py +23 -0
- taucmdr-1.7.0/.testfiles/foo_launcher +17 -0
- taucmdr-1.7.0/.testfiles/hello.c +7 -0
- taucmdr-1.7.0/.testfiles/io.c +23 -0
- taucmdr-1.7.0/.testfiles/jacobi.c +85 -0
- taucmdr-1.7.0/.testfiles/matmult.c +313 -0
- taucmdr-1.7.0/.testfiles/mpi_hello.c +18 -0
- taucmdr-1.7.0/.testfiles/storage/v1.6.0/README +2 -0
- taucmdr-1.7.0/.testfiles/storage/v1.6.0/sqlite/project/.tau/project.sqlite3 +0 -0
- taucmdr-1.7.0/.testfiles/storage/v1.6.0/sqlite/user/user.sqlite3 +0 -0
- taucmdr-1.7.0/.testfiles/storage/v1.6.0/tinydb/project/.tau/project.json +1 -0
- taucmdr-1.7.0/.testfiles/storage/v1.6.0/tinydb/user/user.json +1 -0
- taucmdr-1.7.0/.testfiles/timer.h +67 -0
- taucmdr-1.7.0/Dockerfile +31 -0
- taucmdr-1.7.0/LICENSE +24 -0
- taucmdr-1.7.0/Makefile +72 -0
- taucmdr-1.7.0/PKG-INFO +115 -0
- taucmdr-1.7.0/README.md +87 -0
- taucmdr-1.7.0/docs/_ext/cli_reference.py +168 -0
- taucmdr-1.7.0/docs/_static/.gitkeep +0 -0
- taucmdr-1.7.0/docs/_static/favicon.ico +0 -0
- taucmdr-1.7.0/docs/_static/tau.cf.compiler.png +0 -0
- taucmdr-1.7.0/docs/_static/taucmdr.png +0 -0
- taucmdr-1.7.0/docs/_static/taulogo-large.png +0 -0
- taucmdr-1.7.0/docs/conf.py +413 -0
- taucmdr-1.7.0/docs/continuous_integration.rst +58 -0
- taucmdr-1.7.0/docs/design.rst +94 -0
- taucmdr-1.7.0/docs/documentation.rst +553 -0
- taucmdr-1.7.0/docs/index.rst +82 -0
- taucmdr-1.7.0/docs/install.rst +175 -0
- taucmdr-1.7.0/docs/new_compiler.rst +150 -0
- taucmdr-1.7.0/docs/new_feature.rst +31 -0
- taucmdr-1.7.0/docs/packaging.rst +135 -0
- taucmdr-1.7.0/docs/pre-commit-hooks.rst +47 -0
- taucmdr-1.7.0/docs/style.rst +1676 -0
- taucmdr-1.7.0/docs/unit_tests.rst +80 -0
- taucmdr-1.7.0/examples/matmult_omp/Makefile +26 -0
- taucmdr-1.7.0/examples/matmult_omp/matmult.f90 +155 -0
- taucmdr-1.7.0/examples/memory/Makefile +26 -0
- taucmdr-1.7.0/examples/memory/README +23 -0
- taucmdr-1.7.0/examples/memory/simple.cpp +24 -0
- taucmdr-1.7.0/examples/memoryleakdetect/c/Makefile +10 -0
- taucmdr-1.7.0/examples/memoryleakdetect/c/simple.c +54 -0
- taucmdr-1.7.0/examples/memoryleakdetect/f90/Makefile +8 -0
- taucmdr-1.7.0/examples/memoryleakdetect/f90/foo.f90 +27 -0
- taucmdr-1.7.0/examples/memoryleakdetect/f90/select.tau +4 -0
- taucmdr-1.7.0/examples/memoryleakdetect/mpi/Makefile +8 -0
- taucmdr-1.7.0/examples/memoryleakdetect/mpi/README +8 -0
- taucmdr-1.7.0/examples/memoryleakdetect/mpi/matrix.f90 +149 -0
- taucmdr-1.7.0/examples/memoryleakdetect/mpi/select.tau +4 -0
- taucmdr-1.7.0/examples/mm/Makefile +43 -0
- taucmdr-1.7.0/examples/mm/Makefile.intel +44 -0
- taucmdr-1.7.0/examples/mm/README.stampede +7 -0
- taucmdr-1.7.0/examples/mm/matmult.c +299 -0
- taucmdr-1.7.0/examples/mm/matmult_initialize.c +16 -0
- taucmdr-1.7.0/examples/mm/matmult_initialize.h +14 -0
- taucmdr-1.7.0/examples/mpi_mpmd/Makefile +60 -0
- taucmdr-1.7.0/examples/mpi_mpmd/logging.c +12 -0
- taucmdr-1.7.0/examples/mpi_mpmd/logging.h +11 -0
- taucmdr-1.7.0/examples/mpi_mpmd/master.c +15 -0
- taucmdr-1.7.0/examples/mpi_mpmd/mpmd.conf +12 -0
- taucmdr-1.7.0/examples/mpi_mpmd/worker.c +30 -0
- taucmdr-1.7.0/examples/notebooks/importing2widgets.ipynb +416 -0
- taucmdr-1.7.0/examples/opencl/Makefile +16 -0
- taucmdr-1.7.0/examples/opencl/matmult.cpp +355 -0
- taucmdr-1.7.0/examples/pi/Makefile +14 -0
- taucmdr-1.7.0/examples/pi/README +5 -0
- taucmdr-1.7.0/examples/pi/ex.file +4 -0
- taucmdr-1.7.0/examples/pi/serialPi.cpp +64 -0
- taucmdr-1.7.0/examples/posixio/Makefile +25 -0
- taucmdr-1.7.0/examples/posixio/posixio.c +36 -0
- taucmdr-1.7.0/examples/python/firstprime.py +23 -0
- taucmdr-1.7.0/examples/sc15/f90-mpi/Makefile +24 -0
- taucmdr-1.7.0/examples/sc15/f90-mpi/matmult.f90 +132 -0
- taucmdr-1.7.0/examples/sc15/mpi/Makefile +27 -0
- taucmdr-1.7.0/examples/sc15/mpi/matmult.c +111 -0
- taucmdr-1.7.0/examples/sc15/mpi/matmult_initialize.c +14 -0
- taucmdr-1.7.0/examples/sc15/mpi/matmult_initialize.h +14 -0
- taucmdr-1.7.0/examples/sc15/mpi-openmp/Makefile +27 -0
- taucmdr-1.7.0/examples/sc15/mpi-openmp/matmult.c +117 -0
- taucmdr-1.7.0/examples/sc15/mpi-openmp/matmult_initialize.c +16 -0
- taucmdr-1.7.0/examples/sc15/mpi-openmp/matmult_initialize.h +14 -0
- taucmdr-1.7.0/examples/sc15/openmp/Makefile +27 -0
- taucmdr-1.7.0/examples/sc15/openmp/matmult.c +103 -0
- taucmdr-1.7.0/examples/sc15/openmp/matmult_initialize.c +16 -0
- taucmdr-1.7.0/examples/sc15/openmp/matmult_initialize.h +14 -0
- taucmdr-1.7.0/examples/sc15/serial/Makefile +27 -0
- taucmdr-1.7.0/examples/sc15/serial/matmult.c +97 -0
- taucmdr-1.7.0/examples/sc15/serial/matmult_initialize.c +12 -0
- taucmdr-1.7.0/examples/sc15/serial/matmult_initialize.h +14 -0
- taucmdr-1.7.0/examples/shmem/c/Makefile +8 -0
- taucmdr-1.7.0/examples/shmem/c/simple.c +23 -0
- taucmdr-1.7.0/examples/shmem/f90/Makefile +8 -0
- taucmdr-1.7.0/examples/shmem/f90/simple.f90 +19 -0
- taucmdr-1.7.0/examples/shmem/openshmem_f90/Makefile +8 -0
- taucmdr-1.7.0/examples/shmem/openshmem_f90/license.txt +42 -0
- taucmdr-1.7.0/examples/shmem/openshmem_f90/rotput.f90 +38 -0
- taucmdr-1.7.0/examples/timerOverhead/Makefile +30 -0
- taucmdr-1.7.0/examples/timerOverhead/testOverhead.f90 +16 -0
- taucmdr-1.7.0/mypy.ini +18 -0
- taucmdr-1.7.0/packages/taucmdr/LICENSE +24 -0
- taucmdr-1.7.0/packages/taucmdr/__init__.py +153 -0
- taucmdr-1.7.0/packages/taucmdr/__main__.py +70 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/__init__.py +31 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/LICENCE +7 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/README.rst +244 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/__init__.py +28 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/database.py +543 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/middlewares.py +123 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/migrate.py +66 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/operations.py +28 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/queries.py +616 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/storages.py +129 -0
- taucmdr-1.7.0/packages/taucmdr/_vendor/tinydb/utils.py +114 -0
- taucmdr-1.7.0/packages/taucmdr/cf/__init__.py +27 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/__init__.py +904 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/caf.py +40 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/cuda.py +46 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/host.py +81 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/mpi.py +81 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/python.py +42 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/shmem.py +57 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/tests/test_host.py +143 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/tests/test_installed.py +65 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/tests/test_mpi.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/tests/test_python.py +69 -0
- taucmdr-1.7.0/packages/taucmdr/cf/compiler/tests/test_shmem.py +84 -0
- taucmdr-1.7.0/packages/taucmdr/cf/objects.py +188 -0
- taucmdr-1.7.0/packages/taucmdr/cf/platforms.py +241 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/__init__.py +79 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/binutils_installation.py +145 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/gotcha_installation.py +61 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/installation.py +641 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/libdwarf_installation.py +60 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/libelf_installation.py +65 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/libotf2_installation.py +51 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/libunwind_installation.py +104 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/ompt_installation.py +69 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/papi_installation.py +188 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/pdt_installation.py +206 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/scorep_installation.py +216 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/sqlite3_installation.py +54 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tau_installation.py +2127 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_binutils_installation.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_installation.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_libdwarf_installation.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_libelf_installation.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_libunwind_installation.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_papi_installation.py +82 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_pdt_installation.py +62 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_scorep_installation.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_sources.py +79 -0
- taucmdr-1.7.0/packages/taucmdr/cf/software/tests/test_tau_installation.py +642 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/__init__.py +364 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/levels.py +146 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/local_file.py +578 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/project.py +164 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/sqlite3_file.py +736 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/sqlite3_project.py +144 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/storage_dispatch.py +401 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_levels.py +247 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_local_file.py +59 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_old_databases.py +83 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_project.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_sqlite3_file.py +331 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_sqlite3_project.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/cf/storage/tests/test_storage_dispatch.py +344 -0
- taucmdr-1.7.0/packages/taucmdr/cf/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cf/tests/test_platforms.py +170 -0
- taucmdr-1.7.0/packages/taucmdr/cli/__init__.py +315 -0
- taucmdr-1.7.0/packages/taucmdr/cli/arguments.py +553 -0
- taucmdr-1.7.0/packages/taucmdr/cli/cli_view.py +605 -0
- taucmdr-1.7.0/packages/taucmdr/cli/command.py +118 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/__main__.py +167 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/__init__.py +72 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/copy.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/create.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/delete.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/edit.py +54 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/list.py +44 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/tests/test_create.py +60 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/tests/test_delete.py +50 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/tests/test_edit.py +64 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/application/tests/test_list.py +49 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/build.py +94 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/dashboard.py +76 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/__init__.py +58 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/create.py +84 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/delete.py +34 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/edit.py +66 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/list.py +86 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/select.py +56 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/tests/test_create.py +135 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/tests/test_delete.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/tests/test_edit.py +101 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/tests/test_list.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/experiment/tests/test_select.py +73 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/help.py +184 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/initialize.py +274 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/__init__.py +76 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/copy.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/create.py +56 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/delete.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/edit.py +109 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/list.py +44 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/tests/test_copy.py +65 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/tests/test_create.py +123 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/tests/test_delete.py +69 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/tests/test_edit.py +196 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/measurement/tests/test_list.py +52 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/__init__.py +50 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/copy.py +127 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/create.py +147 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/delete.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/edit.py +199 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/list.py +107 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/select.py +56 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/test_copy.py +69 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/test_create.py +60 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/test_delete.py +51 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/test_edit.py +68 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/test_export.py +38 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/project/tests/test_list.py +49 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/rewrite.py +76 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/select.py +183 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/__init__.py +76 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/configure.py +265 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/fetch.py +121 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/import.py +154 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/tests/test_configure.py +179 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/tests/test_fetch.py +117 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/system/tests/test_import.py +200 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/__init__.py +64 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/copy.py +124 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/create.py +331 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/delete.py +33 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/edit.py +145 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/list.py +57 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/metrics.py +111 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/tests/test_copy.py +145 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/tests/test_create.py +196 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/tests/test_delete.py +51 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/tests/test_edit.py +136 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/target/tests/test_list.py +55 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/tests/test_build.py +59 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/tests/test_dashboard.py +51 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/tests/test_help.py +140 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/tests/test_initialize.py +92 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/__init__.py +68 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/create.py +106 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/delete.py +69 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/edit.py +48 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/export.py +67 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/list.py +109 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/renumber.py +95 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/show.py +98 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_create.py +362 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_create_launcher.py +158 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_delete.py +54 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_edit.py +43 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_export.py +129 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_list.py +106 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_renumber.py +118 -0
- taucmdr-1.7.0/packages/taucmdr/cli/commands/trial/tests/test_show.py +58 -0
- taucmdr-1.7.0/packages/taucmdr/cli/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/cli/tests/test_arguments.py +63 -0
- taucmdr-1.7.0/packages/taucmdr/cli/tests/test_cli_view.py +77 -0
- taucmdr-1.7.0/packages/taucmdr/cli/tests/test_command.py +58 -0
- taucmdr-1.7.0/packages/taucmdr/cli/tests/test_init.py +47 -0
- taucmdr-1.7.0/packages/taucmdr/error.py +226 -0
- taucmdr-1.7.0/packages/taucmdr/gui/__init__.py +30 -0
- taucmdr-1.7.0/packages/taucmdr/logger.py +429 -0
- taucmdr-1.7.0/packages/taucmdr/model/__init__.py +27 -0
- taucmdr-1.7.0/packages/taucmdr/model/application.py +270 -0
- taucmdr-1.7.0/packages/taucmdr/model/compiler.py +236 -0
- taucmdr-1.7.0/packages/taucmdr/model/experiment.py +548 -0
- taucmdr-1.7.0/packages/taucmdr/model/measurement.py +648 -0
- taucmdr-1.7.0/packages/taucmdr/model/project.py +204 -0
- taucmdr-1.7.0/packages/taucmdr/model/target.py +762 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_application.py +115 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_compiler.py +47 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_experiment.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_measurement.py +117 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_project.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_target.py +103 -0
- taucmdr-1.7.0/packages/taucmdr/model/tests/test_trial.py +53 -0
- taucmdr-1.7.0/packages/taucmdr/model/trial.py +581 -0
- taucmdr-1.7.0/packages/taucmdr/mvc/__init__.py +173 -0
- taucmdr-1.7.0/packages/taucmdr/mvc/controller.py +539 -0
- taucmdr-1.7.0/packages/taucmdr/mvc/model.py +604 -0
- taucmdr-1.7.0/packages/taucmdr/mvc/tests/__init__.py +26 -0
- taucmdr-1.7.0/packages/taucmdr/mvc/tests/test_controller.py +38 -0
- taucmdr-1.7.0/packages/taucmdr/mvc/tests/test_model.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/progress.py +306 -0
- taucmdr-1.7.0/packages/taucmdr/tests/__init__.py +495 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_cli_reference.py +118 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_error.py +36 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_imports.py +69 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_init.py +182 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_launcher.py +180 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_logger.py +37 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_no_system_level.py +110 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_progress.py +103 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_pylint.py +139 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_requirements.py +78 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_run_tests.py +303 -0
- taucmdr-1.7.0/packages/taucmdr/tests/test_util.py +386 -0
- taucmdr-1.7.0/packages/taucmdr/util.py +924 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/PKG-INFO +115 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/SOURCES.txt +335 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/dependency_links.txt +1 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/requires.txt +4 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/scm_file_list.json +332 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/scm_version.json +8 -0
- taucmdr-1.7.0/packages/taucmdr.egg-info/top_level.txt +1 -0
- taucmdr-1.7.0/pylintrc +326 -0
- taucmdr-1.7.0/pyproject.toml +55 -0
- taucmdr-1.7.0/requirements-dev.txt +6 -0
- taucmdr-1.7.0/scripts/run_tests.py +211 -0
- taucmdr-1.7.0/scripts/tau +55 -0
- taucmdr-1.7.0/setup.cfg +4 -0
- taucmdr-1.7.0/tox.ini +40 -0
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
program blockmatrix
|
|
2
|
+
implicit none
|
|
3
|
+
integer, dimension(:,:), codimension[:,:], allocatable :: a, b, c
|
|
4
|
+
integer, dimension(:,:), allocatable :: bigmat
|
|
5
|
+
integer :: numimgs
|
|
6
|
+
integer :: nrows, ncols
|
|
7
|
+
integer :: blockrows=5, blockcols=5
|
|
8
|
+
integer :: myrow, mycol
|
|
9
|
+
integer :: startrow, startcol
|
|
10
|
+
integer :: i,j,k
|
|
11
|
+
|
|
12
|
+
! calculate block decomposition
|
|
13
|
+
numimgs = num_images()
|
|
14
|
+
call nearsquare(numimgs, nrows, ncols)
|
|
15
|
+
if (nrows /= ncols) then
|
|
16
|
+
print *,'Sorry, only works for square numbers of images right now.'
|
|
17
|
+
stop
|
|
18
|
+
endif
|
|
19
|
+
allocate(a(blockrows,blockcols)[nrows,*])
|
|
20
|
+
allocate(b(blockcols,blockrows)[nrows,*])
|
|
21
|
+
allocate(c(blockrows,blockrows)[nrows,*])
|
|
22
|
+
|
|
23
|
+
! where is this image in the decomposition?
|
|
24
|
+
mycol = ceiling(this_image()*1./nrows)
|
|
25
|
+
myrow = modulo(this_image(),nrows)
|
|
26
|
+
if (myrow == 0) myrow=nrows
|
|
27
|
+
|
|
28
|
+
! initialize data
|
|
29
|
+
startrow = (myrow-1)*blockrows+1
|
|
30
|
+
startcol = (mycol-1)*blockcols+1
|
|
31
|
+
do i=1,blockrows
|
|
32
|
+
a(i,:) = startrow+i-1
|
|
33
|
+
enddo
|
|
34
|
+
do j=1,blockcols
|
|
35
|
+
b(:,j) = startcol+j-1
|
|
36
|
+
enddo
|
|
37
|
+
|
|
38
|
+
! do the multiplication
|
|
39
|
+
sync all
|
|
40
|
+
c = 0.
|
|
41
|
+
do k=1,ncols
|
|
42
|
+
c = c + matmul(a(:,:)[myrow,k],b(:,:)[k,mycol])
|
|
43
|
+
enddo
|
|
44
|
+
sync all
|
|
45
|
+
|
|
46
|
+
if (this_image() == 1) then
|
|
47
|
+
allocate(bigmat(nrows*blockrows,ncols*blockcols))
|
|
48
|
+
bigmat = reshape( [((i,i=1,nrows*blockrows),j=1,ncols*blockcols)], &
|
|
49
|
+
[nrows*blockrows, ncols*blockcols])
|
|
50
|
+
print *, 'Expected answer: '
|
|
51
|
+
bigmat = matmul(bigmat,transpose(bigmat))
|
|
52
|
+
do i=1,blockrows*nrows
|
|
53
|
+
print '(50(I5,1X))',(bigmat(i,j),j=1,blockcols*ncols)
|
|
54
|
+
enddo
|
|
55
|
+
deallocate(bigmat)
|
|
56
|
+
endif
|
|
57
|
+
|
|
58
|
+
do k=1,num_images()
|
|
59
|
+
if (this_image() == k) then
|
|
60
|
+
print *, 'Image ', k, ' = ', myrow, ', ', mycol
|
|
61
|
+
do i=1,blockrows
|
|
62
|
+
print '(50(I5,1X))',(c(i,j),j=1,blockcols)
|
|
63
|
+
enddo
|
|
64
|
+
endif
|
|
65
|
+
sync all
|
|
66
|
+
enddo
|
|
67
|
+
deallocate(a)
|
|
68
|
+
deallocate(b)
|
|
69
|
+
deallocate(c)
|
|
70
|
+
|
|
71
|
+
contains
|
|
72
|
+
subroutine nearsquare(n, a, b)
|
|
73
|
+
implicit none
|
|
74
|
+
integer, intent(in) :: n
|
|
75
|
+
integer, intent(out) :: a, b
|
|
76
|
+
|
|
77
|
+
do a=ceiling(sqrt(n*1.0)),1,-1
|
|
78
|
+
b = n/a
|
|
79
|
+
if (a*b == n) exit
|
|
80
|
+
enddo
|
|
81
|
+
end subroutine nearsquare
|
|
82
|
+
|
|
83
|
+
end program blockmatrix
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
#!/usr/bin/env python
|
|
2
|
+
# Program written by Devin Shende on August 5th 2018
|
|
3
|
+
|
|
4
|
+
def first_prime_after(x):
|
|
5
|
+
import math
|
|
6
|
+
current = x + 1
|
|
7
|
+
sqrtno = math.sqrt(current)
|
|
8
|
+
while True:
|
|
9
|
+
# search for primes starting at x until it finds one
|
|
10
|
+
# break once found a prime
|
|
11
|
+
for potential_factor in range(2, current):
|
|
12
|
+
# start at 2 because 1 will always be a factor
|
|
13
|
+
# go all the way up to the sqrt of current looking for a factor
|
|
14
|
+
if current % potential_factor == 0:
|
|
15
|
+
# Found factor. not prime
|
|
16
|
+
break # move on to next number
|
|
17
|
+
elif potential_factor >= sqrtno:
|
|
18
|
+
print("The first prime number after {} is {}".format(x, current))
|
|
19
|
+
return current
|
|
20
|
+
current += 1
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
first_prime_after(10000000)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
#include <fcntl.h>
|
|
2
|
+
#include <stdio.h>
|
|
3
|
+
#include <unistd.h>
|
|
4
|
+
|
|
5
|
+
/* Makes a known number of POSIX I/O calls: 10 open, 5 write, 5 read, 10 close. */
|
|
6
|
+
int main(int argc, char *argv[])
|
|
7
|
+
{
|
|
8
|
+
char buf[16] = "hello io\n";
|
|
9
|
+
for (int i = 0; i < 5; ++i) {
|
|
10
|
+
int fd = open("io-test.txt", O_CREAT | O_WRONLY | O_TRUNC, 0644);
|
|
11
|
+
if (fd < 0 || write(fd, buf, 9) != 9 || close(fd) != 0) {
|
|
12
|
+
perror("write io-test.txt");
|
|
13
|
+
return 1;
|
|
14
|
+
}
|
|
15
|
+
fd = open("io-test.txt", O_RDONLY);
|
|
16
|
+
if (fd < 0 || read(fd, buf, sizeof buf) != 9 || close(fd) != 0) {
|
|
17
|
+
perror("read io-test.txt");
|
|
18
|
+
return 1;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
printf("Done\n");
|
|
22
|
+
return 0;
|
|
23
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2013 NVIDIA Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
#include <math.h>
|
|
18
|
+
#include <string.h>
|
|
19
|
+
#include <openacc.h>
|
|
20
|
+
#include <stdio.h>
|
|
21
|
+
#include "timer.h"
|
|
22
|
+
|
|
23
|
+
#define NN 1024
|
|
24
|
+
#define NM 1024
|
|
25
|
+
|
|
26
|
+
double A[NN][NM];
|
|
27
|
+
double Anew[NN][NM];
|
|
28
|
+
|
|
29
|
+
int main(int argc, char** argv)
|
|
30
|
+
{
|
|
31
|
+
const int n = NN;
|
|
32
|
+
const int m = NM;
|
|
33
|
+
const int iter_max = 1000;
|
|
34
|
+
|
|
35
|
+
const double tol = 1.0e-6;
|
|
36
|
+
double error = 1.0;
|
|
37
|
+
|
|
38
|
+
memset(A, 0, n * m * sizeof(double));
|
|
39
|
+
memset(Anew, 0, n * m * sizeof(double));
|
|
40
|
+
|
|
41
|
+
for (int j = 0; j < n; j++)
|
|
42
|
+
{
|
|
43
|
+
A[j][0] = 1.0;
|
|
44
|
+
Anew[j][0] = 1.0;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
printf("Jacobi relaxation Calculation: %d x %d mesh\n", n, m);
|
|
48
|
+
|
|
49
|
+
StartTimer();
|
|
50
|
+
int iter = 0;
|
|
51
|
+
|
|
52
|
+
#pragma acc data copyin(Anew), copy(A)
|
|
53
|
+
while ( error > tol && iter < iter_max )
|
|
54
|
+
{
|
|
55
|
+
error = 0.0;
|
|
56
|
+
|
|
57
|
+
#pragma acc kernels
|
|
58
|
+
for( int j = 1; j < n-1; j++)
|
|
59
|
+
{
|
|
60
|
+
for( int i = 1; i < m-1; i++ )
|
|
61
|
+
{
|
|
62
|
+
Anew[j][i] = 0.25 * ( A[j][i+1] + A[j][i-1]
|
|
63
|
+
+ A[j-1][i] + A[j+1][i]);
|
|
64
|
+
error = fmax( error, fabs(Anew[j][i] - A[j][i]));
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
#pragma acc kernels
|
|
69
|
+
for( int j = 1; j < n-1; j++)
|
|
70
|
+
{
|
|
71
|
+
for( int i = 1; i < m-1; i++ )
|
|
72
|
+
{
|
|
73
|
+
A[j][i] = Anew[j][i];
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
if(iter % 100 == 0) printf("%5d, %0.6f\n", iter, error);
|
|
78
|
+
|
|
79
|
+
iter++;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
double runtime = GetTimer();
|
|
83
|
+
|
|
84
|
+
printf(" total: %f s\n", runtime / 1000);
|
|
85
|
+
}
|
|
@@ -0,0 +1,313 @@
|
|
|
1
|
+
/******************************************************************************
|
|
2
|
+
* OpenMp Example - Matrix Multiply - C Version
|
|
3
|
+
* Demonstrates a matrix multiply using OpenMP.
|
|
4
|
+
*
|
|
5
|
+
* Modified from here:
|
|
6
|
+
* https://computing.llnl.gov/tutorials/openMP/samples/C/omp_mm.c
|
|
7
|
+
*
|
|
8
|
+
* For PAPI_FP_INS, the exclusive count for the event:
|
|
9
|
+
* for (null) [OpenMP location: file:matmult.c ]
|
|
10
|
+
* should be 2E+06 / Number of Threads
|
|
11
|
+
******************************************************************************/
|
|
12
|
+
#include <stdio.h>
|
|
13
|
+
#include <stdlib.h>
|
|
14
|
+
|
|
15
|
+
#ifdef TAU_MPI
|
|
16
|
+
int provided;
|
|
17
|
+
#include <mpi.h>
|
|
18
|
+
/* NOTE: MPI is just used to spawn multiple copies of the kernel to different ranks.
|
|
19
|
+
This is not a parallel implementation */
|
|
20
|
+
#endif /* TAU_MPI */
|
|
21
|
+
|
|
22
|
+
#ifdef PTHREADS
|
|
23
|
+
#include <pthread.h>
|
|
24
|
+
#include <unistd.h>
|
|
25
|
+
#include <errno.h>
|
|
26
|
+
/*** NOTE THE ATTR INITIALIZER HERE! ***/
|
|
27
|
+
pthread_mutex_t mutexsum;
|
|
28
|
+
#endif /* PTHREADS */
|
|
29
|
+
|
|
30
|
+
#define APP_USE_INLINE_MULTIPLY 1
|
|
31
|
+
|
|
32
|
+
#ifndef MATRIX_SIZE
|
|
33
|
+
#define MATRIX_SIZE 512
|
|
34
|
+
#endif
|
|
35
|
+
|
|
36
|
+
#define NRA MATRIX_SIZE /* number of rows in matrix A */
|
|
37
|
+
#define NCA MATRIX_SIZE /* number of columns in matrix A */
|
|
38
|
+
#define NCB MATRIX_SIZE /* number of columns in matrix B */
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
void initialize(double **matrix, int rows, int cols) {
|
|
42
|
+
int i,j;
|
|
43
|
+
#pragma omp parallel private(i,j) shared(matrix)
|
|
44
|
+
{
|
|
45
|
+
//set_num_threads();
|
|
46
|
+
/*** Initialize matrices ***/
|
|
47
|
+
#pragma omp for nowait
|
|
48
|
+
for (i=0; i<rows; i++) {
|
|
49
|
+
for (j=0; j<cols; j++) {
|
|
50
|
+
matrix[i][j]= i+j;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
double** allocateMatrix(int rows, int cols) {
|
|
57
|
+
int i;
|
|
58
|
+
double **matrix = (double**)malloc((sizeof(double*)) * rows);
|
|
59
|
+
for (i=0; i<rows; i++) {
|
|
60
|
+
matrix[i] = (double*)malloc((sizeof(double)) * cols);
|
|
61
|
+
}
|
|
62
|
+
return matrix;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
void freeMatrix(double** matrix, int rows, int cols) {
|
|
66
|
+
int i;
|
|
67
|
+
for (i=0; i<rows; i++) {
|
|
68
|
+
free(matrix[i]);
|
|
69
|
+
}
|
|
70
|
+
free(matrix);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
double multiply(double a, double b) {
|
|
74
|
+
return a * b;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
#ifdef TAU_OPENMP
|
|
78
|
+
// cols_a and rows_b are the same value
|
|
79
|
+
void compute_nested(double **a, double **b, double **c, int rows_a, int cols_a, int cols_b) {
|
|
80
|
+
int i,j,k;
|
|
81
|
+
double tmp = 0.0;
|
|
82
|
+
/*** Do matrix multiply sharing iterations on outer loop ***/
|
|
83
|
+
/*** Display who does which iterations for demonstration purposes ***/
|
|
84
|
+
#pragma omp parallel for private(i,j,k) shared(a,b,c)
|
|
85
|
+
for (i=0; i<rows_a; i++) {
|
|
86
|
+
{
|
|
87
|
+
for (k=0; k<cols_a; k++) {
|
|
88
|
+
for(j=0; j<cols_b; j++) {
|
|
89
|
+
#ifdef APP_USE_INLINE_MULTIPLY
|
|
90
|
+
c[i][j] += multiply(a[i][k], b[k][j]);
|
|
91
|
+
#else
|
|
92
|
+
tmp = a[i][k];
|
|
93
|
+
tmp = tmp * b[k][j];
|
|
94
|
+
c[i][j] += tmp;
|
|
95
|
+
#endif
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
#endif
|
|
102
|
+
|
|
103
|
+
// cols_a and rows_b are the same value
|
|
104
|
+
void compute(double **a, double **b, double **c, int rows_a, int cols_a, int cols_b) {
|
|
105
|
+
int i,j,k;
|
|
106
|
+
#pragma omp parallel private(i,j,k) shared(a,b,c)
|
|
107
|
+
{
|
|
108
|
+
/*** Do matrix multiply sharing iterations on outer loop ***/
|
|
109
|
+
/*** Display who does which iterations for demonstration purposes ***/
|
|
110
|
+
#pragma omp for nowait
|
|
111
|
+
for (i=0; i<rows_a; i++) {
|
|
112
|
+
for(j=0; j<cols_b; j++) {
|
|
113
|
+
for (k=0; k<cols_a; k++) {
|
|
114
|
+
#ifdef APP_USE_INLINE_MULTIPLY
|
|
115
|
+
c[i][j] += multiply(a[i][k], b[k][j]);
|
|
116
|
+
#else /* APP_USE_INLINE_MULTIPLY */
|
|
117
|
+
c[i][j] += a[i][k] * b[k][j];
|
|
118
|
+
#endif /* APP_USE_INLINE_MULTIPLY */
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
} /*** End of parallel region ***/
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
void compute_interchange(double **a, double **b, double **c, int rows_a, int cols_a, int cols_b) {
|
|
126
|
+
int i,j,k;
|
|
127
|
+
#pragma omp parallel private(i,j,k) shared(a,b,c)
|
|
128
|
+
{
|
|
129
|
+
/*** Do matrix multiply sharing iterations on outer loop ***/
|
|
130
|
+
/*** Display who does which iterations for demonstration purposes ***/
|
|
131
|
+
#pragma omp for nowait
|
|
132
|
+
for (i=0; i<rows_a; i++) {
|
|
133
|
+
for (k=0; k<cols_a; k++) {
|
|
134
|
+
for(j=0; j<cols_b; j++) {
|
|
135
|
+
#ifdef APP_USE_INLINE_MULTIPLY
|
|
136
|
+
c[i][j] += multiply(a[i][k], b[k][j]);
|
|
137
|
+
#else /* APP_USE_INLINE_MULTIPLY */
|
|
138
|
+
c[i][j] += a[i][k] * b[k][j];
|
|
139
|
+
#endif /* APP_USE_INLINE_MULTIPLY */
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
} /*** End of parallel region ***/
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
double do_work(void) {
|
|
147
|
+
double **a, /* matrix A to be multiplied */
|
|
148
|
+
**b, /* matrix B to be multiplied */
|
|
149
|
+
**c; /* result matrix C */
|
|
150
|
+
a = allocateMatrix(NRA, NCA);
|
|
151
|
+
b = allocateMatrix(NCA, NCB);
|
|
152
|
+
c = allocateMatrix(NRA, NCB);
|
|
153
|
+
|
|
154
|
+
/*** Spawn a parallel region explicitly scoping all variables ***/
|
|
155
|
+
|
|
156
|
+
initialize(a, NRA, NCA);
|
|
157
|
+
initialize(b, NCA, NCB);
|
|
158
|
+
initialize(c, NRA, NCB);
|
|
159
|
+
|
|
160
|
+
compute(a, b, c, NRA, NCA, NCB);
|
|
161
|
+
#if defined(TAU_OPENMP)
|
|
162
|
+
//if (omp_get_nested()) {
|
|
163
|
+
compute_nested(a, b, c, NRA, NCA, NCB);
|
|
164
|
+
//}
|
|
165
|
+
#endif
|
|
166
|
+
#ifdef TAU_MPI
|
|
167
|
+
if (provided == MPI_THREAD_MULTIPLE) {
|
|
168
|
+
printf("provided is MPI_THREAD_MULTIPLE\n");
|
|
169
|
+
} else if (provided == MPI_THREAD_FUNNELED) {
|
|
170
|
+
printf("provided is MPI_THREAD_FUNNELED\n");
|
|
171
|
+
}
|
|
172
|
+
#endif /* TAU_MPI */
|
|
173
|
+
compute_interchange(a, b, c, NRA, NCA, NCB);
|
|
174
|
+
|
|
175
|
+
double result = c[0][1];
|
|
176
|
+
|
|
177
|
+
freeMatrix(a, NRA, NCA);
|
|
178
|
+
freeMatrix(b, NCA, NCB);
|
|
179
|
+
freeMatrix(c, NCA, NCB);
|
|
180
|
+
|
|
181
|
+
return result;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
#ifdef PTHREADS
|
|
185
|
+
int busy_sleep() {
|
|
186
|
+
int i, sum = 0;
|
|
187
|
+
for (i = 0 ; i < 100000000 ; i++) {
|
|
188
|
+
sum = sum+i;
|
|
189
|
+
}
|
|
190
|
+
return sum;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
void * threaded_func(void *data)
|
|
194
|
+
{
|
|
195
|
+
int rc;
|
|
196
|
+
int sum = 0;
|
|
197
|
+
// compute
|
|
198
|
+
do_work();
|
|
199
|
+
|
|
200
|
+
#ifdef APP_DO_LOCK_TEST
|
|
201
|
+
// test locking - sampling should catch this
|
|
202
|
+
if ((rc = pthread_mutex_lock(&mutexsum)) != 0)
|
|
203
|
+
{
|
|
204
|
+
errno = rc;
|
|
205
|
+
perror("thread lock error");
|
|
206
|
+
exit(1);
|
|
207
|
+
}
|
|
208
|
+
fprintf(stderr,"Thread 'sleeping'...\n"); fflush(stderr);
|
|
209
|
+
sum += busy_sleep();
|
|
210
|
+
fprintf(stderr,"Thread 'awake'...\n"); fflush(stderr);
|
|
211
|
+
if ((rc = pthread_mutex_unlock(&mutexsum)) != 0)
|
|
212
|
+
{
|
|
213
|
+
errno = rc;
|
|
214
|
+
perror("thread unlock error");
|
|
215
|
+
exit(1);
|
|
216
|
+
}
|
|
217
|
+
pthread_exit((void*) 0);
|
|
218
|
+
//return NULL;
|
|
219
|
+
#endif // APP_DO_LOCK_TEST
|
|
220
|
+
}
|
|
221
|
+
#endif // PTHREADS
|
|
222
|
+
|
|
223
|
+
int main (int argc, char *argv[])
|
|
224
|
+
{
|
|
225
|
+
|
|
226
|
+
#ifdef PTHREADS
|
|
227
|
+
int ret;
|
|
228
|
+
pthread_attr_t attr;
|
|
229
|
+
pthread_t tid1, tid2, tid3;
|
|
230
|
+
pthread_mutexattr_t Attr;
|
|
231
|
+
pthread_mutexattr_init(&Attr);
|
|
232
|
+
pthread_mutexattr_settype(&Attr, PTHREAD_MUTEX_ERRORCHECK);
|
|
233
|
+
if (pthread_mutex_init(&mutexsum, &Attr)) {
|
|
234
|
+
printf("Error while using pthread_mutex_init\n");
|
|
235
|
+
}
|
|
236
|
+
#endif /* PTHREADS */
|
|
237
|
+
|
|
238
|
+
#ifdef TAU_MPI
|
|
239
|
+
int rc = MPI_SUCCESS;
|
|
240
|
+
#if defined(PTHREADS)
|
|
241
|
+
rc = MPI_Init_thread(&argc, &argv, MPI_THREAD_MULTIPLE, &provided);
|
|
242
|
+
printf("MPI_Init_thread: provided = %d, MPI_THREAD_MULTIPLE=%d\n", provided, MPI_THREAD_MULTIPLE);
|
|
243
|
+
#elif defined(TAU_OPENMP)
|
|
244
|
+
rc = MPI_Init_thread(&argc, &argv, MPI_THREAD_FUNNELED, &provided);
|
|
245
|
+
printf("MPI_Init_thread: provided = %d, MPI_THREAD_FUNNELED=%d\n", provided, MPI_THREAD_FUNNELED);
|
|
246
|
+
#else
|
|
247
|
+
rc = MPI_Init(&argc, &argv);
|
|
248
|
+
#endif /* THREADS */
|
|
249
|
+
if (rc != MPI_SUCCESS) {
|
|
250
|
+
char *errorstring;
|
|
251
|
+
int length = 0;
|
|
252
|
+
MPI_Error_string(rc, errorstring, &length);
|
|
253
|
+
printf("Error: MPI_Init failed, rc = %d\n%s\n", rc, errorstring);
|
|
254
|
+
exit(1);
|
|
255
|
+
}
|
|
256
|
+
#endif /* TAU_MPI */
|
|
257
|
+
|
|
258
|
+
#ifdef PTHREADS
|
|
259
|
+
if (ret = pthread_create(&tid1, NULL, threaded_func, NULL) )
|
|
260
|
+
{
|
|
261
|
+
printf("Error: pthread_create (1) fails ret = %d\n", ret);
|
|
262
|
+
exit(1);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
if (ret = pthread_create(&tid2, NULL, threaded_func, NULL) )
|
|
266
|
+
{
|
|
267
|
+
printf("Error: pthread_create (2) fails ret = %d\n", ret);
|
|
268
|
+
exit(1);
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
if (ret = pthread_create(&tid3, NULL, threaded_func, NULL) )
|
|
272
|
+
{
|
|
273
|
+
printf("Error: pthread_create (3) fails ret = %d\n", ret);
|
|
274
|
+
exit(1);
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
#endif /* PTHREADS */
|
|
278
|
+
|
|
279
|
+
/* On thread 0: */
|
|
280
|
+
int i;
|
|
281
|
+
//for (i = 0 ; i < 100 ; i++) {
|
|
282
|
+
do_work();
|
|
283
|
+
//}
|
|
284
|
+
|
|
285
|
+
#ifdef PTHREADS
|
|
286
|
+
if (ret = pthread_join(tid1, NULL) )
|
|
287
|
+
{
|
|
288
|
+
printf("Error: pthread_join (1) fails ret = %d\n", ret);
|
|
289
|
+
exit(1);
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
if (ret = pthread_join(tid2, NULL) )
|
|
293
|
+
{
|
|
294
|
+
printf("Error: pthread_join (2) fails ret = %d\n", ret);
|
|
295
|
+
exit(1);
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
if (ret = pthread_join(tid3, NULL) )
|
|
299
|
+
{
|
|
300
|
+
printf("Error: pthread_join (3) fails ret = %d\n", ret);
|
|
301
|
+
exit(1);
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
pthread_mutex_destroy(&mutexsum);
|
|
305
|
+
#endif /* PTHREADS */
|
|
306
|
+
|
|
307
|
+
#ifdef TAU_MPI
|
|
308
|
+
MPI_Finalize();
|
|
309
|
+
#endif /* TAU_MPI */
|
|
310
|
+
printf ("Done.\n");
|
|
311
|
+
|
|
312
|
+
return 0;
|
|
313
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
#include <mpi.h>
|
|
2
|
+
#include <stdio.h>
|
|
3
|
+
#include <stdlib.h>
|
|
4
|
+
|
|
5
|
+
int main (int argc, char ** argv)
|
|
6
|
+
{
|
|
7
|
+
int numtasks, taskid, len;
|
|
8
|
+
char hostname[MPI_MAX_PROCESSOR_NAME];
|
|
9
|
+
|
|
10
|
+
MPI_Init(&argc, &argv);
|
|
11
|
+
MPI_Comm_size(MPI_COMM_WORLD, &numtasks);
|
|
12
|
+
MPI_Comm_rank(MPI_COMM_WORLD,&taskid);
|
|
13
|
+
MPI_Get_processor_name(hostname, &len);
|
|
14
|
+
printf ("Hello from task %d on %s!\n", taskid, hostname);
|
|
15
|
+
if (taskid == 0)
|
|
16
|
+
printf("Number of MPI tasks is: %d\n",numtasks);
|
|
17
|
+
MPI_Finalize();
|
|
18
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"_default": {"1": {"key": "selected_project", "value": 1}}, "Project": {"1": {"name": "oldproj", "targets": [1], "applications": [1], "measurements": [1], "experiments": [], "init_options": "--bare --backend tinydb --project-name oldproj"}}, "Target": {"1": {"projects": [1], "name": "oldtarg", "host_os": "Linux", "host_arch": "x86_64", "Host_CC": 1, "Host_CXX": 2, "Host_FC": 3, "cuda_toolkit": "/usr/local/cuda", "tau_source": "download", "pdt_source": "download", "binutils_source": "download", "unwinder": "libunwind", "libunwind_source": "download", "libdwarf_source": "download", "libelf_source": "download", "papi_source": "download", "scorep_source": "download", "ompt_source": "download", "libotf2_source": "download", "sqlite3_source": "download", "level_zero_source": "download"}}, "Application": {"1": {"projects": [1], "name": "oldapp", "openmp": false, "openacc": false, "pthreads": false, "python": false, "tbb": false, "mpi": false, "caf": false, "cuda": false, "opencl": false, "shmem": false, "mpc": false, "linkage": "dynamic"}}, "Measurement": {"1": {"projects": [1], "name": "oldmeas", "baseline": false, "profile": "tau", "trace": "none", "sample": true, "source_inst": "never", "compiler_inst": "never", "mpi": false, "openmp": "ignore", "openacc": false, "cuda": false, "shmem": false, "opencl": false, "callpath": 100, "unwind_depth": 0, "io": false, "heap_usage": false, "system_load": false, "memory_alloc": false, "metrics": ["TIME"], "keep_inst_files": false, "reuse_inst_files": false, "comm_matrix": false, "throttle": true, "throttle_per_call": 10, "throttle_num_calls": 100000, "sample_resolution": "line", "sampling_period": 5000, "track_memory_footprint": false, "metadata_merge": true, "callsite": false, "update_nightly": false, "ptts": false, "ptts_post": false, "ptts_sample_flags": "", "ptts_restart": false, "ptts_start": "", "ptts_stop": "", "ptts_report_flags": "", "mpit": false, "level_zero": false, "tag": ""}}, "Experiment": {}, "Compiler": {"1": {"uid": "452187dd", "path": "/usr/bin/gcc", "family": "GNU", "role": "Host_CC"}, "2": {"uid": "ca4050bd", "path": "/usr/bin/g++", "family": "GNU", "role": "Host_CXX"}, "3": {"uid": "9edef6ab", "path": "/usr/bin/gfortran", "family": "GNU", "role": "Host_FC"}}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"_default": {}, "Project": {}, "Compiler": {"1": {"uid": "452187dd", "path": "/usr/bin/gcc", "family": "GNU", "role": "Host_CC"}, "2": {"uid": "ca4050bd", "path": "/usr/bin/g++", "family": "GNU", "role": "Host_CXX"}, "3": {"uid": "9edef6ab", "path": "/usr/bin/gfortran", "family": "GNU", "role": "Host_FC"}}, "Target": {"1": {"projects": [], "name": "usertarg", "host_os": "Linux", "host_arch": "x86_64", "Host_CC": 1, "Host_CXX": 2, "Host_FC": 3, "cuda_toolkit": "/usr/local/cuda", "tau_source": "download", "pdt_source": "download", "binutils_source": "download", "unwinder": "libunwind", "libunwind_source": "download", "libdwarf_source": "download", "libelf_source": "download", "papi_source": "download", "scorep_source": "download", "ompt_source": "download", "libotf2_source": "download", "sqlite3_source": "download", "level_zero_source": "download"}}, "Application": {}, "Measurement": {}}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2012 NVIDIA Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
#ifndef TIMER_H
|
|
18
|
+
#define TIMER_H
|
|
19
|
+
|
|
20
|
+
#include <stdlib.h>
|
|
21
|
+
|
|
22
|
+
#ifdef WIN32
|
|
23
|
+
#define WIN32_LEAN_AND_MEAN
|
|
24
|
+
#include <windows.h>
|
|
25
|
+
#else
|
|
26
|
+
#include <sys/time.h>
|
|
27
|
+
#endif
|
|
28
|
+
|
|
29
|
+
#ifdef WIN32
|
|
30
|
+
double PCFreq = 0.0;
|
|
31
|
+
__int64 timerStart = 0;
|
|
32
|
+
#else
|
|
33
|
+
struct timeval timerStart;
|
|
34
|
+
#endif
|
|
35
|
+
|
|
36
|
+
void StartTimer()
|
|
37
|
+
{
|
|
38
|
+
#ifdef WIN32
|
|
39
|
+
LARGE_INTEGER li;
|
|
40
|
+
if(!QueryPerformanceFrequency(&li))
|
|
41
|
+
printf("QueryPerformanceFrequency failed!\n");
|
|
42
|
+
|
|
43
|
+
PCFreq = (double)li.QuadPart/1000.0;
|
|
44
|
+
|
|
45
|
+
QueryPerformanceCounter(&li);
|
|
46
|
+
timerStart = li.QuadPart;
|
|
47
|
+
#else
|
|
48
|
+
gettimeofday(&timerStart, NULL);
|
|
49
|
+
#endif
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
// time elapsed in ms
|
|
53
|
+
double GetTimer()
|
|
54
|
+
{
|
|
55
|
+
#ifdef WIN32
|
|
56
|
+
LARGE_INTEGER li;
|
|
57
|
+
QueryPerformanceCounter(&li);
|
|
58
|
+
return (double)(li.QuadPart-timerStart)/PCFreq;
|
|
59
|
+
#else
|
|
60
|
+
struct timeval timerStop, timerElapsed;
|
|
61
|
+
gettimeofday(&timerStop, NULL);
|
|
62
|
+
timersub(&timerStop, &timerStart, &timerElapsed);
|
|
63
|
+
return timerElapsed.tv_sec*1000.0+timerElapsed.tv_usec/1000.0;
|
|
64
|
+
#endif
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
#endif // TIMER_H
|