Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » U++ logging refactored
Re: U++ logging refactored [message #36807 is a reply to message #36806] Sat, 07 July 2012 12:22 Go to previous messageGo to previous message
dolik.rce is currently offline  dolik.rce
Messages: 1791
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

mirek wrote on Sat, 07 July 2012 11:54

This is nothing new, it was always working this way.

It is possible to fix it, but with somewhat lowered performance (because we would need to create String first, then output to stream, now everything goes directly to stream).

Not sure it is worth it...

(Note that MT behaviour is fine, it is "non-atomic" only in single thread).


Hm, interesting, I never noticed before... I think that when using logging for debug purposes, the performance is not important. Would it be possible to add some mechanism that would allow to differentiate between debug logging and other cases?

The simple way that comes to my mind is to make it work fast in release mode and correct in debug, but that might lead to confusion in the non-debug usage. What about a flag/macro, that would let me say "now I want to use the 'atomic' logging"? It could even work on per file basis...

Honza
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: SQL refactored, adding per-thread option, added second SQLR
Next Topic: MySql now supports reconnection features
Goto Forum:
  


Current Time: Fri Jul 18 06:41:22 CEST 2025

Total time taken to generate the page: 0.04169 seconds