<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=windows-1252">
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:"MS Mincho";
        panose-1:2 2 6 9 4 2 5 8 3 4;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:"\@MS Mincho";}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.E-MailFormatvorlage17
        {mso-style-type:personal-reply;
        font-family:"Calibri","serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body lang=EN-US link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'>Actually you want something like<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'>retval WINAPI wine_cudaSomething(int a, int etc)<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'>so instead of the void use the return value the function is
supposed to return<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'>WINAPI tells the compiler about the calling convention(ie, first
parameter on the stack, in ecx, or elsewhere, who takes care about cleaning up
the stack, etc). You'll have to check the calling convention Win32 cuda uses,
but most likely WINAPI is correct. You don't have to care about the Linux cuda calling
convention, since the compiler knows about that from the Linux cuda headers<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'>I am also not quite sure about some constructs, like<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'>&quot;wine_cudaBindTexture( size_t* offset, const struct texture
&lt; T, dim, readMode &gt;&amp; texRef, const void* devPtr, const struct
cudaChannelFormatDesc&amp; desc, size_t size = UINT_MAX )&quot; As far as I
know this contains C++ or Microsoft syntax, which is not valid in pure C.<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<div style='border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt'>

<div>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p class=MsoNormal><b><span lang=DE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span
lang=DE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Seth
Shelnutt [mailto:shelnutt2@gmail.com] <br>
<b>Sent:</b> Monday, July 07, 2008 11:01 AM<br>
<b>To:</b> Stefan D�singer<br>
<b>Cc:</b> wine-devel@winehq.org<br>
<b>Subject:</b> Re: CUDA wrapper<o:p></o:p></span></p>

</div>

</div>

<p class=MsoNormal><o:p>&nbsp;</o:p></p>

<p class=MsoNormal><br>
I've attached my spec file and my .c file along with the two header files from
the nvidia toolkit. I am pretty sure in the .c file I was not suppose to use
the &quot;WINAPI&quot; but instead I need &quot;FancyCudaReturnValue&quot; but
I don't know what that is. Needless to say after using &quot;winemaker
cuda&quot; (I have it in a folder called cuda), it doesn't compile and I get a
million and one errors. I'm sure these errors are more or less caused because I
didn't quite get it right. If you could just look at it and give me some pointers
on where and how I went wrong, it would be appreciated. You've been a big help
so far. Thank you for the explanations in the last email it got me this far so
far.<br>
<br>
<br>
-Seth Shelnutt<o:p></o:p></p>

</div>

</div>

</body>

</html>