首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >哪个是最好的图形化ruby分析器?

哪个是最好的图形化ruby分析器?
EN

Stack Overflow用户
提问于 2011-12-10 00:39:04
回答 2查看 2K关注 0票数 2

到目前为止,我找到的最好的匹配方法是从命令行使用ruby-prof,并尝试从那里猜测图形读数。

代码语言:javascript
复制
require 'ruby-prof'

# Profile the code
RubyProf.start
...
[code to profile]
...
result = RubyProf.stop

# Print a flat profile to text
printer = RubyProf::FlatPrinter.new(result)
printer.print(STDOUT)

https://github.com/rdp/ruby-prof

这种方法的主要问题是,您必须修改代码才能看到分析,而且可读性不是很好。

我也尝试过一些IDE: RubyMine,Aptana和Netbeans,但没有人有一个合适的图形界面来配置代码。

有什么建议吗?

EN

回答 2

Stack Overflow用户

发布于 2012-01-24 20:11:04

试试ruby-prof命令行工具:http://ruby-prof.rubyforge.org/files/bin/ruby-prof.html

并使用类似于以下内容:

代码语言:javascript
复制
ruby-prof -p graph_html -f filename.html rubycode.rb
票数 3
EN

Stack Overflow用户

发布于 2013-07-02 23:38:23

签出迷你分析器:http://railscasts.com/episodes/368-miniprofiler

文档可以在这里找到:https://github.com/SamSaffron/MiniProfiler/tree/master/Ruby

检查特殊参数:pp=flamegraph -它非常容易分析。对于ruby 2.0,它甚至可以在生产环境中工作!

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/8448705

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档