On Thu, Oct 14, 2010 at 3:15 PM, Martin Sustrik <[email protected]> wrote:

> On 10/14/2010 03:08 PM, Martin Sustrik wrote:
>
>> Hi Martin,
>>
>>  the attached patch ensures that a correct rdtsc value is returned when
>>> compiled
>>> with sunstudio 12 compiler.
>>>
>>
>> Just a check: This is a performance patch, right? The codebase still
>> works with sunstudio, even without this patch?
>>
>
Correct, it's a performance patch. Previously, the rdtsc() function
returned 0 in my case, thus now_us() was used in now_ms() instead.
Now, an inline assembly code is in place.


>
> Also, you should check for the platform (x86 or x86-64). I would expect
> that sunstudio works with platforms that have no rdtsc instruction -- such
> as SPARC.
>
>
True. I also added platform checks. See the updated patch attached.

Martin


> Martin
>

Attachment: 0001-zmq-clock_t-return-correct-value-in-rdtsc-on-solaris.patch
Description: Binary data

_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to