Last change
on this file since 20690 was 20690, checked in by Mathieu Morlighem, 9 years ago |
NEW: marhsall strings instead of enums
|
File size:
888 bytes
|
Rev | Line | |
---|
[19753] | 1 | //DEBUG class definition
|
---|
| 2 | //
|
---|
| 3 | // Usage:
|
---|
| 4 | // debug=new debug();
|
---|
| 5 |
|
---|
| 6 | function debug (){
|
---|
| 7 | //methods
|
---|
| 8 | this.setdefaultparameters = function(){// {{{
|
---|
| 9 | }// }}}
|
---|
[19791] | 10 | this.classname= function(){// {{{
|
---|
| 11 | return "debug";
|
---|
| 12 | }// }}}
|
---|
[19753] | 13 | this.disp= function(){// {{{
|
---|
| 14 | console.log(sprintf(' debug parameters:'));
|
---|
| 15 | console.log(sprintf(' debug parameters:'));
|
---|
| 16 |
|
---|
| 17 | fielddisplay(this,'valgrind','use Valgrind to debug (0 or 1)');
|
---|
| 18 | fielddisplay(this,'gprof','use gnu-profiler to find out where the time is spent');
|
---|
| 19 | fielddisplay(this,'profiling','enables profiling (memory, flops, time)');
|
---|
| 20 |
|
---|
| 21 | }// }}}
|
---|
[19791] | 22 | this.marshall=function(md,fid) { //{{{
|
---|
[20690] | 23 | WriteData(fid,prefix,'object',this,'fieldname','profiling','format','Boolean');
|
---|
[19791] | 24 | }//}}}
|
---|
[19860] | 25 | this.fix=function() { //{{{
|
---|
| 26 | }//}}}
|
---|
| 27 |
|
---|
[19753] | 28 | //properties
|
---|
| 29 | // {{{
|
---|
| 30 | this.valgrind = false;
|
---|
| 31 | this.gprof = false;
|
---|
| 32 | this.profiling = false;
|
---|
| 33 | this.setdefaultparameters();
|
---|
| 34 | //}}}
|
---|
| 35 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.