just google it

http://stackoverflow.com/questions/4092641/profiling-ruby-code

---
"No man is an island... except Philip"


On Mon, Jul 1, 2013 at 1:44 PM, Li Dong <[email protected]> wrote:

> Oh! Could you tell me what is the best tool can I use to draw a table of
> time cost? Thanks!
>
> Cheers
> Li
>
> 在 2013-7-1,上午11:27,Nigel Thorne <[email protected]> 写道:
>
> no sorry. I meant.. "Have you run your code through a profiler to find the
> bottlenecks?"
>
> ie. What percentage of your time is being spent on each method?
>
> Cheers
> Nigel
>
> ---
> "No man is an island... except Philip"
>
>
> On Mon, Jul 1, 2013 at 12:59 PM, Li Dong <[email protected]> wrote:
>
>> Hi Nigel,
>>
>> Yes, the timing result is already outputted by the 'rspec' command. Here
>> is in my environment:
>>
>> [Notice]: Test fortran code parsing
>>  ---> Parsing uses 17.100005 seconds.
>>  ---> Converting uses 1.838105 seconds.
>>
>> Best,
>> Li
>>
>> 在 2013-7-1,上午10:46,Nigel Thorne <[email protected]> 写道:
>>
>> Please can you include your profiler results.
>>
>> Cheers
>> Nigel
>>
>> ---
>> "No man is an island... except Philip"
>>
>>
>> On Mon, Jul 1, 2013 at 12:51 AM, Li Dong <[email protected]> wrote:
>>
>>> Dear all,
>>>
>>> After several hard working days, I have implemented a Fortran parser.
>>> Although
>>> it is still incomplete, the most thing that I am worrying about is the
>>> performance. I have tried it on a Fortran code with 2000+ lines, and it
>>> took
>>> around 20 seconds on my MacBook Pro for parsing. This can not be
>>> practical. So
>>> I should optimize the parser, but I have no idea where to start, and
>>> which
>>> parts should be heavily optimized.
>>>
>>> The parser is located in htt 
>>> ps://gist.github.com/dongli/5791976<https://gist.github.com/dongli/5791976>,
>>> and the example
>>> can be run as:
>>>
>>>     rspec rspec_fortran_parser.rb
>>>
>>> Any idea is appreciated!
>>> Best regards,
>>>
>>> Li
>>>
>>>
>>
>>
>
>

Reply via email to