octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Patch] FIrst experimental profiler


From: Daniel Kraft
Subject: [Patch] FIrst experimental profiler
Date: Thu, 30 Jun 2011 20:20:12 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-GB; rv:1.9.2.18) Gecko/20110616 Lightning/1.0b2 Thunderbird/3.1.11

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Jordi and all,

luckily, my holidays are drawing nearer -- and finally I have some more
time as before already.  Attached is my current working code for the
first experimental profiler.  It has still some serious deficiencies (no
really useful interface, probably the documentation of the defined
built-in functions is much, much too brief, no tests and also the
line/column numbering on anonymous functions does not work -- I have no
idea why, but put this aside for the moment).  But it also produces
already at least some results.  For instance, you can:

...start up octave...
profiler_enable (true);
...do some stuff...
profiler_enable (false);
data = profiler_data ();

to get a flat profile in as data-structure in data.  The idea is that
profiler_enable / profiler_data will be called from .m files which
provide the real, user-friendly interface to profiling later; but at the
moment those do not yet exist.  Also currently nothing more than a flat
profile is produced, which gives total "self" execution times of all
functions that were called.

Comments are very welcome -- especially as this is my first attempt at
actually writing some non-trivial code for GNU Octave.  Also, if anyone
has an idea what's going wrong with the line/column numbers, please let
me know!

Apart from that, my next plan as to look at how the "profile" function
of Matlab works and implement a similar interface based on the built-ins
already in my patch (and modify them if necessary, of course).

Yours,
Daniel

- -- 
http://www.pro-vegan.info/
- --
Done:  Arc-Bar-Cav-Kni-Ran-Rog-Sam-Tou-Val-Wiz
To go: Hea-Mon-Pri
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJODL5cAAoJEFJ+ebqjtTmYYo0P/As54d3Nr0QPdkuQ+MAIYd1Y
5BruhQf2lxPcWa3TJdIRw4MBF3RReGFaTJuqAdduUWMil9cL29qbky4bxVkN1uln
GPkozm/fKPYiaBmYDF5oTr9KlXho4UDuMk8tebo6+yvOSNEmHPGVktH9U3yFinCZ
d0eZ3deeixhYQIWHbCyv7qIGdIBii8LSEdrIBYhvDb4VuBsmqkYq8Gj6mV9T2ubX
vUu47YGTZp3+auOhNnnX8bS8srqpjV34AE+Ea21vbJfwriq94dfh+z+Kwqz8ROPh
O/YjqwOBHgLH+62OsQgQ50IAUjwvay5xjfkAbC1vKcNbelIOTkjzj2M+IlKnB6rS
2ol0x2qoxcajzyhOAHGPpQYFueuh1MlmRz9CAfFWPCmBOMgUOOVAPGBrMeISU7ks
gtazpTejqlxNpNd6r331wt+jMqmKWR+bcU0sGLxrh3jKOwHvMZMPqT+iWUCxNdpU
4ykC/GJxGF7R853gSXNfBLSGUi8LNnIB6IFzcHs6/9yHrQrvSPWg6gxQvGo6soth
2aBLRH+tzDKYAnPfuyTYbmpYN8/pa5o4OXX7e1nU34BuxZnsDJ7nuxUmKRto0Heo
p/fOKe38//uIXL0T4H25dMeAScaZDte4q8kOv85PahDjhFkS9nAUQmg327X0drcy
1RxTLP4eUVWQdOvsdOcj
=i1KI
-----END PGP SIGNATURE-----

Attachment: patch.diff
Description: Text document

Attachment: patch.diff.sig
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]