[ofw] RE: [PATCH] osmtest - Add OSM_CDECL to main() declaration

Smith, Stan stan.smith at intel.com
Mon Oct 12 15:28:18 PDT 2009


Sasha Khapyorsky wrote:
> On 14:58 Mon 12 Oct     , Smith, Stan wrote:
>>>
>>>>  {
>>>>      static osmtest_t osm_test;
>>>>      osmtest_opt_t opt = { 0 };
>>
>> Sean maintains a separate set of patches applied to IB diags in
>> order to address issues like the x86 requirement for __cdecl on
>> main(). Since OSM_CDECL was already defined in OFED opensm, it did
>> not seem to be a major concession to prefix main() with it.
>> Options:
>> 1) utilize OSM_CDECL
>> 2) throw an ugly ifdef __WIN__ or ifdef __linux__ around main()
>> 3) Create more Windows-only patches required for the Windows
>> implementation of OFED opensm & tools.
>
> Any options for windows compiler about call conventions?
>
> Sasha

Sadly not for x86 architecture on Windows. Both Sean and I have danced around this and come up empty.



More information about the ofw mailing list