Am Sonntag, 19. Dezember 2004 07:11 schrieb Curt Arnold:
> On Dec 18, 2004, at 6:19 PM, Curt Arnold wrote:
> >> Just to fight at least a little for STL (I don't want to start a
> >> flame-war
> >> about STL): I created StringHelper::UlongToString-methods and
> >> benchmarked it
> >> against std::wostringstream. The result was, that for large numbers
> >> (>INT_MAX, where your optimization don't catch), it took 2.3 seconds
> >> to
> >> format 1000000 with UlongToString and 1.5 seconds with
> >> std::wostringstream
> >> (including std::wostringstream-creation). For small numbers
> >> UlongToString
> >> took 0.5 seconds.
>
> For thread id it is probably more useful to output hex, since any
> debugger would be unlikely to display a signed decimal representation
> (plus it is very simple to implement).
hex sounds good. When I saw my 64-bit thread-id I thought it looked somewhat 
funny. And yes - the implementation will get much easier. I will try that.

Tommi

Reply via email to