Граф коммитов

14 Коммитов

Автор SHA1 Сообщение Дата
agunashe d96481fb36 SWDEV-293742 - Update copyright end year VDI repo
Change-Id: I69d2fea4a7a43adf96ccea794270e4af991c5261
2021-08-22 23:56:07 -07:00
Tony Tye e0448535a3 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
2021-01-13 08:24:28 +00:00
Vladislav Sytchenko 29efce7520 Add missing include
Change-Id: I21683ddb981581a0456ad0aa79843a44422a6ab0
2020-09-12 20:16:09 -04:00
Laurent Morichetti 5d4b6f74d3 Use std::atomic
Replace amd::Atomic with std::atomic. Remove make_atomic uses by
converting the variable to std::atomic and making sure the memory
order is relaxed when synchronizes-with is not needed.

Delete utils/atomic.hpp.

Change-Id: I0b36db8d604a8510ac6e36b32885fd16a1b8ccfa
2020-09-09 14:55:29 -04:00
Laurent Morichetti 5079410c94 Periodically wake up the thread in monitor::wait
There is a small window where a thread can go to sleep in
Monitor::wait after releasing the lock but before another thread
notifies the monitor and updates the on-deck thread.

A simple approach to fix this problem is to wake-up the Monitor::wait
every 10 milliseconds and check if it is on-deck.

Change-Id: I4b9abda89d1fc653cdae2b4c84cdda01efde1cf2
2020-09-01 18:09:38 -04:00
Laurent Morichetti f10435a1ef Add missing storeload memory fences
There is no synchronize with relationship between the monitor micro-
lock and the onDeck microlock, so it is possible for an onDeck.load to
move above a contendersList.store, or a contendersList.load to move
above an ondeck.store.

To fix this issue a full memory fence (mm_mfence on x86) is needed
after the last store in the contendersList and onDeck critical regions.

Change-Id: I5beb7dfe0d21010c5bf00cd65d59b9c7af58e919
2020-08-24 18:03:37 -04:00
Tao Sang fdef6f722f Apply constexpr on global constant varaibles
When HIP_ENABLE_DEFERRED_LOADING=0, many global variables will be
referenced but they are not initialized in that early time. The patch
will use constexpr to initialze global constant varables in compile
time.

Change-Id: I9d538b7abc6a0ce700ec3332b97fc144db5fc1ef
2020-07-22 22:14:13 -04:00
Matt Arsenault a9ffa384e8 Use alignas to effectively define padding and fix 32-bit build
Change-Id: Ib318d2fe847625567de93c9268cf000ec35a921f
2020-07-21 10:53:47 -04:00
Matt Arsenault 51f4aa305b Fix -Wunused-private-field
Change-Id: Ib60e8dc2625c0c5e10fa109e452af0bc6174e763
2020-07-20 11:23:18 -04:00
Matt Arsenault 2f3e9afab7 Fix windows build
Change-Id: I0c5fff636ec43d5c1daf888457f77ef214a29566
2020-07-16 17:08:22 -04:00
Matt Arsenault dabda131bd Correct total size of Semaphore to be 64
Change-Id: I20db76eab06fc8a0b3869348c537e7303dfa6466
2020-07-15 16:51:19 -04:00
Payam 1b6f21ad9a removing AMD emails per palamida scan
Change-Id: If7307f5b1f81a43f2725ec5abd3b8989cbddbcc5
2020-03-11 21:26:55 -04:00
Laurent Morichetti b4c6143a2f Update copyright info
Change-Id: Ia4f9ff0f5f873b4223a8cca154188bb0d2f1abba
2020-02-04 09:26:14 -08:00
Laurent Morichetti 20c7173849 Merge branch 'origin/pghafari/vdi-prototype' into lmoriche/amd-master
Change-Id: Id3b833d405596735becb3346f3b08c6da57033fe
2020-01-30 20:12:13 -08:00