著者
須永 高浩 笹田 耕一
雑誌
情報処理学会論文誌プログラミング(PRO) (ISSN:18827802)
巻号頁・発行日
vol.4, no.3, pp.1-15, 2011-06-29

Ruby は高い生産性を持つプログラミング言語である.これまでもプログラムにあるそれぞれのメソッドの実行時間を計測することができるプロファイラは整備されてきた.しかし,分析対象プログラムの実行と並行してリアルタイムプロファイリングが行えるツールが存在しなかった.そこで,本研究では Ruby で書かれたソフトウェアのプロファイリングをリアルタイムに行える実行時間プロファイラを開発した.本プロファイラは,対象となる Ruby で記述されたプログラムの,メソッド単位での実行時間情報を取得することが可能である.この情報取得はネットワークで接続された別のホストからリアルタイムに行うことができる.さらに,それぞれの情報についてプログラムのエントリポイントからの完全なコールパスを関連付けてプロファイリングを行うことが可能であり,対象となるプログラムのパフォーマンスの傾向を詳細に把握することが可能である.本プロファイラは,プロファイリングモジュールとモニタプログラムに分離されており,プロファイリングモジュールで情報を収集し,モニタプログラムがその情報をユーザへリアルタイムに提供する.本稿では,本プロファイラの設計と実装について述べる.また,本プロファイラのオーバヘッドの評価を行い,その結果を述べる.実用的なプログラムによる評価では 1.15 倍程度の実行時間の増加となり,本プロファイラは実用的であるとの結論を得た.Ruby is a programming language which has high productivity. Up to now, Ruby's performance profilers that are able to measure execution time of each method have been developed. However, there is no real-time profiler that is able to show the profiling result while a Ruby program is running. We developed a profiler that is able to profile programs written in Ruby language in real time. The profiler can get execution time information of each method in the target Ruby program. It is able to get the information from a foreign host connected by network in real time. Furthermore, the profiler can profile associating each information with the entire call-path from an entry point of the program. With this call-path informathion users can know the trend in program performance in detail. The profiler consists of two parts: a profiling module and a monitor program. The profiling module collects information, and the monitor program provides information for users in real time. In this paper, we describe the design and implementation of our proposed profiler. We also describe the result of overhead evaluation for the profiler. Execution time increases 1.15 times in a practical example. We conclude that our profiler is capable for practical use.
著者
須永 高浩 笹田 耕一
出版者
日本ソフトウェア科学会
雑誌
コンピュータ ソフトウェア (ISSN:02896540)
巻号頁・発行日
vol.29, no.4, pp.4_95-4_113, 2012-10-25 (Released:2012-11-25)

本研究では,スクリプト言語用プロファイラの実装を容易に行うためのフレームワークの開発を行った.本フレームワークを用いることで,プログラムの性能情報をリアルタイムに取得するプロファイラを構築できる.本フレームワークは複数のスクリプト言語に対応することができ,計測内容も容易に追加できる.また,プロファイリングの利便性を高めるため,ネットワークで接続された別のホストから接続し遠隔で情報取得するための機能や,コンテキスト情報を含んだ情報を取得するための機能を提供する.本論文では本フレームワークの設計と実装を示す.また,本フレームワークによるプロファイラの参考実装を行い,本フレームワークによるプロファイラを使用した実運用しているアプリケーションに対する分析事例を示し,本フレームワークが実用的であることを示す.