From: Lukasz Kostyra Date: Mon, 27 Jul 2020 17:12:23 +0000 (+0200) Subject: Don't look up pid/tid on YAGL_LOG_FUNC_SET X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F23%2F239723%2F2;p=sdk%2Femulator%2Fqemu.git Don't look up pid/tid on YAGL_LOG_FUNC_SET YAGL_LOG_FUNC_SET looks into cur_ts global variable to read current PID/TID. Unforutnately on multithreaded app scenarios, this can cause a segmentation failure so was temporarily removed. Change-Id: I253c9e38545b98d47dcdcd485966c5a838145ffb Signed-off-by: Lukasz Kostyra [cw00.choi: Apply it from tizen branch by using cherry-pick git command] Signed-off-by: Chanwoo Choi --- diff --git a/hw/yagl/yagl_log.h b/hw/yagl/yagl_log.h index 8a8a7a5..4479108 100644 --- a/hw/yagl/yagl_log.h +++ b/hw/yagl/yagl_log.h @@ -123,10 +123,12 @@ bool yagl_log_is_enabled_for_func_tracing(void); } \ } while(0) +// TODO _yagl_log_current_pid/tid must be restored to proper form +// PID/TID must be read in a different way than via global cur_ts #define YAGL_LOG_FUNC_SET(func) \ const char* _yagl_log_current_func = #func; \ - yagl_pid _yagl_log_current_pid = (cur_ts ? cur_ts->ps->id : 0); \ - yagl_tid _yagl_log_current_tid = (cur_ts ? cur_ts->id : 0) + yagl_pid _yagl_log_current_pid = 0; \ + yagl_tid _yagl_log_current_tid = 0 #define YAGL_LOG_FUNC_ENTER(func, format, ...) \ YAGL_LOG_FUNC_SET(func); \