Commit Graph

620 Commits

Author SHA1 Message Date
German Andryeyev e8b1e484f5 SWDEV-274199 - Enable SVM tracking
ROCr/KFD doesn't validate memory pointers. Enable validation inside
ROCclr, using SVM tracking mechanism.

Change-Id: I581e32ff37187f9ed8d9a302e8fd9f6ca935bdd7


[ROCm/clr commit: fbde61de7f]
2021-03-03 13:18:56 -05:00
Vladislav Sytchenko fe244055b7 SWDEV-1 - [PAL] Force luxmark to use HSAIL on gfx10+
Change-Id: I929d6d15365d3a6e9fd7eaed0b8b4910694f9504


[ROCm/clr commit: d8c1da5669]
2021-03-02 16:16:56 -05:00
Ravi C Akkenapally 1d842c07ec SWDEV-179105 - Stream Operations: Add feature querying support
Change-Id: I01cb85223b83f3655e5e21ad16639da406e5cd3e


[ROCm/clr commit: e94d482c8f]
2021-03-02 11:02:15 -08:00
Vladislav Sytchenko f22b6ede06 SWDEV-232428 - Fix typo from ac53942
Change-Id: Iec1f07e04ca3ae8ad72d38034bc136b59eb89dfe


[ROCm/clr commit: 8c4cf8c1b0]
2021-03-02 12:34:38 -05:00
Tao Sang e6bde7467e SWDEV-270973 - Add missing copyright headers
Change-Id: I6bb17650f74371dae6e29c59fd6bb2022cc062fe


[ROCm/clr commit: c1c5c89cd0]
2021-03-02 12:01:54 -05:00
kjayapra-amd 5ee300da46 SWDEV-270013 - Assign Kern_args segment only for gfx90a.
Change-Id: Icc890041eb27800cb78ef9e3d7bbe02658f53821


[ROCm/clr commit: a7abe44436]
2021-03-02 11:07:37 -05:00
German Andryeyev f6cc68deac SWDEV-272496 - Fix multiple timing issues
- Don't notify if the batch is empty, because that means
the current command was processed already.
- Disable pinning optimization to avoid a race condition on stall.
- TS marker submition requires extra AQL barrier
to track the status.

Change-Id: I17eff4ad12ac66cfe1bb44048bebb1891805279d


[ROCm/clr commit: 24299e25bd]
2021-03-01 12:46:57 -05:00
Alex Xie d82e14bf2c SWDEV-272382 - [OCL][LNX] OCLMemoryInfo[1] subtest of oclruntime is failing
1. Fix the size of the memory when releasing.
2. Make sure we only count the device memory

Change-Id: Ib4dcda79f313c4ee9cc1c7bab53f8076bce5f583


[ROCm/clr commit: 639d67866c]
2021-02-28 16:00:51 -05:00
Vladislav Sytchenko 3cd2c487d3 SWDEV-193973 - Enable HSAIL for all Navi Asics
Change-Id: I0a48442f9a970de3d449e512293bc4600c62db13


[ROCm/clr commit: 4e1232a110]
2021-02-26 11:56:09 -05:00
Vladislav Sytchenko cae2f29c10 SWDEV-86035 - [PAL] Correct allocation logging
Since the allocation can be a suballocation, we should print both the
VA range for the allocation and the underlying memory object.

Change-Id: Ic9c707bbb78113b366d1b2c688e6fd33bdc8fd94


[ROCm/clr commit: 9e8a2f3266]
2021-02-24 11:35:49 -05:00
kjayapra-amd d26aceba19 SWDEV-274058 - Porting HIP, ROCclr gfx90a changes to mainline.
Change-Id: I4f4220df77e57f749a00c1dbb66743ac5af4959a


[ROCm/clr commit: 46a50965c4]
2021-02-24 09:55:54 -05:00
Jason Tang 09259cd49f SWDEV-198364 - Only enable clgl sharing in ROCm path when building LinuxPro
Change-Id: Ie4d87e252519d090a62b930f7ebb315d3477b690


[ROCm/clr commit: 54a7170e40]
2021-02-23 14:15:04 -05:00
Vladislav Sytchenko dfdb975c7d SWDEV-270013 - Fix uninitialized variable warning
Change-Id: Ic4c8090e94e82798c294ac4532ca20efbc5a3a54


[ROCm/clr commit: c93f66a5ec]
2021-02-23 11:49:28 -05:00
Vladislav Sytchenko c122c28e5d SWDEV-86035 - [PAL] Propagate gl2Uncached setting to the backend
Change-Id: I594f304a20d448fe198ec27901e6c97b265c1183


[ROCm/clr commit: dbcf023cb1]
2021-02-21 13:52:38 -05:00
Vladislav Sytchenko 007671faf8 SWDEV-86035 - [PAL] Fix runtime init
The settings need to be populated ASAP, otherwise the dummy context is
not created properly.

Change-Id: Iede0066308bb601dc68164e894775a646a0372f1


[ROCm/clr commit: 263173914f]
2021-02-20 16:39:13 -05:00
German Andryeyev 33c1e3d14d SWDEV-272496 - Wait on CPU before switching to GPU wait
GPU waits have noticeable overheads on compute with extra
AQL barrier packet and on SDMA with power saving features. This
change introduces a wait on CPU for 30 us in case the app has tiny
operations.

Change-Id: I761ba3af595f3f48544980058a9077dda15aa5f9


[ROCm/clr commit: ac387f9b03]
2021-02-17 15:19:17 -05:00
Vladislav Sytchenko 086bdf83b4 SWDEV-232428 - Push hostcall implementation to the device layer
This change unifies the hostcall implementation for all the backends,
by pushing the common logic to the device layer. This is done by
replacing the use of hsa_signal_t with device::Signal (a light wrapper
around it).

Change-Id: I7b6fca7930b5a0b199da5d85e2e048354cc04e7b


[ROCm/clr commit: 671778bdd3]
2021-02-16 17:19:57 -05:00
Jason Tang ac06dab550 SWDEV-265304 - Disable GFX8 in LinuxPro ROCr build
Change-Id: Ia26bb025a133a4acb255a539a45668975019cc6e


[ROCm/clr commit: c65be06c4c]
2021-02-16 13:32:47 -05:00
Vladislav Sytchenko 42c3dc5c6e SWDEV-271486 - [PAL] Temporarily disable reporting sramecc support
Change-Id: I089af8f8a4645ce5353f351dbf3a018cd31df216


[ROCm/clr commit: ac237ac094]
2021-02-16 10:39:18 -05:00
Vladislav Sytchenko 27fea99659 SWDEV-270013 - Fix Windows build
Change-Id: I9573ef8b9d94367b8fa1dd90d40a93ddc4992f18


[ROCm/clr commit: 660e543f49]
2021-02-16 10:03:51 -05:00
Ravi C Akkenapally 6629930067 SWDEV-179105 - Stream Operations: Add support for Wait and Write
Change-Id: Ibffa1d6d573826b64763da280074a77271d66808


[ROCm/clr commit: 0a5f9a3b10]
2021-02-15 17:02:38 -08:00
kjayapra-amd 4583cbafee SWDEV-270013 - Allocate kernel_arguments from kern_arg & finegrain pool instead of coarse grain.
Change-Id: Id4c6977934fdd6ef2311f6e75593801f1e51983c


[ROCm/clr commit: 2df099df9e]
2021-02-15 18:20:08 -05:00
German Andryeyev 64360211fe SWDEV-86035 - switch PAL interface to 656 version
Change-Id: I162ba6e49aa866c013f37a114df5bb7ea3e08874


[ROCm/clr commit: 70f06c79fa]
2021-02-12 13:08:59 -05:00
German Andryeyev b5e80a048a SWDEV-86035 - Enable PAL for gfx8
Change-Id: Ia6623993e44aeb4bdf317628ee8a84af6c4cacc7


[ROCm/clr commit: e7c636c5e7]
2021-02-11 14:25:43 -05:00
Payam 72b49f0800 SWDEV-257937 - Updated fix for ROC_BARRIER_SYNC=0
Change-Id: I7e28e541b654db57fb0890d7dbb7519cfb2d93db


[ROCm/clr commit: a2e0b0495c]
2021-02-11 14:01:45 -05:00
German Andryeyev 1ac2b818e6 SWDEV-271806 - Disable pinning for views.
Only parent object should pin system memory

Change-Id: Ic9a0a34e3aff2263501c564c3cebd33f4f7e2455


[ROCm/clr commit: fb142e7b2f]
2021-02-11 13:05:58 -05:00
Vladislav Sytchenko 4f2684594f SWDEV-252745 - Fix uninitialized variable
Change-Id: I9167dc3c85779771a44626f2f88eec4134c5a5ad


[ROCm/clr commit: ee1ec3258d]
2021-02-11 10:26:38 -05:00
Rahul Garg ff35f82881 SWDEV-271182 - Fix HdpMemFlushCntl and HdpRegFlushCntl
Change-Id: Ib690b475c2c4514c862ded5fc2bdd1049e27bd46


[ROCm/clr commit: df0b14ff47]
2021-02-10 11:40:35 -05:00
cjatin 43a470093d SWDEV-252745 - Adding precompiled headers to build option
Change-Id: Iab03e8a75215d80c91817ee0227d034fefa9dfad


[ROCm/clr commit: 5cfea2981b]
2021-02-09 23:33:55 -05:00
German Andryeyev e60c7aa890 SWDEV-269654 - Fix HIP stream busy query
- Avoid GPU wait on the marker submission and update the command
batch after HSA signal callback upon HSA barrier completion.

Change-Id: I5c1c97212aefc2ae4b99aa9e2a81627ee9a38c1c


[ROCm/clr commit: 6966d8098e]
2021-02-09 12:57:12 -05:00
Vladislav Sytchenko ac5394299f SWDEV-232428 - Use std atomics
Change-Id: Ieca85738621d056e612faf4de1e2011a817b8965


[ROCm/clr commit: 738fd1d24b]
2021-02-08 16:50:41 -05:00
Alex Xie c490930624 SWDEV-268914 - Linux, AMF, tests fail to scale images down
In pitch workaround, we need to copy the image to copy buffer
when application wants to read image to buffer. After this
patch, we unconditionally copy the image data to the copy buffer.

Change-Id: I71b0d19459542dfbb3ca51a2c8a3a81367fa2fb5


[ROCm/clr commit: 5330679473]
2021-02-01 15:22:15 -05:00
Joseph Greathouse 62fee66ff2 SWDEV-270773 - Fix workgroup calculation logic for GWS initialization
The existing workgroup calculation logic for GWS initialization is
incorrect. It tries to add together workgroups across dimensions,
leading to major under-count in 2D and 3D kernels. An (x,y,z) kernel
uses x * y * z blocks, not x + y + z.

In addition, the previous logic was incorrect for the case of launching
a single-threaded kernel. It calculated 0 workgroups, leading to
initializing GWS to -1.

Change-Id: I1bb20a0d5b6e0cc10ac55901c28d8f93aac61c09


[ROCm/clr commit: 54d1d69c0a]
2021-01-31 01:16:48 -06:00
Saleel Kudchadker 7a08212ce1 SWDEV-257787 - Add log for tracking copy signals
Change-Id: I713e8463916a85a634a1ec2309bbd46a11c461a8


[ROCm/clr commit: 629a2d8ef3]
2021-01-28 13:25:49 -05:00
Vladislav Sytchenko 95655fd5fd SWDEV-268186 - [PAL] Enable MALL for persistent allocations
Change-Id: Ibc21255d5be52289cb4de3de7d12e0415fd1bc91


[ROCm/clr commit: 0d0739a39b]
2021-01-28 12:47:18 -05:00
Vladislav Sytchenko b8ce1cc059 SWDEV-1 - Update ISA table
Disable gfx9+ for GSL.

Enable gfx9+ (except MI100/200/300) for PAL.

Change-Id: Ic5a238af939e1d8795503aae39df6a6ece50a9d2


[ROCm/clr commit: 81e331dc42]
2021-01-28 11:26:22 -05:00
kjayapra-amd 4693ecf345 SWDEV-270013 - Adding code to differentiate between kern_arg + fine_grain and fine_grain segment of system memory.
Change-Id: Id0404b2dab8561946ad0a90a77030582f7e021a4


[ROCm/clr commit: 85fafb0561]
2021-01-28 09:48:17 -05:00
German Andryeyev f96e973378 SWDEV-257787 - Add engine tracking per signal
- The logic will trace compute, sdma read/write operations and
apply signals when necessary
- ROC_CPU_WAIT_FOR_SIGNAL, ROC_SYSTEM_SCOPE_SIGNAL
and ROC_SKIP_COPY_SYNC were added to control the tracking

Change-Id: I9e8e6174c63bf7784f7ab00964e2918c8667d364


[ROCm/clr commit: dbc7abaecf]
2021-01-25 12:34:45 -05:00
Jason Tang 6fb4972c65 SWDEV-269147 - Disable ROC offline devices for now
Change-Id: I520f3c8e56db91cbc384d08beba4e0bd4626941d


[ROCm/clr commit: 1e08a3e0cd]
2021-01-23 14:48:07 -05:00
German Andryeyev 1d26696235 SWDEV-257787 - Reset active signal if ROCR call failed
- ROCR fails the call for some reason, then the signal will
become invalid and can hang on a wait. The logic will reset the
active signal in such cases

Change-Id: Ia131420200f1bbd7c9a162b8f1b06db8cecf41c6


[ROCm/clr commit: ce2e5eba6b]
2021-01-21 17:29:34 -05:00
German Andryeyev 1086195745 SWDEV-268381 - Enable wait on CPU before SDMA transfer
- There is a performance regression with a HW wait for HSA signal
on ROCr async operation. For now move the logic back to CPU wait.

- Fix profiling issue with multiple HSA signal per single timestamp
object. Some copies require multiple ROCR calls and if profiling is
required, then the execution time is derived from all used signals.

Change-Id: Id003e4abb8c2de378eedc152a7e389500fc6f4ce


[ROCm/clr commit: 5a8946190a]
2021-01-19 18:24:21 -05:00
Tony Tye a05c745d54 SWDEV-268864 - Remove duplicatation of isa related information
Remove targetId_, gfxipMajor_, gfxipMinor_ and gfxipStepping_ from
device::Info as they are now available in device::Isa.

Change-Id: I381b1d4798ebf50655740e004a01ac7f86dbf668


[ROCm/clr commit: c2308216dd]
2021-01-18 22:32:37 +00:00
Jason Tang 3b5b0175ac Fix build error when building with clang++
Change-Id: If1c9fbd6af6028bd39ff43ee53d74d5e778e2a27


[ROCm/clr commit: c0730b69d5]
2021-01-18 09:45:19 -05:00
Jatin Chaudhary 3dc9013e52 Adding compiler option to be passed to comgr
Change-Id: I6247cfc8f323e7ccbc95e35408ab3e8a55e16495


[ROCm/clr commit: 9943fcd81b]
2021-01-18 06:25:44 -05:00
Saleel Kudchadker fff9c7f413 Cleanup redundant Barrier packet fill function
Change-Id: I31f3250f00a362c2fdd35aca31df177fed7ddb98


[ROCm/clr commit: ce56d04dee]
2021-01-14 12:38:00 -05:00
Tony Tye 38744069df Make HSAILProgram::gpuNullDevice private
Change-Id: I822d1800eff0703a154dac997fe940d232eab542


[ROCm/clr commit: 2026a24438]
2021-01-14 11:12:14 -05:00
Tony Tye 902cf1a239 Update code object handling for GSL, PAL and ROCm
- Correct GSL path to report targets using the TargetID syntax.

- Correct GSL path to check compatibility of code objects when
  loading.

- Add concept of an device isa and create a registery used by ROCm,
  PAL and GSL.

- Support XNACK and SRAMECC target features consistently for PAL and ROCm.

- Correct logic for NullDevices and asserts to avoid memory coruption.

- Allow all NullDevices to be created for HIP.

- Numerous other code improvements.

Change-Id: I40abf3d2b22249c1492d1af5919665f8184f4e0e


[ROCm/clr commit: c7e8d91e14]
2021-01-14 11:11:51 -05:00
Tony Tye 44c3b775a4 Use strncpy
Use strncpy instead of strcpy to ensure the arrays will not be
overflowered. Only copy one less than size of char array to leave a
NUL character at the end even if the copy is truncated provided the
original object is zeroed memory.

Change-Id: I00f7679630cf28dcb9a51cb0aba2810a4f4c72b9


[ROCm/clr commit: e0448535a3]
2021-01-13 08:24:28 +00:00
Tony Tye 2476472bcb Make hsa_agent_t handles use pointer to device::Device
For roc devices create hsa_agent_t handles using a pointer to the
device::Device. This ensures each device has a different hsa_agent_t
handle. This may be necessary to ensure the loader symbol lookup will
search only symbols for the correct device.

Change-Id: Iee6dd40d68bf22a02ce8c75cbe5ac8f5a0d9e418


[ROCm/clr commit: 76c371d78a]
2021-01-13 08:24:28 +00:00
Tony Tye 4bfc88db5f Simplify handling of Settings
roc:Settings and pal::Settings are derivations. Allocate them as their
derived class then assign that to the base class member to avoid the
need for a static_cast.

Use device::settings to access the Settings consistently.

Change-Id: I0f85157962fbf6fed176da0caf83b723bcbe1452


[ROCm/clr commit: 583dddf6b6]
2021-01-13 08:24:28 +00:00