wangbo commented on code in PR #25724:
URL: https://github.com/apache/doris/pull/25724#discussion_r1375216498


##########
be/src/agent/cgroup_cpu_ctl.cpp:
##########
@@ -120,7 +122,7 @@ Status CgroupV1CpuCtl::add_thread_to_cgroup() {
     if (!_init_succ) {
         return Status::OK();
     }
-    int tid = static_cast<int>(syscall(SYS_gettid));
+    int tid = static_cast<int>(Thread::current_thread_id());

Review Comment:
   ```
   int tid=0;
   #if defined(__linux__)
       tid = static_cast<int>(syscall(SYS_gettid);
   #elseif #if defined(__APPLE__) // unsupported now
      tid=0;
   #endif
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to