Commit Graph

64 Commits

Author SHA1 Message Date
Mateusz Jablonski 92bfd2e3d2 Move OsContext to Device
Change-Id: I030b65372fbdc075423d22720e9da34ac65b8e68
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2018-09-03 10:42:26 +02:00
Dunajski, Bartosz 118bad16df Dont add PIPE_CONTROL between Walkers for TimestampPacket writes
Change-Id: I6216a0926678c7f7a997cb37ce4eb59f914b518e
Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
2018-08-30 15:30:16 +02:00
Chodor, Jaroslaw ad9710bec2 Refactor around binding table programming
Change-Id: I4cad63b11937531e36ea9d92cee606ea8941c9ef
2018-08-29 14:35:52 +02:00
Maciej Dziuban b91c14f70e Delete Device::getBuiltIns()
Change-Id: I9d1968dfb2ba4a56020fd17152119add726106e1
Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com>
2018-08-22 16:54:53 +02:00
Maciej Dziuban e0e48203d2 Move BuiltIns to ExecutionEnvironment
Change-Id: Ib2a1b82cc7858c898bb32820aad106a01d1325ad
Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com>
2018-08-21 23:15:47 +02:00
Stefanowski, Adam 1ad70dfebe Decouple memory manager and device
Change-Id: Ia64cc955e1d290cad4c50b6a2a41052d9acf0eec
2018-08-20 13:44:31 +02:00
Mrozek, Michal 1599ea800e Pass execution environment to command stream receiver.
Change-Id: I598f67f8b005b5ce8249b638e080657eb6dc3547
2018-08-08 17:10:39 +02:00
Stefanowski, Adam 4df9cf638f Remove device use by memory manager
Change-Id: Ia9dffb322d7b9f96e5698eb85fcff22a60051f74
2018-08-07 10:58:15 +02:00
Mrozek, Michal d80dbb1ae0 Do not take ownership on device.
- Command Stream Receiver should be used instead for locking.
- Remove not needed synchronization in clSetUserEventStatus

Change-Id: I17050dc70cb0be03b2003043a9666ba8df1a83c9
2018-08-07 09:29:50 +02:00
Mrozek, Michal 6f251f5ea1 Fix TBX completion loop.
- resources are dumped in make non resident call
- in order to dump correct data we need to be sure that GPU is done processing
- waiting needs to be unconditional to handle all cases
- remove not needed parameter to makeSurfacePackNonResident

Change-Id: Ib2b065d486cd3a5d86e599c51b24f3c958c3a10b
2018-08-03 09:32:24 +02:00
Mrozek, Michal f60847b64e Pass device to flushTask.
- do not obtain it from memory manager

Change-Id: Icc7c03dc925c69ec5932c5812151ac28dc34d20d
2018-08-01 14:11:06 +02:00
Hoppe, Mateusz 4441387969 Refactor allocateGraphicsMemoryInPreferredPool
- extend AllocationType to code necessary flags
- remove redundant args
- refactor Buffer::create()

Change-Id: Ic4b2e0931fad8198ad1cf4f79de210d815048ccf
2018-07-31 08:05:55 +02:00
Mateusz Jablonski a906ddaa66 Make gmm client context non-static member
Construct platform and initialize gmm in each test

Change-Id: I4f209369e77213420308f31f911b7a569ea93283
2018-07-27 00:16:30 +02:00
Zdanowicz, Zbigniew 51421ec0b9 Add experimental command buffer
This code is an infrastructure for special debug purpose that allow measure
execution time of any hardware command.

Change-Id: Id12a7979d204734a0c4a6c4700e427b65ac2397f
2018-07-13 12:09:14 +02:00
Hoppe, Mateusz 55a045ebe1 Refactor graphics memory allocation scheme
- replace createGraphicsAllocationWithRequiredBitness with more general
methodallocateGraphicsMemoryInPreferredPool based on passed
 AllocationData
- proper flags for allocation selected based on AllocationType

- remove allocateGraphicsMemory(size_t size, size_t alignment)
and use allocateGraphicsMemory(size_t size) instead where default
alignment is sufficient, otherwise use full options version:
allocateGraphicsMemory(size_t size, size_t alignment,
 bool forcePin, bool uncacheable)

Change-Id: I2da891f372ee181253cb840568a61b33c0d71fc9
2018-07-11 15:48:05 +02:00
Hoppe, Mateusz 64277ee849 TBX CommandStreamReceiver fix for makeCoherent
- makeCoherent should be called after TBX finished processing
 - this is when tagAddress is updated with taskCount
makeCoherent is called from makeNonResident which is invoked just
after flush and may happen before TBX server finished processing
leading to invalid data to be read back to CPU accessible memory

- this fix adds waiting for taskCount to blocking calls for TBX CSR
before calling makeNonResident on surfaces to guarantee correct data
from TBX server is ready.

Change-Id: I498a5454e0826eec2a5413a08880af40268550e1
2018-07-04 12:04:32 +02:00
Milczarek, Slawomir eb1b5ded9c Add support for AUB subcapture (filter and toggle modes)
This commit adds a capability to selectively enable/disable AUB capture,
i.e. by toggling the registry key from the outside or specifying the filter
with a kernel name and/or kernel start index and kernel end index.

Change-Id: Ib5d39c21863fbc4a95aa73c949b9779ff993de0f
2018-06-15 13:02:27 +02:00
Dunajski, Bartosz bd16f4bf2b Improve scratch allocation size calculation
Change-Id: I627bea89ce31e7110976cb88f9e9266e08af590a
2018-06-06 16:27:48 +02:00
Hoppe, Mateusz a1a224c3bc Add Clear SLM workaround for BDW
- set ProtectedMemoryDisable in PC prior to setting new L3 config

Change-Id: I2ecbfe9535ef45159b48fffa41faad66db55d074
2018-05-21 14:29:17 +02:00
Maciej Dziuban 41f570ab50 Fix overestimation of MediaVfeState in CommandStreamReceiver
Change-Id: I38fd00f6b994f6a62921bcc09f293cabc95773d4
2018-05-15 11:13:20 +02:00
Hoppe, Mateusz 47f1abe543 Source Level Debugger fixes
when SLD is active:
- make Sip Kernel Resident
- program GPGPU_CSR_BASE_ADDRESS
- Disable Preemption

- adjust getDebuggerOption input param,
value passed has to be at least 2 bytes in size
change unit test behaviour accordingly

Change-Id: I4ec87d0e8dfcf02437fdeeffc5363314eea5dd07
2018-05-14 15:51:32 +02:00
Maciej Dziuban 749d89a9bf L3 programming refactor 4/n
- Fix overestimation of preemption programming in preamble

Change-Id: I4ddfc6a2dacbe1160c68cdcef08125a5d5e74835
2018-05-14 15:39:28 +02:00
Maciej Dziuban 44d35b3534 L3 programming refactor 2/n
- Rename misnamed test function
- Adjust 2 tests, so they use CSR size getters instead of hardcoded values
- Move getSizeRequiredPreambleCS() into CommandStreamReceiverHw class
- Improve PreambleHelper size estimating

Change-Id: I3f292d50e08f3d10d190c9f8722e1f0498481154
2018-04-27 13:10:28 +02:00
Pawel Wilma a0c044e6d2 Extend batch buffer flattening in AubCSR to BatchedDispatch mode
- batch buffer flatening in batched mode
    - added MI_USER_INTERRUPT command
    - added GUC Work Queue Item

Change-Id: I35142da34b30d3006bb4ffc1521db7f6ebe68ebc
2018-04-26 12:45:02 +02:00
Maciej Dziuban 1392b79b58 L3 programming refactor 1/n
- Clean up size estimation functions
- Make some tests gen specific

Change-Id: If9c15f311306282ba035b380e6d4cadc17584815
2018-04-20 22:34:35 +02:00
Mrozek, Michal 59df78cc18 [32/n] Internal 4GB allacator.
- Ensure that heaps passed as IndirectHeap to flushTask

Change-Id: Ib633e3d3027e142a1fdb51e78b970fb1bd1b9b0c
2018-04-18 08:49:08 +02:00
Koska, Andrzej b0a6d9131a Making DSH and IOH always resident
Change-Id: Ib114b92cb5ee153f213c15c935f8f1d1cfeb46eb
2018-04-13 12:35:15 +02:00
Dunajski, Bartosz acf97999f3 Force Kmd Notify timeout for Windows machines running on battery
- This is to improve battery usage while waiting in busy loop on CPU
- New Kmd Notify helper to maintain dynamic parameters
- Ask OS about battery status on longer waits
- Pick different timeout when using battery and optimization is disabled

Change-Id: I5f9c8c5a9c635652aac27c707f2b55933947a7fb
2018-04-12 10:03:10 +02:00
Dunajski, Bartosz 87f8f735f9 Move KMD Notify logic from CSR to specialized helper
- Decission about timeout enabling and value moved out of CSR
- Timeout multiplier is no longer Linux specific

Change-Id: I6858fe2f811ef13802b95e0470e310210a9dea8b
2018-04-10 08:16:11 +02:00
Hoppe, Mateusz 9a86f86a24 Source Level Debugger device debugger active flag
- device flag indicating if debugger is active
- when active, proper sip kernels must be used

Change-Id: I678367cdf8fab5d4b5770e3f471246ff6d6bd112
2018-04-09 14:02:45 +02:00
Zdanowicz, Zbigniew b6b92ae808 Create GpgpuWalkerHelper class
Change-Id: Ia9aa7b816356aff57234b46ea3509b6bd9b7f14b
2018-04-04 16:42:16 +02:00
Dunajski, Bartosz 8505658cab Multiply wait timeout by task count difference
- Linux specific
- Use only for non-quickSleep requests

Change-Id: I245546f83672d128377e51d92b6c7708a7448f05
2018-03-30 12:50:38 +02:00
Mrozek, Michal 9bdf01468e [20/n] Internal 4GB allocator.
- Switch to internal heap for kernel ISA allocations.
- remove IH from various functions
- remove IHState from CSR , IH is never dirty
- ISA is no longer copied on enqueue calls.

Change-Id: I0099cf2a9ebab6192ea03a74dd35f7da963fd5a5
2018-03-28 16:07:26 +02:00
Mrozek, Michal 3958cd909a [18/n] Internal 4GB allocator.
- Remove IH from preemption functions.
- This is one of parts of complete IH removal.

Change-Id: Ic19a6e2e1f5d9df25785c2c982c52b581b57a605
2018-03-27 11:19:47 +02:00
Pawel Wilma ff1d2361f3 Add patch info comments to AUB dump
Collect patching information and add as comments to AUB dump.

Change-Id: Ib7c903a2589d68b6e3e614c1774c7cd5a000c29f
2018-03-23 13:08:54 +01:00
Mrozek, Michal d7fe01454b Make sure that gtpin callbacks are not executed in enqueue path.
-This is to make sure those functions are not called when gtpin is not used
-This preserves CPU instruction cache pollution.
-Our enqueue path needs to be as thin as possible, even with this small change
there is visible gain in ULT execution time.

Change-Id: I44cc2144754cda95ca1fe058184cd8a151b8d35c
2018-03-23 12:54:17 +01:00
Dunajski, Bartosz 93cb7be091 Kmd notify improvements [3/n]: Fix sporadic in ULT
Change-Id: I1e326e7514d4d7d14cb1051b50105cbc418e325c
2018-03-23 10:50:42 +01:00
Dunajski, Bartosz 9486dba6dd Kmd notify improvements [2/n]: Use QuickKmdSleep for sporadic waits
- Measure time between wait calls. If delay is exeeded  use QuickKmdSleep
- Kmd Notify helper functions
- Refactor overriding from debug variables
- Refactor Kmd Notify tests


Change-Id: I123c31f492d98fd304184f99ee0bf7d733d06f04
2018-03-22 17:09:16 +01:00
Dunajski, Bartosz 516082e7c5 Kmd notify improvements [1/n]: Quick KMD sleep optimization
- KmdNotifyProperties struct for CapabilityTable that can be extended by
  incoming KmdNotify related optimizations
- Quick KMD sleep optimization that is called from async events handler
- Optimization makes a taskCount check in busy loop with much smaller
  delay than basic version of KMD Notify optimization

Change-Id: I60c851c59895f0cf9de1e1f21e755a8b4c2fe900
2018-03-21 20:41:33 +01:00
Dunajski, Bartosz c0d3eade30 Disable wait timeout when flushStamp is 0
Change-Id: I416ace1f8c1a3e5aa91d9bc2425a4faa77e2fbe7
2018-03-15 15:44:17 +01:00
Mrozek, Michal 00ae077913 [14/n] Internal 4GB allocator
- call make resident on sip kernel allocation.

Change-Id: I9c9af5ed4cec3e8b05decac7228658358ef1562b
2018-03-13 10:29:50 +01:00
Mrozek, Michal 8254d6a081 Ensure that submissions are flushed prior to csr destruction.
Change-Id: Ie04de561d3d295f40f55a19f01274d873d259abd
2018-03-12 12:54:47 +01:00
Pawel Wilma c4c35955d1 Debug option to flatten main and chained batch buffer in AUB dump.
New debug option FlattenBatchBufferForAUBDump has been added. When set it
modifies AUB dump in such way that commands from main and chained batch
buffer are dumped as single allocation. Commands from chained batch buffer are
dumped directly after commands from main batch buffer without
MI_BATCH_BUFFER_START. This feature also requires ImmediateDispatch mode which
can be forced using debug option CsrDispatchMode = 1.

Change-Id: I730760791693a748e7f4e1463ce8e7af94287b93
2018-03-06 12:26:50 +01:00
Mrozek, Michal 1602fa5a88 [7/n] Internal 4GB allocator
- rename getBase to getCpuBase
- change some test names accordingly.

Change-Id: I6fb2e4714298250147ea7766a916d7f5d62edc54
2018-03-05 22:16:14 +01:00
Mrozek, Michal cd747b7b8c Change notify delay to use microseconds.
- Microseconds offer better precision.
- Some workloads require threshold less then 1 millisecond to work
efficiently.

Change-Id: I1a565049340fb6eeebe5c0a61ededae9959daca8
2018-02-27 09:10:49 +01:00
Dunajski, Bartosz 1292c3d533 Improve thread arbitration policy programming
Change-Id: Ibd764352e14d1a5112034b1c5a1fc6d6d67ebac0
2018-02-20 11:05:54 +01:00
hjnapiat 5909a6b3d3 Add support for GT-Pin Callbacks [3/n]
Change-Id: Iea4b49efc9a666fde310ece15a9c69686d22f627
2018-02-19 10:43:19 +01:00
Dunajski, Bartosz 87ed3d4fff Improve page table manager initialization
Change-Id: Ifdd74bf93a93fcdecaae5b1276c0fa83a9664987
2018-02-15 13:31:50 +01:00
Mrozek, Michal acb044dce3 Fix DC flush programming in non concurrent scenarios.
-If out of order flag was disabled then pipe control was not having dc flush.
-This could led to a batch buffer that doesn't end with dc flush.
-This change adds differentiation between pipe controls that may be erased and
pipe controls that are used as a part of epilogue command

Change-Id: Ic9c970c75c89ff524a0e40506eff6dd097760145
2018-02-15 09:42:11 +01:00
Mrozek, Michal 82a2afb611 Improve DC flush handling.
-Do not flush dc for every command in batched mode
-Do that only in immediate mode
-For commands that needs DC do not noop pipe controls
-Ensure that each command buffer in batching mode ends with dc flush.

Change-Id: I3cd9d1831c19b69c66092687922f20df7e330245
2018-02-13 11:37:11 +01:00