Commit Graph

63 Commits

Author SHA1 Message Date
Ammar ELWazir 935b40b837 Fixing Multiple Profiler Issues:
1- Fixing Output Buffer Issues
2- Metrics Instances created for all GPUs in Init
3- Multi CPU/GPU/KernArg Pools are initialized for every Agent in Init
4- Lowering OverHead in the Packet WriteInterceptor in the ProxyQueue for both Profile Counting & ATT

Change-Id: Ic3d78156af8405bb134d01584574c339237d265f


[ROCm/rocprofiler commit: 00ecca25c7]
2023-05-30 21:41:54 -05:00
Ammar ELWazir d206ec0bf0 Fixing Rebase Issues
Change-Id: I69d6c9fd8f8a05951b543f30195de87dc993e5b7


[ROCm/rocprofiler commit: 720f2fd9df]
2023-04-11 03:56:46 +00:00
Ammar ELWazir 331cdb5011 Fixing rocprofilerv2 naming and CMake issues
Change-Id: Ib6d336349a056731e5c0f35151296d6fea671360


[ROCm/rocprofiler commit: a5e1069920]
2023-03-29 15:55:05 +00:00
Ammar ELWazir 5a3d089c3a SWDEV-379553: Fix for counters
Change-Id: I65b9bf61c6fc288f95461981979699ccccc4820f


[ROCm/rocprofiler commit: 80676bb478]
2023-03-09 13:21:09 +00:00
Ammar ELWazir ff80dd4dfa Fixing rocprofilerv2 naming and CMake issues
Change-Id: Ib6d336349a056731e5c0f35151296d6fea671360


[ROCm/rocprofiler commit: dc69331379]
2023-03-09 13:21:01 +00:00
Ammar ELWazir f7772fb704 GPU ID issue
Before, the GPU IDs were counted starting from zero, now CPU IDs are counted from zero and then GPU IDs from the last CPU_ID+1

Change-Id: I3f815195ad97933e02f249841e53b64b674370d9


[ROCm/rocprofiler commit: 6dda141e4b]
2023-03-09 13:20:35 +00:00
Ammar ELWazir de4abd0d0f Adding rocprofilerv2
Change-Id: Ic0cc280ba207d2b8f6ccae1cd4ac3184152fc1ad


[ROCm/rocprofiler commit: 8032adb64f]
2023-03-09 13:20:33 +00:00
Ammar ELWazir c256910fe8 GPU Index to use HSA AMD Agent Driver Node ID
Change-Id: Ia814f64419615f1d77fc09fc88f11bbaf75afd45


[ROCm/rocprofiler commit: 553a4c7ee7]
2022-11-21 14:05:33 -05:00
Ranjith Ramakrishnan a5a941cbfc SWDEV-345870 - Correct include paths for new directory layout
Use hsa header files from /opt/rocm-ver/include rather than using wrapper files from /opt/rocm-ver/hsa/include/hsa

Change-Id: Id7a9bde19447cd2a0fd6e03b11c08471f09c2a46


[ROCm/rocprofiler commit: e7eb195924]
2022-07-14 16:08:41 -07:00
Laurent Morichetti 6624fe4628 Fix a compilation error with gcc-9.3.0
On Ubuntu 20.04, in Release mode, gcc fails with this error:

In file included from /usr/include/string.h:495,
                 from /opt/rocm/include/hsa/hsa_api_trace.h:57,
                 from ../rocprofiler/src/util/hsa_rsrc_factory.h:29,
                 from ../rocprofiler/src/util/hsa_rsrc_factory.cpp:25:
In function ‘char* strncpy(char*, const char*, size_t)’,
    inlined from ‘const util::AgentInfo* util::HsaRsrcFactory::AddAgentInfo(hsa_agent_t)’ at ../rocprofiler/src/util/hsa_rsrc_factory.cpp:323:12:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:106:34: error: ‘char* __builtin___strncpy_chk(char*, const char*, long unsigned int, long unsigned int)’ specified bound depends on the length of the source argument [-Werror=stringop-overflow=]
  106 |   return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
      |          ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../rocprofiler/src/util/hsa_rsrc_factory.cpp: In member function ‘const util::AgentInfo* util::HsaRsrcFactory::AddAgentInfo(hsa_agent_t)’:
../rocprofiler/src/util/hsa_rsrc_factory.cpp:322:39: note: length computed here
  322 |     const int gfxip_label_len = strlen(agent_info->name) - 2;
      |                                 ~~~~~~^~~~~~~~~~~~~~~~~~

The error is caused by the following 2 lines:

    const int gfxip_label_len = strlen(agent_info->name) - 2;
    strncpy(agent_info->gfxip, agent_info->name, gfxip_label_len);

The size argument to strncpy should not depend on the input string.

Since the terminating character is not considered (the copy is at
most len - 2 bytes), using memcpy is preferable. Also, make sure
the destination does not overflow by clamping the size.

Change-Id: I0c5cf7e0daf4cd6fcf7092efb1d9fd4c02a6c639


[ROCm/rocprofiler commit: 304d3366af]
2021-04-22 11:12:53 -07:00
Evgeny eddcdabf2a fixing gfx10 gfxip name
Change-Id: Ie58768d64117a616b1896489b505790cfa993054


[ROCm/rocprofiler commit: 64bdcaddc7]
2021-03-24 00:48:21 -05:00
Evgeny e06ff588ce porting of AQL packet submit to new atomic HSA queue API
Change-Id: I654448a7a8627978395d426118a5cb3ba2a92058


[ROCm/rocprofiler commit: 96ff7582ce]
2020-10-12 09:26:27 -05:00
Evgeny 0d363636f6 HSA trace kernel name demangling
Change-Id: I6d8b674137405a93939c38d7e615af5a114f04ca


[ROCm/rocprofiler commit: 858e0b0f8a]
2020-08-28 05:40:17 -05:00
Evgeny a331990ee4 optimization mechanism fix: correct tracker handler; kernel name query on completion;
Change-Id: I14da152b4ac3c7d8fd1af2f54e9d71f834071622


[ROCm/rocprofiler commit: 80747de208]
2020-08-03 23:34:49 -05:00
Evgeny 676669c2c0 setting code-obj tracking by default
Change-Id: Id6a97a7dc77faa3b7eb0e2b81b75c13ca7fc5818


[ROCm/rocprofiler commit: 30db99e758]
2020-05-28 03:43:12 -05:00
Evgeny 0bea31fe48 get_time API: make public; extende with more time id: coarse and raw; added time error return value;
Change-Id: I1641eb2c38915222204617e07fc0bfb388bb8346


[ROCm/rocprofiler commit: 3ce98d33d4]
2020-04-30 02:38:18 -05:00
Evgeny 31a7eac580 elliminaring the need of AMD_INTERNAL_BUILD macro defined
Change-Id: Ie97aef943793b1e4f40b7c7397af313520b35beb


[ROCm/rocprofiler commit: f819e1c463]
2020-04-09 23:41:51 -05:00
Evgeny cc285d5b48 JSON kernel name propogation and stats
Change-Id: I60cf4c7608272941e2499bd251850416ac254f32


[ROCm/rocprofiler commit: a5f52b40f5]
2020-02-26 19:45:49 -06:00
Evgeny d657afa812 adding AgentInfo::lds_block_size
Change-Id: I186893add96dc92570e710ae78b475897ebfe531


[ROCm/rocprofiler commit: 40730e34e4]
2020-02-18 14:00:19 -06:00
Evgeny ec6fd99b30 hsa_rsrc_factory sync
Change-Id: Idecbc0cdad6068eae5259cb043bdf5746b430aec


[ROCm/rocprofiler commit: 5615ade977]
2020-01-30 19:29:59 -06:00
Evgeny 4a817e3e83 minor changes;
Change-Id: I4266d6af1adef66637b3c971fa21c800240a79ef


[ROCm/rocprofiler commit: 9bdd497a51]
2020-01-14 10:25:13 -06:00
Evgeny 423fec7691 adding rocprofiler_get_time API
Change-Id: I9202b3e97f8f9ca7485f87ea22746a9c4d8091c3


[ROCm/rocprofiler commit: 4d5a11fbbf]
2019-12-30 13:55:04 -06:00
Evgeny 6dd6ea0046 sgpr/vgpr reported sizes in terms of registers; lds size in bytes;
Change-Id: Id527687cc075a4e85ea4d0063ed8f336e34d2454


[ROCm/rocprofiler commit: c8eb0641bf]
2019-11-27 15:19:14 -06:00
Evgeny 9b183d909e code object tracking and v3 code object support
Change-Id: I081ada13f6364ea4401a97a485dedfa9bf8a45fe


[ROCm/rocprofiler commit: 60043d198b]
2019-11-19 20:18:09 -06:00
Xianwei Zhang 3dce66bd80 build: slightly change files to pass compilation
Compiled using Clang and encountered errors on ambiguous pointer
type, implicit conversion NULL to bool, and unused function, etc.
As a fix, this patch slightly updates the related codes.

Change-Id: I4a73d66293313dda36749036f5c73aaf2a445231


[ROCm/rocprofiler commit: ee917344ff]
2019-08-22 23:29:16 -04:00
Evgeny 06778e004b adding hsa_system_get_info, hsa_amd_profiling_set_profiler_enabled to shadow hsa api table
Change-Id: I18859caa45c268f573210aad0b5d8bcc745d3e2e


[ROCm/rocprofiler commit: a91d1e039a]
2019-04-02 12:22:34 -05:00
Evgeny 8b6c9cc839 creation fix
Change-Id: I717d96555677664ce0a926cf1c3c3c48f55287d9


[ROCm/rocprofiler commit: 1ed97815f1]
2019-03-13 15:17:56 -05:00
Evgeny 222ef52c5d supporting original hsa api table
Change-Id: Ia98554c137a3ec6433d8234ba17ca4dc2f2be940


[ROCm/rocprofiler commit: df860838a2]
2019-03-06 13:41:54 -06:00
Evgeny 2c8414e512 introducing hsa api duplicating table
Change-Id: I4bbf933def018ad7b282fa08e587c53f5a44b336


[ROCm/rocprofiler commit: 89ff4ace93]
2019-03-05 19:42:26 -06:00
Evgeny c3c9815c49 minor changes
Change-Id: I16444de8c5d83a9f33392ac870d2fc188978ab54


[ROCm/rocprofiler commit: ea0a1110dc]
2018-12-18 09:51:47 -06:00
Evgeny da6e7f7da4 moving to non-deprecated get extension table HSA API
Change-Id: I356c6406eb5c2a1755202dc562298b30cb7acc06


[ROCm/rocprofiler commit: 01aa4c4ffb]
2018-09-26 13:20:36 -05:00
Evgeny 443b15bc97 standalone/sampling mode
Change-Id: I24c358bfebacb5678fb3d31f2f94ae867a1c9ac9


[ROCm/rocprofiler commit: b481bfe5de]
2018-09-18 20:33:41 -05:00
Evgeny 5af5a02478 licensing annotation
Change-Id: Icdd79e25e7ba30e777f1024697f87d583f380a62


[ROCm/rocprofiler commit: f6f857f6f4]
2018-08-19 04:18:55 -05:00
Evgeny b3e79bee45 cpu_pool/kern_arg_pool search fix for multi core host
Change-Id: Ia7e3a0dcbb8912e88edbf4ba2028818f09599374


[ROCm/rocprofiler commit: bd07ed73fd]
2018-08-17 16:34:30 -05:00
Evgeny f35caeda00 compiling for CentOS support
Change-Id: I0c01b4f34ac3701b5cea324e2e2a34835163aee0


[ROCm/rocprofiler commit: 2cccdb566e]
2018-07-27 15:06:26 -05:00
Evgeny 1027ae42f5 adding tracker handler
Change-Id: Iea47c25b3c9b6e1eadf097c34323727181975cca


[ROCm/rocprofiler commit: 4d790c8eee]
2018-07-25 14:55:21 -05:00
Evgeny 379e305ebd adding -Werror=unused-result compilation flag
Change-Id: I2869d0a150918ad56cefed07d278cbcc6ef5a4b4


[ROCm/rocprofiler commit: 2f83829f4f]
2018-07-13 16:15:48 -05:00
James Edwards d397625ae5 Fix build break for logger.h.
Change-Id: I4b783a1ca668e1c2b2712c31ed4904258b1e3af7


[ROCm/rocprofiler commit: 98bae77eea]
2018-07-13 15:34:25 -05:00
Evgeny 624dbeb708 adding session log
Change-Id: I3e1568f711ca1e863f8d912ba4598ac3ede5a46f


[ROCm/rocprofiler commit: 013721eb62]
2018-07-11 11:39:15 -05:00
Evgeny 75203018c9 adding counters instancing info
Change-Id: Idccc776ed91cafe9662b84bfad4149dde0c82caf


[ROCm/rocprofiler commit: bc7a052294]
2018-07-09 13:48:57 -05:00
Evgeny d31b372430 build compatibility
Change-Id: Ifde4b2e4e7cb48d5c06ccce5eb76b7b943c4114a


[ROCm/rocprofiler commit: a8db3d930c]
2018-06-26 16:05:39 -05:00
Evgeny 368f9f2b5d license annotations
Change-Id: I96b8f625a03b707b45aee6b8e7dbfabe073294c6


[ROCm/rocprofiler commit: add56e26ae]
2018-06-25 19:52:28 -05:00
Evgeny 32b472e246 documentation and cleanup, public metrics only
Change-Id: I8213d193ce2ba632adf133e630fd91baf9e81ddd


[ROCm/rocprofiler commit: ca5c0e8928]
2018-06-22 10:16:13 -05:00
Evgeny 81356f3745 test: scenario with different counters sets per dispatch
Change-Id: Ia0866d485128e7295cbf98c3241a6113ce8d98b8


[ROCm/rocprofiler commit: 53211acd04]
2018-06-01 09:06:51 -05:00
Evgeny 7ae981cdd2 aqlprofile/rocprofiler util sync
Change-Id: If029a5aa4eff9ad3e01dc83b41426c079f7f03a7


[ROCm/rocprofiler commit: cca3ca68c1]
2018-05-16 13:04:07 -05:00
Evgeny 42458339af SQTT local allocation
Change-Id: Ie4a150ad0dc141226f6f1c571916c5a526dd723c


[ROCm/rocprofiler commit: 9dec361cd4]
2018-04-29 03:24:46 -05:00
Evgeny e761eda5fa memory allocation refactoring
Change-Id: Ic63b4f5ea44f2dc5e009e3e58652a661e957b7d6


[ROCm/rocprofiler commit: c9c0ecc976]
2018-04-27 20:00:20 -05:00
Evgeny 0a8e945d88 HSA memory alloc/copy/free refactoring
[ROCm/rocprofiler commit: d04f7095f4]
2018-04-20 11:15:26 -05:00
Evgeny ade8a8c868 context array valid bit reverted
Change-Id: Ibbbf19ffd2e66750d7296d2b45850c21bb86445a


[ROCm/rocprofiler commit: aea5d8e0d9]
2018-03-21 21:11:42 -05:00
Evgeny 777eb116d4 adding timestamps dispatch/begin/end/complete
Change-Id: I8c23e5f7ff75174243224ff008ba266553ee30c8


[ROCm/rocprofiler commit: 363700581a]
2018-03-05 20:59:01 -06:00