File tree Expand file tree Collapse file tree 2 files changed +8
-7
lines changed
Expand file tree Collapse file tree 2 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -101,9 +101,9 @@ ROCPROFILER_REGISTER_DEFINE_IMPORT(hsa, ROCP_REG_VERSION)
101101const char rocrbuildid[] __attribute__((used)) = " ROCR BUILD ID: " STRING(ROCR_BUILD_ID);
102102
103103extern r_debug _amdgpu_r_debug;
104- extern void _loader_debug_state ();
105104
106105namespace rocr {
106+ extern void _loader_debug_state ();
107107namespace core {
108108bool g_use_interrupt_wait;
109109bool g_use_mwaitx;
Original file line number Diff line number Diff line change 6666using namespace rocr ::amd::hsa;
6767using namespace rocr ::amd::hsa::common;
6868
69- // Having a side effect prevents call site optimization that allows removal of a noinline function call
70- // with no side effect.
71- __attribute__ ((noinline)) void _loader_debug_state() {
72- static volatile int function_needs_a_side_effect = 0 ;
73- function_needs_a_side_effect ^= 1 ;
74- }
7569// r_version history:
7670// 1: Initial debug protocol
7771// 2: New trap handler ABI. The reason for halting a wave is recorded in ttmp11[8:7].
@@ -92,6 +86,13 @@ static __forceinline link_map*& r_debug_tail() {
9286}
9387
9488namespace rocr {
89+ // Having a side effect prevents call site optimization that allows removal of a noinline function call
90+ // with no side effect.
91+ __attribute__ ((noinline)) void _loader_debug_state () {
92+ static volatile int function_needs_a_side_effect = 0 ;
93+ function_needs_a_side_effect ^= 1 ;
94+ }
95+
9596namespace amd {
9697namespace hsa {
9798namespace loader {
You can’t perform that action at this time.
0 commit comments