CodeTools[Profiling] - Maple Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Profiling : CodeTools[Profiling] : CodeTools/Profiling/Merge

CodeTools[Profiling]

  

Merge

  

merge tables of profiling data into a single table

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

Merge(tab1, tab2, ..., filename1, filename2, ...)

Parameters

tab1, tab2, ...

-

(optional) table

filename1, filename2, ...

-

(optional) filename

Description

• 

The Merge(tab1, tab2, ...) command combines the specified tables, tab1, tab2, ..., of profiling data together into a single table.

• 

The Merge(filename1, filename2, ...) command reads the profiling data from the specified files, filename1, filename2, ..., and combines it into a single table.

• 

The Merge(tab1, tab2, ..., filename1, filename2, ...) command reads the profiling data from the specified tables, tab1, tab2, ..., and the specified files, filename1, filename2, ..., and combines it into a single table.

• 

Procedures that appear more than once have their data summed.

  

If no parameters are specified, Merge raises an error.

Examples

a := proc(x)
    if (x > 1) then
        return 1;
    else
        return 0;
    end if;
end proc:

withCodeTools[Profiling]:

t1Buildprocs=a,commands='a0',commands='a2'

t1:=table_Inert_ASSIGNEDNAMEa,PROC=206206100100

(1)

PrintProfilest1

a
a := proc(x)
     |Calls Seconds  Words|
PROC |    2   0.000      6|
   1 |    2   0.000      6| if 1 < x then
   2 |    1   0.000      0|   return 1
                            else
   3 |    1   0.000      0|   return 0
                            end if
end proc

t2Buildprocs&equals;a&comma;commands&equals;&apos;a0&apos;&comma;commands&equals;&apos;a2&apos;&comma;&apos;a1&apos;

t2:=table_Inert_ASSIGNEDNAMEa&comma;PROC&equals;309309100200

(2)

PrintProfilest2

a
a := proc(x)
     |Calls Seconds  Words|
PROC |    3   0.000      9|
   1 |    3   0.000      9| if 1 < x then
   2 |    1   0.000      0|   return 1
                            else
   3 |    2   0.000      0|   return 0
                            end if
end proc

tMerget1&comma;t2

t:=table_Inert_ASSIGNEDNAMEa&comma;PROC&equals;50155015200300

(3)

PrintProfilest

a
a := proc(x)
     |Calls Seconds  Words|
PROC |    5   0.000     15|
   1 |    5   0.000     15| if 1 < x then
   2 |    2   0.000      0|   return 1
                            else
   3 |    3   0.000      0|   return 0
                            end if
end proc

See Also

CodeTools[Profiling]

CodeTools[Profiling][Build]

CodeTools[Profiling][GetProfileTable]

CodeTools[Profiling][PrintProfiles]

CodeTools[Profiling][Profile]

CodeTools[Profiling][SaveProfiles]

 


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam