是否可以使用ETW来分析发送到Win32调试输出的消息? [英] Is it possible to use ETW to analyze messages, sent to Win32 debug output?

查看:76
本文介绍了是否可以使用ETW来分析发送到Win32调试输出的消息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

通常我使用DebugView查看我的.NET代码写入标准调试输出(如System.Diagnostics.Debug.WriteLine()所做的)。是否可以使用Message Analyzer而不是DebugView?该怎么办?

usually I use DebugView to see what my .NET code write to the standard debug Output (like System.Diagnostics.Debug.WriteLine() does). Is it possible to use Message Analyzer instead of DebugView? What is to do for this?

问候,

Alexander

Alexander

亲切的问候,亚历山大

推荐答案

没有本土方式,但我想那里目前很少有可能。 

There is not a native way, but I suppose there are few possibilities at this point. 

1。您可以将程序转换为仅编写ETW事件。 然后Message Analyzer可以直接使用它们。当然,这是一些工作,但在写了ETW事件之后,Message Analyzer可以自动解析它们。但这可以是一个更好的解决方案
在您创建新代码时继续前进。

1. You could convert your program to just write ETW events.  Then Message Analyzer could consume them directly. Granted, it's some work, but after write ETW events, Message Analyzer can parse them automatically. But this can be a better solution moving forward as you create new code.

2。如果您可以将输出重定向到文本文件,那么您可以使用文本事件,并为它们编写文本配置解析器。 假设格式相当好,这并不太难。

2. If you can redirect the output to a text file, then you could consume the text events, and write a text configuration parser for them.  Assuming they are fairly well formatted, this isn't too difficult.

3。最后,可以编写一个转换器,它接受Debug Output事件(假设有一个API),然后将它们转换为ETW。 你没有获得前两个数据的保真度,但它会给你一个通用的解决方案
,它适用于你已编写的任何代码。

3. Finally, it would be possible to write a converter, that takes Debug Output events (assuming there is an API), and then converting them to ETW.  You don't get the data fidelity you would for the first two, but it would give you a generic solution that would work for any code you've written already.

谢谢,

保罗


这篇关于是否可以使用ETW来分析发送到Win32调试输出的消息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆