Commit Graph

37 Commits

Author SHA1 Message Date
German Andryeyev eccf328c14 SWDEV-307184 - Make sure runtime passes CO version into comgr
Disable devlib linking when runtime links multiple objects from
the app. Otherwise devlibs will be linked twice and may cause
undefined behavior with COv5.

Change-Id: I3b8640c64ff898893225fe3af5b4b4a32d42bf40


[ROCm/clr commit: c275d9b4b3]
2022-04-25 09:53:59 -04:00
agunashe 49f0546637 SWDEV-293742 - Update copyright end year VDI repo
Change-Id: I69d2fea4a7a43adf96ccea794270e4af991c5261


[ROCm/clr commit: d96481fb36]
2021-08-22 23:56:07 -07:00
Laurent Morichetti e284923583 Update copyright info
Change-Id: Ia4f9ff0f5f873b4223a8cca154188bb0d2f1abba


[ROCm/clr commit: b4c6143a2f]
2020-02-04 09:26:14 -08:00
foreman f4cbe3a464 P4 to Git Change 1914428 by gandryey@gera-win10 on 2019/06/27 18:22:17
SWDEV-79445 - OCL generic changes and code clean-up
	- Remove all compilaiton flags for LC. LC should be selected dynamically only.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#141 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/paldevice.cpp#146 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palsettings.cpp#86 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocdevice.cpp#130 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocsettings.cpp#45 edit
... //depot/stg/opencl/drivers/opencl/runtime/utils/flags.hpp#312 edit
... //depot/stg/opencl/drivers/opencl/runtime/utils/macros.hpp#12 edit


[ROCm/clr commit: c3f3ef430f]
2019-06-27 18:24:28 -04:00
foreman 3a2d23357a P4 to Git Change 1757959 by asalmanp@asalmanp-ocl-stg on 2019/03/18 18:53:08
SWDEV-132899 - [OCL][GFX10] propagate "force-wgp-mode" option to finalizer

	ReviewRequestURL = ReviewRequestURL = http://ocltc.amd.com/reviews/r/16894/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#71 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#140 edit


[ROCm/clr commit: ddba7b6c8d]
2019-03-18 19:12:32 -04:00
foreman bd530def40 P4 to Git Change 1584825 by asalmanp@asalmanp-ocl-stg on 2018/07/24 16:08:09
SWDEV-132899 - Propagate -xnack option to Finalizer

	ReviewURLBoard = http://ocltc.amd.com/reviews/r/15478/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#70 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#139 edit


[ROCm/clr commit: 439ddcff00]
2018-07-24 16:41:18 -04:00
foreman 3d4652b8a3 P4 to Git Change 1524559 by asalmanp@asalmanp-ocl-stg on 2018/03/08 14:18:24
SWDEV-132899 - [gfx10][OCL]- Adding support for forcing WaveSize32 from runtime for testing on gfx10 HW emulator

	Motivation: During testing ocltst on Windows on PAL/HSAIL/SC path on gfx10 HW emulator, it was found that SC uses WaveSize64 by default for compute kernels.
	SC also has an interface that can be used for forcing the WaveSize to 32 or 64.

	- Adding the "-force-wave-size-32" into compiler to be passed down to Finalizer/SC
	- Adding environment variable "GPU_FORCE_WAVE_SIZE_32" that can be used from runtime to force WaveSize32 compilation in HSAIL/SC path

	ReviewBoardURL = http://ocltc.amd.com/reviews/r/14364/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#69 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#138 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palprogram.cpp#55 edit
... //depot/stg/opencl/drivers/opencl/runtime/utils/flags.hpp#284 edit


[ROCm/clr commit: 3c0e80074b]
2018-03-08 14:26:17 -05:00
foreman cdfc1b06be P4 to Git Change 1481396 by lmoriche@lmoriche_opencl_dev2 on 2017/11/10 16:12:29
SWDEV-118564 - [OCL-LC-ROCm] Refactor the Lightning Compiler program manager to allow the compiler library API and the ROCm-OpenCL-Driver to coexist in the same platform.
	- Default compiler is the Lightning Compiler
	- Fall back to the HSAIL compiler if the amdoclcl compiler library is in the PATH and the -legacy option is specified (or app-detect)

Affected files ...

... //depot/stg/opencl/drivers/opencl/Makefile#59 edit
... //depot/stg/opencl/drivers/opencl/api/opencl/amdocl/build/Makefile.api#168 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/api/v0_8/acl.cpp#44 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/api/v0_8/aclLoaders.cpp#14 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/api/v0_8/aclValidation.cpp#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/build/Makefile.complib#98 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/loaders/elf/elf.hpp#26 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#137 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/build/Makefile.utils#19 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/cpu/cpuprogram.cpp#71 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/device.cpp#213 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/device.hpp#292 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuprogram.cpp#235 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palprogram.cpp#49 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/build/Makefile.oclrocm#20 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/roccompiler.cpp#38 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/roccompilerlib.cpp#8 delete
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/roccompilerlib.hpp#6 delete
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocdevice.cpp#75 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rockernel.cpp#30 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rockernel.hpp#17 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocprogram.cpp#75 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocprogram.hpp#30 edit
... //depot/stg/opencl/drivers/opencl/runtime/platform/program.cpp#88 edit


[ROCm/clr commit: 88ba77a1b4]
2017-11-10 16:21:49 -05:00
foreman f340618f4c P4 to Git Change 1451958 by skudchad@skudchad_test_win_opencl2 on 2017/08/25 19:27:11
SWDEV-116136 - Support -Og for Clang

	ReviewBoardURL = http://ocltc.amd.com/reviews/r/13341/diff/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/codegen.cpp#3 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/linker.cpp#4 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/opt_level.cpp#2 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/opt_level.hpp#3 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/optimizer.cpp#3 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/gpu/hsail_be.cpp#5 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/gpu/scwrapper/scState.cpp#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/OPTIONS.def#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/options.cpp#5 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/options.hpp#5 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/codegen.cpp#73 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/linker.cpp#157 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/opt_level.cpp#33 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/opt_level.hpp#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/optimizer.cpp#30 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#68 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#136 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/options.cpp#42 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/options.hpp#19 edit


[ROCm/clr commit: 2c0b212d96]
2017-08-25 19:39:53 -04:00
foreman 26000ade1b P4 to Git Change 1361929 by smekhano@stas-rampitec-hsa on 2017/01/13 17:49:16
SWDEV-109533 - AMDIL: increase inline cost threshold from 400 to 14000
	This is the w/a to allow Blender work on SI device.

	Testing: precheckin
	Reviewed by Boleslaw Ciesielski

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/OPTIONS.def#6 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#135 edit


[ROCm/clr commit: 1330285eca]
2017-01-13 17:56:50 -05:00
foreman 718365b83a P4 to Git Change 1235456 by kebai@kebai_win1 on 2016/02/09 02:47:34
SWDEV-86836 - Enhance caching library class to prepare one-stage kernel caching by:
	0. Moving cache storage setup into constructor
	1. Controlling cache storage size
	2. Explicit cache cleanup
	    a. -kcache-wipe is off by default; when turned on, the caching directory would be wiped off
	    b. Here it's just an option. The implementation (the call of wipeCacheFolders()) will be added in the compiler library
	3. Enforcing cache miss (actual compilation enforcing and adding a new entry to the cache storage).
	    a. -kcache-enforce-miss is off by default; when turned on, the real compilation will be enforced
	    b. Here it's just an option. The implementation will be added in the compiler library
	ReviewBoardURL = http://ocltc.amd.com/reviews/r/9726/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#134 edit
... //depot/stg/opencl/drivers/opencl/compiler/tools/caching/cache.cpp#12 edit
... //depot/stg/opencl/drivers/opencl/compiler/tools/caching/cache.hpp#7 edit


[ROCm/clr commit: c5265e08c6]
2016-02-09 02:52:58 -05:00
foreman 7387f3f09f P4 to Git Change 1222362 by smekhano@stas-rampitec-hsa on 2015/12/18 13:43:21
SWDEV-80173 - HSA HLC: disable liveness analysis and jump threading

	After the investigation I have found liveness analysis never changed code generation in any of the benchmarks or applications.
	Its only use is in the LICM and the hoisting limitation was never really triggered.
	Since the analysis is very expensive I'm disabling it.

	The jump threading is generally bad on the GPU because it creates unstructured control flow.
	Even if hsail might become smaller and have less branches, it does not help because finalzier's structurizer will have to clone blocks.
	Jump threading is disabled for GPU. This improves compilation speed and just slightly improves performance.

	Testing: smoke, precheckin, vray and blender compilation
	Reviewed by Daniil Fukalov

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#133 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/AMDLLVMContextHook.h#29 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Analysis/AMDLiveAnalysis.cpp#32 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDPassManagerBuilder.cpp#61 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/tools/opt/amdopt.inc#29 edit


[ROCm/clr commit: 36fb8d6764]
2015-12-18 13:54:00 -05:00
foreman 097c4462da P4 to Git Change 1206858 by emankov@em-hsa-amd on 2015/11/03 08:44:27
SWDEV-77584 - Compiler Lib: Preparations for enabling HSAIL on OpenCL 1.2 by default. Adding -legacy and -binary_is_spirv.

	-legacy option will be used for forcing AMDIL path after switching HSAIL by default for OpenCL.
	-binary_is_spirv option will be used for indicating that the binary is constructed from SPIRV.

	[Testing] pre-checkin:
	http://ocltc.amd.com:8111/viewModification.html?modId=61541&personal=true&buildTypeId=&tab=vcsModificationBuilds&show_all_builds=true

	[Reviewer] Stanislav Mekhanoshin
	http://ocltc.amd.com/reviews/r/8850

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/OPTIONS.def#4 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#132 edit


[ROCm/clr commit: 0efe4a5ead]
2015-11-03 08:51:35 -05:00
foreman 439e3dde3b P4 to Git Change 1191624 by emankov@em-hsa-amd on 2015/09/17 08:40:13
ECR #333753 - Compiler Lib: Bug 10998 - Add a way to pass options to finalizer (-Wh,-finalizer-option)

	Works only for HSAIL path.

	Testing: complib -Wh, pre check-in

	Reviewer: Nikolay Haustov

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#52 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#131 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/options.cpp#33 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/options.hpp#18 edit
... //depot/stg/opencl/drivers/opencl/tests/hsa/src/complib/options/-Wh/HelloWorld_Kernel_cl.cl#1 add
... //depot/stg/opencl/drivers/opencl/tests/hsa/tlst/complib.tlst#15 edit


[ROCm/clr commit: 087722ed49]
2015-09-17 08:46:23 -04:00
foreman 5232aa119d P4 to Git Change 1183975 by marsenau@marsenau_home on 2015/08/24 15:19:19
EPR #425389 - Back out changelist 1181925

	Although the compiler library sources are split, the build does not yet use this, so the wrong default value is being used for AMDIL vs. HSAIL

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#130 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/AMDLLVMContextHook.h#28 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/Transforms/IPO/AMDOptOptions.h#8 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDOptOptions.cpp#10 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDPassManagerBuilder.cpp#56 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/tools/opt/amdopt.inc#26 edit


[ROCm/clr commit: adedfc7a66]
2015-08-24 15:37:10 -04:00
foreman 08bd8f4b3b P4 to Git Change 1183928 by yaxunl@yaxunl_stg_win50 on 2015/08/24 13:06:02
ECR #354633 - SPIR-V: Let aoc2 load and save SPIR-V.

	E.g.

	aoc2 -march=hsail-64 -cl-std=CL2.0 -srctospv testReadf.cl
	compile a cl to SPIR-V binary and save it as .spv

	aoc2 -march=hsail-64 -cl-std=CL2.0 -spirv work_group_any.spv
	load a SPIR-V binary and compiles it to ISA and save it to elf in .bin

	Changed the option for round-trip translation of SPIR-V to -round-trip-spirv.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/api/v0_8/acl.cpp#35 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/frontend_clang.cpp#22 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/linker.cpp#133 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/v0_8/if_acl.cpp#74 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/include/v0_8/aclEnums.h#22 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#129 edit
... //depot/stg/opencl/drivers/opencl/compiler/tools/aoc2/aoc2.cpp#76 edit
... //depot/stg/opencl/drivers/opencl/tests/ocltst/module/complib/CLEnumCheck.cpp#47 edit


[ROCm/clr commit: cc13b9f1f6]
2015-08-24 13:14:41 -04:00
foreman e1382f2d12 P4 to Git Change 1181925 by marsenau@marsenau_home on 2015/08/19 00:14:53
ECR #304775 - Remove HLC_Unroll_* variables.

	HLC_Unroll_Scratch_Threshold was unused. The others have equivalent settings in the AMDLLVMContextHook, so consistently use that version. The patches to opt were already had different set of command line flags for the same options.

	This changes two of the defaults in compiler library and the equivalent flags in opt to match the values which were actually in use so this shoudn't change the current behavior. The unroll threshold default and allow partial unrolling defaults were changed to the actually used default values. Eventually all of these custom options should be removed, because in current LLVM these can be controlled per loop by the TargetTransformInfo, and all have equivalent cl::opts already.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#128 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/AMDLLVMContextHook.h#27 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/Transforms/IPO/AMDOptOptions.h#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDOptOptions.cpp#9 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDPassManagerBuilder.cpp#55 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/tools/opt/amdopt.inc#25 edit


[ROCm/clr commit: 5ad9c314c6]
2015-08-19 00:25:53 -04:00
foreman d28d824917 P4 to Git Change 1181226 by kebai@kebai-lnx1 on 2015/08/17 16:11:30
ECR #304775 - Preparation for kernel caching feature
	1. Each device have a separate cache directory
	2. It logs caching errors, so we can debug the cache and/or detect collisions
	3. Implementeded cache size tracking, so we can evict old data when cache files are too large
	4. Added file/path access permission control on both windows and linux
	5. Have read/write file lock protection
	6. -kcache-disable flag can be used to turn on/off the caching functionality
	7. AMD_FORCE_KCACHE_TEST env variable is used for internal testing
	8. For the stage we want to cache, call getCacheEntry() followed by makeCacheEntry() if the get fails; otherwise directly return cached data.
	- After the compiler library code is refactored, getCacheEntry() and makeCacheEntry() will be wrapped into one function call, so that only one call is needed at the place we want to cache

	TO DO:
	1. Use it in the compiler library code
	- Waiting for the decision on how many stages we want to cache, i) 1-stage caching: source->ISA; or ii) 3-stage caching: source->LLVM IR, LLVM IR->IL, IL->ISA
	2. Tracking of timestamps for cache entries
	- LRU eviction when cache grows too large
	- Suggestion from Laurent: Regarding tracking timestamps for LRU eviction: Random eviction would probably perform as well as LRU and does not require timestamps.
	3. Track cache entries per application

	ReviewBoardURL = http://ocltc.amd.com/reviews/r/8194/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/cache.cpp#3 add
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/cache.hpp#3 add
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#127 edit


[ROCm/clr commit: 7b52a80a63]
2015-08-17 16:27:05 -04:00
foreman 5aea79d7bf P4 to Git Change 1180133 by ashi1@ashi1_win50 on 2015/08/13 13:20:33
ECR #292434 - Add option to turn on/off SCOption_POST_RA_INSTRUCTION_SCHEDULING.

	Also fixed some default comments.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/scState.cpp#39 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#126 edit


[ROCm/clr commit: c37750a8ac]
2015-08-13 13:28:01 -04:00
foreman 06b7785be1 P4 to Git Change 1170017 by kebai@kebai-lnx-desktop on 2015/07/13 14:12:55
ECR #304775 - Back out CL 1170011

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/cache.cpp#2 delete
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/cache.hpp#2 delete
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/frontend.cpp#35 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/frontend_clang.cpp#21 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/v0_8/if_acl.cpp#69 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/amdil_be.cpp#44 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#43 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#125 edit
... //depot/stg/opencl/drivers/opencl/tests/kcache/Makefile#2 delete
... //depot/stg/opencl/drivers/opencl/tests/kcache/build/Makefile#2 delete
... //depot/stg/opencl/drivers/opencl/tests/kcache/build/Makefile.kcache#2 delete
... //depot/stg/opencl/drivers/opencl/tests/kcache/kCacheTest_std.txt#2 delete
... //depot/stg/opencl/drivers/opencl/tests/kcache/kernel.cl#2 delete
... //depot/stg/opencl/drivers/opencl/tests/kcache/main.cpp#2 delete


[ROCm/clr commit: 5637f52e00]
2015-07-13 18:17:22 -04:00
foreman 509bd691bb P4 to Git Change 1170011 by kebai@kebai-lnx-desktop on 2015/07/13 13:47:29
ECR #304775 - Bug 10752 kernel caching feature (AMDIL and HSAIL path)
	1. For the stage we want to cache, call getCacheEntry() followed by makeCacheEntry() if the get fails; otherwise directly return cached data.
	a. Each device have a separate cache directory
	b. It logs caching errors, so we can debug the cache and/or detect collisions
	2. Implementeded cache size tracking, so we can evict old data when cache files are too large
	3. Added file/path access permission control on both windows and linux
	4. Have read/write file lock protection
	5. -kcache-disable flag can be used to turn on/off the caching functionality
	6. AMD_FORCE_KCACHE_TEST env variable is used for internal testing

	TO DO:
	1. Tracking of timestamps for cache entries
	-LRU eviction when cache grows too large
	2. Track cache entries per application

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/cache.cpp#1 add
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/cache.hpp#1 add
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/frontend.cpp#34 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/frontend_clang.cpp#20 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/v0_8/if_acl.cpp#68 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/amdil_be.cpp#43 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#42 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#124 edit
... //depot/stg/opencl/drivers/opencl/tests/kcache/Makefile#1 add
... //depot/stg/opencl/drivers/opencl/tests/kcache/build/Makefile#1 add
... //depot/stg/opencl/drivers/opencl/tests/kcache/build/Makefile.kcache#1 add
... //depot/stg/opencl/drivers/opencl/tests/kcache/kCacheTest_std.txt#1 add
... //depot/stg/opencl/drivers/opencl/tests/kcache/kernel.cl#1 add
... //depot/stg/opencl/drivers/opencl/tests/kcache/main.cpp#1 add


[ROCm/clr commit: 4b6f2324d0]
2015-07-13 18:11:44 -04:00
foreman 7b48252995 P4 to Git Change 1140647 by yaxunl@yaxunl_stg_win50 on 2015/04/14 14:38:32
ECR #304775 - Add option to turn on/off SCOption_LIVENESS_BASED_INSTRUCTION_SCHEDULING.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/scState.cpp#35 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#123 edit


[ROCm/clr commit: e81739b759]
2015-04-14 14:53:58 -04:00
foreman 37a547cad5 P4 to Git Change 1137201 by skudchad@skudchad_test_win_opencl2 on 2015/04/02 16:27:14
EPR #403782 - IOMMU2/SVM
	- Enable SCOption_R1200_ENABLE_XNACK whenever IOMMUv2 is supported.
	- Add "-sc-xnack-iommu" option for compile and link and pass this to SCWrapper in the options string.

	ReviewBoardURL = http://ocltc.amd.com/reviews/r/7266/diff/

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scStateSI.cpp#30 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#122 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpukernel.cpp#282 edit


[ROCm/clr commit: 05a3825964]
2015-04-02 16:37:11 -04:00
foreman a709ffc57e P4 to Git Change 1103884 by yaxunl@yaxunl_stg_win50 on 2014/12/09 15:30:25
EPR #405889 - Added option to set VGPR/SGPR/LDS usage in ISA to certain value greater than actual usage for debugging purpose. If the given value is smaller than actual value, this option has no effect.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scCompileSI.cpp#52 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/scHWShaderInfo.h#2 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#121 edit


[ROCm/clr commit: 9f760b7bf0]
2014-12-09 16:10:21 -05:00
foreman 04398ca890 P4 to Git Change 1092096 by yaxunl@yaxunl_stg_win50 on 2014/10/29 22:49:51
EPR #408439 - Add heuristics for setting SC register allocation strategy.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/amdil_be.cpp#40 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scCompileSI.cpp#47 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scCompileSI.h#18 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scStateSI.cpp#26 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/scState.cpp#33 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#120 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/amdilUtils.cpp#2 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/amdilUtils.hpp#2 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/InitializePasses.h#73 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/Transforms/IPO.h#29 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/include/llvm/Transforms/IPO/AMDKernelPerfHint.h#1 add
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Target/AMDIL/AMDILKernelManager.cpp#453 edit
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDKernelPerfHint.cpp#1 add
... //depot/stg/opencl/drivers/opencl/compiler/llvm/lib/Transforms/IPO/AMDPassManagerBuilder.cpp#46 edit


[ROCm/clr commit: a5d50f6926]
2014-10-29 22:56:55 -04:00
foreman 293853b84f P4 to Git Change 1091316 by yaxunl@yaxunl_stg_win50 on 2014/10/27 17:49:43
ECR #377625 - Function support: reduce number of private memory access by increasing argument promotion limit.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#119 edit


[ROCm/clr commit: c4abe32135]
2014-10-27 18:06:52 -04:00
foreman 484dff16aa P4 to Git Change 1085454 by yaxunl@yaxunl_stg_win50 on 2014/10/08 13:47:11
EPR #407056, #407061, #406980 - Back out changelist 1083545 since it causes a bunch of perf degradations. Will add a heurstics for -scras=2 for memory bound kernels only.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#118 edit


[ROCm/clr commit: d853eb5ebb]
2014-10-08 13:56:22 -04:00
foreman 6acd90b55c P4 to Git Change 1083545 by yaxunl@yaxunl_stg_win50 on 2014/10/02 11:58:08
EPR #402000 - [CQE OCL][Perf][QR] ~6-7% perf drop in CompuCL Benchmark (Graphics: T-Rex subtest).

	Enable -scras=2.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#117 edit


[ROCm/clr commit: 252525974e]
2014-10-02 14:53:40 -04:00
foreman 239faab75e P4 to Git Change 1079952 by yaxunl@yaxunl_stg_win50 on 2014/09/23 12:31:16
ECR #377625 - Workaround for Blender performance issue. Lower available VGPRs to improve waves per CU.

	Added BuildOptsAppend to OCL app profile.
	Read BuildOptsAppend and append to build options.
	Added specific wave optimization option for Blender.

Affected files ...

... //depot/stg/opencl/drivers/opencl/appprofiles/oclappprofile.xml#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scCompileSI.cpp#45 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#116 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/appprofile.cpp#10 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/appprofile.hpp#8 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/device.cpp#170 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/device.hpp#230 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuappprofile.cpp#10 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuappprofile.hpp#6 edit
... //depot/stg/opencl/drivers/opencl/runtime/platform/program.cpp#63 edit


[ROCm/clr commit: 16f8ca9aae]
2014-09-23 12:44:50 -04:00
foreman 10a5371f59 P4 to Git Change 1078026 by yaxunl@yaxunl_stg_win50 on 2014/09/17 21:51:23
EPR #402000 - Add option to control SC reg alloc strategy.

	[CQE OCL][Perf][QR] ~6-7% perf drop in CompuCL Benchmark (Graphics: T-Rex subtest).

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scStateSI.cpp#25 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#115 edit


[ROCm/clr commit: 478f10bc24]
2014-09-17 21:58:55 -04:00
foreman b3a2e596d3 P4 to Git Change 1077642 by yaxunl@yaxunl_stg_win50 on 2014/09/16 23:00:53
EPR #402000 - [CQE OCL][Perf][QR] ~6-7% perf drop in CompuCL Benchmark (Graphics: T-Rex subtest).

	Add option to disable SC merge memory loads and stores. By default it is disabled. Will decide whether to enable it by default after performance runs.
	cherrypick 1076590 and CL#1077419 from sc stg for adding option in sc.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/sc/Interface/SCCommon.h#42 integrate
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/sc/Src/CompilerBase.cpp#51 integrate
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/sc/Src/CompilerBase.hpp#35 integrate
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/sc/Src/HwUtils.cpp#36 integrate
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/scState.cpp#32 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#114 edit


[ROCm/clr commit: a49ebf6f6e]
2014-09-16 23:14:51 -04:00
foreman 7cafd57a3f P4 to Git Change 1075489 by marsenau@marsenau_ma on 2014/09/10 15:05:23
EPR #405194 - Change unroll threshold to LLVM default to partially work around Linpack performance problem.

	Prior to CL 1058428, which increased the unroll threshold to 200, this was only 100 which is lower than the LLVM default. Linpack's new ISA has increased register usage, but decreasing the unroll threshold to the previous level does not reduce the register count to its previous level. The increased register usage is probably a new SC problem, so this should probably be increased again in the future. There is no change in register usage with 100 vs. 150 on Linpack.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#113 edit


[ROCm/clr commit: d5f7502ca8]
2014-09-10 15:52:30 -04:00
foreman 7c5ee80511 P4 to Git Change 1075322 by smekhano@rampitec-HSA on 2014/09/10 11:07:04
ECR #333756 - HSA Finalizer: added runtime option to force buffer instructions for global access
	This can be used under ORCA RT.

	Testing: smoke, smoke_clang, precheckin, clbas dgemm
	Reviewed by Nikolay Haustov

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scStateSI.cpp#24 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#112 edit


[ROCm/clr commit: d35be99f01]
2014-09-10 11:25:14 -04:00
foreman 649664914e P4 to Git Change 1058428 by marsenau@marsenau_cl on 2014/07/23 14:39:25
ECR #304775 - Bug 10112 - Raise default unroll threshold. The current default is 100, which is even lower than the LLVM default of 150. Increasing to 200 is a modest increase, and this should probably be even higher.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#111 edit


[ROCm/clr commit: 2c5424663c]
2014-07-23 15:19:00 -04:00
foreman a17dac4537 P4 to Git Change 1055410 by emankov@em-hsa-amd on 2014/07/15 14:22:48
ECR #333753 - Compiler Lib: -print-compile-phases option is added

	Testing: smoke, smoke_clang, pre check-in

	Reviewers: Brian Sumner, Leonid Lobachev

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/v0_8/if_acl.cpp#37 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#110 edit


[ROCm/clr commit: b555ae7f64]
2014-07-15 15:00:01 -04:00
foreman 0d2632da70 P4 to Git Change 1055292 by yaxunl@yaxunl_stg_win50 on 2014/07/15 10:23:56
EPR #389586 - Add workaround for VI SPI SGPR initialization hardware bug for HSAIL path.

	There is a hardware bug in VI (UBTS502672) which requires a workaround. Compute shaders need to tell shader compiler the available sGPR is 78 and set sGPUR usage in the compiled ISA to be 94. It has been done in AMDIL path but not done in HSAIL path. This change will apply the workaround to HSAIL path.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/devStateSI.cpp#16 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/devStateSI.h#11 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/scwrapper/SI/scCompileSI.cpp#41 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#109 edit


[ROCm/clr commit: 1abfb8b305]
2014-07-15 10:29:49 -04:00
foreman f80f2f233c initial commit
[ROCm/clr commit: 3694ab2ce8]
2014-07-04 16:17:05 -04:00