libgompd: Fix Access Bugs
libgomp/ChangeLog 2022-06-29 Mohamed Atef <mohamedatef1698@gmail.com> * ompd-helper.c (gompd_is_final, gompd_is_implicit, gompd_get_team_size): Change is_ptr from 1 to 0 in ACCESS_VALUE. Signed-off-by: Mohamed Atef <mohamedatef1698@gmail.com>
This commit is contained in:
parent
d098c1d7c0
commit
bf7b85b96f
@ -540,7 +540,7 @@ gompd_is_final (ompd_task_handle_t *task_handle, ompd_word_t *final_task)
|
|||||||
ompd_rc_t ret;
|
ompd_rc_t ret;
|
||||||
/* gomp_task->final_task. */
|
/* gomp_task->final_task. */
|
||||||
ACCESS_VALUE (context, NULL, "gompd_access_gomp_task_final_task", temp_offset,
|
ACCESS_VALUE (context, NULL, "gompd_access_gomp_task_final_task", temp_offset,
|
||||||
1, ret, symbol_addr, temp_sym_addr, temp_addr);
|
0, ret, symbol_addr, temp_sym_addr, temp_addr);
|
||||||
DEREFERENCE (context, NULL, symbol_addr, target_sizes.sizeof_char, 1,
|
DEREFERENCE (context, NULL, symbol_addr, target_sizes.sizeof_char, 1,
|
||||||
res, ret, 0);
|
res, ret, 0);
|
||||||
*final_task = res;
|
*final_task = res;
|
||||||
@ -565,7 +565,7 @@ gompd_is_implicit (ompd_task_handle_t *task_handle, ompd_word_t *task_kind)
|
|||||||
ompd_address_space_context_t *context = task_handle->ah->context;
|
ompd_address_space_context_t *context = task_handle->ah->context;
|
||||||
ompd_rc_t ret;
|
ompd_rc_t ret;
|
||||||
/* gomp_task->kind. */
|
/* gomp_task->kind. */
|
||||||
ACCESS_VALUE (context, NULL, "gompd_access_gomp_task_kind", temp_offset, 1,
|
ACCESS_VALUE (context, NULL, "gompd_access_gomp_task_kind", temp_offset, 0,
|
||||||
ret, symbol_addr, temp_sym_addr, temp_addr);
|
ret, symbol_addr, temp_sym_addr, temp_addr);
|
||||||
DEREFERENCE (context, NULL, symbol_addr, target_sizes.sizeof_int, 1, res,
|
DEREFERENCE (context, NULL, symbol_addr, target_sizes.sizeof_int, 1, res,
|
||||||
ret, 0);
|
ret, 0);
|
||||||
@ -597,7 +597,7 @@ gompd_get_team_size (ompd_parallel_handle_t *parallel_handle,
|
|||||||
ompd_rc_t ret;
|
ompd_rc_t ret;
|
||||||
/* gomp_team->nthreads. */
|
/* gomp_team->nthreads. */
|
||||||
ACCESS_VALUE (context, NULL, "gompd_access_gomp_team_nthreads", temp_offset,
|
ACCESS_VALUE (context, NULL, "gompd_access_gomp_team_nthreads", temp_offset,
|
||||||
1, ret, symbol_addr, temp_sym_addr, temp_addr);
|
0, ret, symbol_addr, temp_sym_addr, temp_addr);
|
||||||
DEREFERENCE (context, NULL, symbol_addr, target_sizes.sizeof_int, 1,
|
DEREFERENCE (context, NULL, symbol_addr, target_sizes.sizeof_int, 1,
|
||||||
res, ret, 0);
|
res, ret, 0);
|
||||||
*nthreads = res;
|
*nthreads = res;
|
||||||
|
Loading…
Reference in New Issue
Block a user