[antlr-interest] Profiler of ANTLR usage

Martin Probst mail at martin-probst.com
Thu Dec 1 15:03:52 PST 2005


Hi Ruslan,

the last time you said you wanted to investigate some possible changes
to the ANTLR runtime. Did you make any progress on that? I think I
remember you wanted to remove the std::string part, did you manage to?
I'd be curious. Do you use semantic predicates "( ... ) =>" btw?

Martin

Am Freitag, den 02.12.2005, 00:20 +0200 schrieb Ruslan Zasukhin:
> Hi ANTLR list,
> 
> I have get some profiling. 
> 
> Simple test. We add 100,000 record using SQL INSERT into Valentina
> database.
> 
> As you can see 
> 
>         ANTLR  take     74.6% of time. This is only parsing and tree
> parsing        :-((
> 
>         Valentina do rest work to put million records in 13.6% + 4.6%
> = 18.2%
> 
> As I have always told, on top of problem are 
>     std::strings, which do a lots of  new/delete...
> 
> 
> -------------------------------------------------------------------------------
>     0.0%    99.9%    Common_SetExtesions    main    
>     0.0%    99.9%    Common_SetExtesions    Example()    
>     0.1%    99.2%    Common_SetExtesions
>    AddRecords(fbl::smart_ptr<fbl::vsql::I_Database>)    
>     0.1%    96.7%    libvkernel_ppc_debug.dylib
>    fbl::vsql::Database::SqlExecute(fbl::String const&,
> fbl::smart_ptr<fbl::ArrayOfSmartPtrs<fbl::smart_ptr<fbl::I_Value> >
> >)    
>     0.1%    96.4%    libvkernel_ppc_debug.dylib
>    fbl::vsql::SqlParser::SqlExecute(fbl::vsql::I_Database*,
> fbl::String const&,
> fbl::smart_ptr<fbl::ArrayOfSmartPtrs<fbl::smart_ptr<fbl::I_Value> >
> >)    
> 
>     0.1%    74.6%  libvkernel_ppc_debug.dylib
>    fbl::vsql::SqlParser::ParseCommand(fbl::String const&,
> fbl::vsql::Environment&)    
>    0.0%    13.6%  libvkernel_ppc_debug.dylib
>    fbl::vsql::SqlParser::PreprocessCommand(fbl::vsql::Environment&)
>    
>   0.0%    4.6%    libvkernel_ppc_debug.dylib
>    fbl::vsql::SqlParser::ProceedCommand(fbl::vsql::Environment&)    
> 
>     0.0%    2.3%    libvkernel_ppc_debug.dylib
>    fbl::vsql::Environment::~Environment [in-charge]()    
>     0.0%    0.6%    libvkernel_ppc_debug.dylib
>    fbl::vsql::Environment::Environment[in-charge](fbl::smart_ptr<fbl::vsql::I_Database>, fbl::String const&, fbl::smart_ptr<fbl::ArrayOfSmartPtrs<fbl::smart_ptr<fbl::I_Value> > >)    
>     0.1%    0.1%    libstdc++.6.dylib
>    std::basic_istringstream<char, std::char_traits<char>,
> std::allocator<char> >::str(std::basic_string<char,
> std::char_traits<char>, std::allocator<char> > const&)    
>     0.1%    0.1%    libstdc++.6.dylib    std::basic_ios<char,
> std::char_traits<char> >::clear(std::_Ios_Iostate)    
>     0.0%    0.1%    libvkernel_ppc_debug.dylib
>    fbl::Environment::~Environment [not-in-charge]()    
>     0.1%    0.1%    libvkernel_ppc_debug.dylib
>    fbl::smart_ptr<fbl::vsql::I_Database>::smart_ptr[in-charge](fbl::vsql::I_Database*, bool)    
>     0.0%    0.1%    libvkernel_ppc_debug.dylib
>    fbl::smart_ptr<fbl::vsql::I_Cursor>::operator=(fbl::vsql::I_Cursor*)    
> 
> -- 
> Best regards,
> 
> Ruslan Zasukhin
> VP Engineering and New Technology
> Paradigma Software, Inc
> 
> Valentina - Joining Worlds of Information 
> http://www.paradigmasoft.com
> 
> [I feel the need: the need for speed]



More information about the antlr-interest mailing list