<?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 pin-2.14-71313 and WinSock library in Intel® ISA Extensions</title>
    <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059778#M5473</link>
    <description>&lt;P&gt;&lt;FONT color="#000099" face="Arial,Sans-Serif" size="3"&gt;Hi,&lt;BR /&gt;
	I have a problem trying to start my pintool built with WinSock library (ws2_32.lib) - it immediately exits with message "Failure to open DLL file WS2_32.dll".&lt;BR /&gt;
	I've prepared a simple pintool to illistrate the problem:&lt;BR /&gt;
	&lt;BR /&gt;
	//----------------------------------------------------------&lt;BR /&gt;
	#include "pin.H"&lt;BR /&gt;
	&lt;BR /&gt;
	namespace WINDOWS&lt;BR /&gt;
	{&lt;BR /&gt;
	#include &amp;lt;Ws2tcpip.h&amp;gt;&lt;BR /&gt;
	void *p = WSAStartup;&lt;BR /&gt;
	};&lt;BR /&gt;
	&lt;BR /&gt;
	int main(int argc, char *argv[])&lt;BR /&gt;
	{&lt;BR /&gt;
	if (PIN_Init(argc, argv)) return 1;&lt;BR /&gt;
	PIN_StartProgram();&lt;BR /&gt;
	return 0;&lt;BR /&gt;
	}&lt;BR /&gt;
	&lt;BR /&gt;
	I've placed this file to a subdirectory of source\tools, added to makefile.rules the following line&lt;BR /&gt;
	TOOL_LIBS := ${TOOL_LIBS} ws2_32.lib&lt;BR /&gt;
	&lt;BR /&gt;
	built the pintool&lt;BR /&gt;
	make -B TARGET=ia32&lt;BR /&gt;
	&lt;BR /&gt;
	then tried to run with the following command:&lt;BR /&gt;
	..\..\..\pin.exe -t obj-ia32\sock_tool.dll -- c:\windows\System32\cmd /c echo ****** started Ok ******&lt;BR /&gt;
	&lt;BR /&gt;
	and have got the following message:&lt;BR /&gt;
	E: Failure to open DLL file Z:\pin-2.14-71313\source\tools\sock_tool\obj-ia32\WS2_32.dll&lt;BR /&gt;
	E: System error 2 : The system cannot find the file specified.&lt;BR /&gt;
	E: Failure to initialize DLL Z:\pin-2.14-71313\source\tools\sock_tool\obj-ia32\sock_tool.dll&lt;BR /&gt;
	E: See preceding message to find out the reason&lt;BR /&gt;
	&lt;BR /&gt;
	Could you please explain me what I'm doing wrong?&lt;BR /&gt;
	With the previous versions of PIN this pintool works Ok.&lt;BR /&gt;
	When I remove the line "void *p = WSAStartup;" from the source and rebuild the pintool works Ok with pin-2.14-71313 too.&lt;BR /&gt;
	&lt;BR /&gt;
	Any help would be greatly appreciated.&lt;BR /&gt;
	Thanks in advance,&lt;BR /&gt;
	Pavel&lt;BR /&gt;
	&lt;BR /&gt;
	OS: Windows 7&lt;BR /&gt;
	compiler: Visual Studio 2010&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 23 Mar 2015 17:56:16 GMT</pubDate>
    <dc:creator>Pavel_R_</dc:creator>
    <dc:date>2015-03-23T17:56:16Z</dc:date>
    <item>
      <title>pin-2.14-71313 and WinSock library</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059778#M5473</link>
      <description>&lt;P&gt;&lt;FONT color="#000099" face="Arial,Sans-Serif" size="3"&gt;Hi,&lt;BR /&gt;
	I have a problem trying to start my pintool built with WinSock library (ws2_32.lib) - it immediately exits with message "Failure to open DLL file WS2_32.dll".&lt;BR /&gt;
	I've prepared a simple pintool to illistrate the problem:&lt;BR /&gt;
	&lt;BR /&gt;
	//----------------------------------------------------------&lt;BR /&gt;
	#include "pin.H"&lt;BR /&gt;
	&lt;BR /&gt;
	namespace WINDOWS&lt;BR /&gt;
	{&lt;BR /&gt;
	#include &amp;lt;Ws2tcpip.h&amp;gt;&lt;BR /&gt;
	void *p = WSAStartup;&lt;BR /&gt;
	};&lt;BR /&gt;
	&lt;BR /&gt;
	int main(int argc, char *argv[])&lt;BR /&gt;
	{&lt;BR /&gt;
	if (PIN_Init(argc, argv)) return 1;&lt;BR /&gt;
	PIN_StartProgram();&lt;BR /&gt;
	return 0;&lt;BR /&gt;
	}&lt;BR /&gt;
	&lt;BR /&gt;
	I've placed this file to a subdirectory of source\tools, added to makefile.rules the following line&lt;BR /&gt;
	TOOL_LIBS := ${TOOL_LIBS} ws2_32.lib&lt;BR /&gt;
	&lt;BR /&gt;
	built the pintool&lt;BR /&gt;
	make -B TARGET=ia32&lt;BR /&gt;
	&lt;BR /&gt;
	then tried to run with the following command:&lt;BR /&gt;
	..\..\..\pin.exe -t obj-ia32\sock_tool.dll -- c:\windows\System32\cmd /c echo ****** started Ok ******&lt;BR /&gt;
	&lt;BR /&gt;
	and have got the following message:&lt;BR /&gt;
	E: Failure to open DLL file Z:\pin-2.14-71313\source\tools\sock_tool\obj-ia32\WS2_32.dll&lt;BR /&gt;
	E: System error 2 : The system cannot find the file specified.&lt;BR /&gt;
	E: Failure to initialize DLL Z:\pin-2.14-71313\source\tools\sock_tool\obj-ia32\sock_tool.dll&lt;BR /&gt;
	E: See preceding message to find out the reason&lt;BR /&gt;
	&lt;BR /&gt;
	Could you please explain me what I'm doing wrong?&lt;BR /&gt;
	With the previous versions of PIN this pintool works Ok.&lt;BR /&gt;
	When I remove the line "void *p = WSAStartup;" from the source and rebuild the pintool works Ok with pin-2.14-71313 too.&lt;BR /&gt;
	&lt;BR /&gt;
	Any help would be greatly appreciated.&lt;BR /&gt;
	Thanks in advance,&lt;BR /&gt;
	Pavel&lt;BR /&gt;
	&lt;BR /&gt;
	OS: Windows 7&lt;BR /&gt;
	compiler: Visual Studio 2010&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Mar 2015 17:56:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059778#M5473</guid>
      <dc:creator>Pavel_R_</dc:creator>
      <dc:date>2015-03-23T17:56:16Z</dc:date>
    </item>
    <item>
      <title>It seems that you have</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059779#M5474</link>
      <description>&lt;P&gt;It seems that you have aproblem with &lt;SPAN style="font-size: 13.0080003738403px; line-height: 19.5120010375977px;"&gt;&amp;nbsp;path related to winsock dll location,&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 13.0080003738403px; line-height: 19.5120010375977px;"&gt;Can you create test project which uses&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 12px; line-height: 18px;"&gt;Ws2tcpip.h?&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 12px; line-height: 18px;"&gt;I have also seen that call to WSAStartup returns void pointer, but in documentation return type is address of WSADATA structure which is passed as a function parameter. Maybe this is the reason for the failure.&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;A href="https://msdn.microsoft.com/en-us/library/windows/desktop/ms742213%28v=vs.85%29.aspx" target="_blank"&gt;https://msdn.microsoft.com/en-us/library/windows/desktop/ms742213%28v=vs.85%29.aspx&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 16:56:40 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059779#M5474</guid>
      <dc:creator>Bernard</dc:creator>
      <dc:date>2015-03-24T16:56:40Z</dc:date>
    </item>
    <item>
      <title>Hi Guys,</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059780#M5475</link>
      <description>&lt;P&gt;Hi Guys,&lt;/P&gt;

&lt;P&gt;Pin support stuff is handled on the pinheads yahoo group:&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;&amp;nbsp; &amp;nbsp; &lt;A href="https://groups.yahoo.com/neo/groups/pinheads/info" target="_blank"&gt;https://groups.yahoo.com/neo/groups/pinheads/info&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;It is monitored by the pin developers and many users.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 16:59:59 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059780#M5475</guid>
      <dc:creator>MarkC_Intel</dc:creator>
      <dc:date>2015-03-24T16:59:59Z</dc:date>
    </item>
    <item>
      <title>Quote:iliyapolak wrote:</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059781#M5476</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;iliyapolak wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;It seems that you have aproblem with &amp;nbsp;path related to winsock dll location,&amp;nbsp;&lt;/P&gt;

&lt;P style="line-height: 12.1949996948242px;"&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;No problem with&amp;nbsp;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;path - the same pintool built with the previous version of PIN works Ok&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="line-height: 12.1949996948242px;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;iliyapolak wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;Can you create test project which uses&amp;nbsp;Ws2tcpip.h?&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;I have also seen that call to WSAStartup returns void pointer, but in documentation return type is address of WSADATA structure which is passed as a function parameter. Maybe this is the reason for the failure.&lt;/P&gt;

&lt;P style="line-height: 12.1949996948242px;"&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="line-height: 12.1949996948242px;"&gt;WSAStartup is not called there, I just assigned its address to a void pointer to have a reference to w2_3.dll&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 17:20:13 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059781#M5476</guid>
      <dc:creator>Pavel_R_</dc:creator>
      <dc:date>2015-03-24T17:20:13Z</dc:date>
    </item>
    <item>
      <title>You may try to run pintools</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059782#M5477</link>
      <description>&lt;P&gt;You may try to run pintools under windbg with loader snaps enabled. &amp;nbsp;You may get more comprehensive error description.&lt;/P&gt;

&lt;H1 class="name" itemprop="name" style="margin-top: 30px; margin-left: 10px; border: 0px; font-size: 18px; vertical-align: baseline; max-width: 733px; line-height: 20px; color: rgb(0, 0, 0); clear: both; width: auto; font-family: Arial, Tahoma, Verdana, Helvetica, sans-serif;"&gt;&lt;A href="http://blogs.msdn.com/b/junfeng/archive/2006/11/20/debugging-loadlibrary-failures.aspx" target="_blank"&gt;http://blogs.msdn.com/b/junfeng/archive/2006/11/20/debugging-loadlibrary-failures.aspx&lt;/A&gt;&lt;/H1&gt;</description>
      <pubDate>Tue, 24 Mar 2015 19:08:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059782#M5477</guid>
      <dc:creator>Bernard</dc:creator>
      <dc:date>2015-03-24T19:08:16Z</dc:date>
    </item>
    <item>
      <title> </title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059783#M5478</link>
      <description>&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 12.1949996948242px;"&gt;Thank you, I'll try&lt;/SPAN&gt;&lt;SPAN style="font-size: 1em; line-height: 12.1949996948242px;"&gt;. In any case this is a useful link for me&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 19:24:37 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059783#M5478</guid>
      <dc:creator>Pavel_R_</dc:creator>
      <dc:date>2015-03-24T19:24:37Z</dc:date>
    </item>
    <item>
      <title>Btw, you can put breakpoint</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059784#M5479</link>
      <description>&lt;P&gt;Btw, you can put breakpoint on address assignment to void pointer and observe in windbg if address of WSAStartup was resolved properly.&lt;/P&gt;</description>
      <pubDate>Wed, 25 Mar 2015 08:36:17 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059784#M5479</guid>
      <dc:creator>Bernard</dc:creator>
      <dc:date>2015-03-25T08:36:17Z</dc:date>
    </item>
    <item>
      <title>Hi Mark,</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059785#M5480</link>
      <description>&lt;P&gt;Hi Mark,&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Mark Charney (Intel) wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;Pin support stuff is handled on the pinheads yahoo group:&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp; &amp;nbsp; &lt;A href="https://groups.yahoo.com/neo/groups/pinheads/info"&gt;https://groups.yahoo.com/neo/groups/pinheads/info&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;It is monitored by the pin developers and many users.&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;I've asked them before but have no answer.&amp;nbsp;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;Strange, because this looks like a bug in PIN toolkit, as for me.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Mar 2015 10:20:29 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/pin-2-14-71313-and-WinSock-library/m-p/1059785#M5480</guid>
      <dc:creator>Pavel_R_</dc:creator>
      <dc:date>2015-03-25T10:20:29Z</dc:date>
    </item>
  </channel>
</rss>

