<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Intercept calls to pthread_mutex_lock in Software Tuning, Performance Optimization &amp; Platform Monitoring</title>
    <link>https://community.intel.com/t5/Software-Tuning-Performance/Intercept-calls-to-pthread-mutex-lock/m-p/1168456#M7206</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I would want to profile multithreaded program and find out if threre was a contention for mutex by threads.&lt;/P&gt;&lt;P&gt;If a thread is going to operate on some mutex, the thread needs to call corresponding pthread functions, like pthread_mutex_lock.&amp;nbsp; I should be able to redirect the execution of these functions,&amp;nbsp;as in wrap before and after the execution of these functions, where I can get the parameters and return values.&lt;/P&gt;&lt;P&gt;&amp;nbsp;how to intercept calls to pthread_mutex_lock. doing something like&amp;nbsp; #define pthread_mutex_lock my_pthread_mutex_lock?&lt;/P&gt;&lt;P&gt;Kindly throw some light on this.I request you to help me out.&lt;/P&gt;&lt;P&gt;Thank you in advance.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi&lt;/P&gt;</description>
    <pubDate>Sat, 01 Dec 2018 04:25:49 GMT</pubDate>
    <dc:creator>Umesh__Deepthi</dc:creator>
    <dc:date>2018-12-01T04:25:49Z</dc:date>
    <item>
      <title>Intercept calls to pthread_mutex_lock</title>
      <link>https://community.intel.com/t5/Software-Tuning-Performance/Intercept-calls-to-pthread-mutex-lock/m-p/1168456#M7206</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I would want to profile multithreaded program and find out if threre was a contention for mutex by threads.&lt;/P&gt;&lt;P&gt;If a thread is going to operate on some mutex, the thread needs to call corresponding pthread functions, like pthread_mutex_lock.&amp;nbsp; I should be able to redirect the execution of these functions,&amp;nbsp;as in wrap before and after the execution of these functions, where I can get the parameters and return values.&lt;/P&gt;&lt;P&gt;&amp;nbsp;how to intercept calls to pthread_mutex_lock. doing something like&amp;nbsp; #define pthread_mutex_lock my_pthread_mutex_lock?&lt;/P&gt;&lt;P&gt;Kindly throw some light on this.I request you to help me out.&lt;/P&gt;&lt;P&gt;Thank you in advance.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi&lt;/P&gt;</description>
      <pubDate>Sat, 01 Dec 2018 04:25:49 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Tuning-Performance/Intercept-calls-to-pthread-mutex-lock/m-p/1168456#M7206</guid>
      <dc:creator>Umesh__Deepthi</dc:creator>
      <dc:date>2018-12-01T04:25:49Z</dc:date>
    </item>
    <item>
      <title>This doesn't have much to do</title>
      <link>https://community.intel.com/t5/Software-Tuning-Performance/Intercept-calls-to-pthread-mutex-lock/m-p/1168457#M7207</link>
      <description>&lt;P&gt;This doesn't have much to do with Intel, but you can Google for "symbol interposition" or something like that. One way is to use LD_LIBRARY_PRELOAD on Unix-like with a library that redefines the symbols. You can also look at uprobes and similar.&lt;/P&gt;</description>
      <pubDate>Sat, 22 Dec 2018 03:02:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Tuning-Performance/Intercept-calls-to-pthread-mutex-lock/m-p/1168457#M7207</guid>
      <dc:creator>Travis_D_</dc:creator>
      <dc:date>2018-12-22T03:02:45Z</dc:date>
    </item>
  </channel>
</rss>

