rocr: Use view3dAs2dArray flag, for thick/3D swizzle modes.
Added HSA_IMAGE_ENABLE_3D_SWIZZLE_DEBUG environment flag to
enable/disable this. Default value is false (view3dAs2dArray = 1)
Enabling this flag will enable support for swizzles that do 3D
interleaving. Note that all features of 3D images are supported
with 2D swizzles,it's just that the access patterns are different
and therefore cache hit-rates may be better or worse, depending
on how it's used. Volumetric algorithms do better with 3D and apps
that tend to access a single slice at a time do better with 2D.
Change-Id: Id8574a6710fe4333a1ee331e5ce9195a81434198
[ROCm/ROCR-Runtime commit: 6361466baa]
This commit is contained in:
@@ -273,6 +273,9 @@ class Flag {
|
||||
else
|
||||
fprintf(stderr, "Failed to parse HSA_ASYNCEVENTS_THREAD_PRIORITY");
|
||||
}
|
||||
|
||||
var = os::GetEnvVar("HSA_IMAGE_ENABLE_3D_SWIZZLE_DEBUG");
|
||||
enable_3d_swizzle_ = (var == "1") ? true : false;
|
||||
}
|
||||
|
||||
void parse_masks(uint32_t maxGpu, uint32_t maxCU) {
|
||||
@@ -391,6 +394,8 @@ class Flag {
|
||||
|
||||
int async_events_thread_priority() const { return async_events_thread_priority_; }
|
||||
|
||||
bool enable_3d_swizzle() const { return enable_3d_swizzle_; }
|
||||
|
||||
private:
|
||||
bool check_flat_scratch_;
|
||||
bool enable_vm_fault_message_;
|
||||
@@ -423,6 +428,7 @@ class Flag {
|
||||
bool dev_mem_queue_;
|
||||
uint32_t signal_abort_timeout_;
|
||||
int async_events_thread_priority_;
|
||||
bool enable_3d_swizzle_ = false;
|
||||
|
||||
SDMA_OVERRIDE enable_sdma_;
|
||||
SDMA_OVERRIDE enable_peer_sdma_;
|
||||
|
||||
Reference in New Issue
Block a user