Excessively inefficient source code modifications
Jesús Díaz Vico <[email protected]>
| Newsgroups | gmane.comp.multimedia.ogg.vorbis.devel |
|---|---|
| Message-ID | <[email protected]> |
Hello, I've made some changes in the libvorbis-1.2.3 source code to introduce some functionality I need for a project I'm working on. For compilation, besides including some macro definitions I need to pass to the C preprocessor, and linking with the math library somewhere (and including the source files I've implemented, of course) I've made no big changes in the Makefile or configure scripts. But when I run my modified oggenc program, the execution time becames excessive (for coding 2 secs of audio it spents approximately 2 mins, with default parameters). The modifications I've made consist basically in some extra computation involving the residual vectors (so it executes once for each residue vector). I've measured independently the average time for the whole extra code and it takes approximately 0.00012 secs per call (so that would make roughly 0.00012*channels*frames extra encoding time for an audio file). Despite I've re-re-rechecked my code and I haven't found anything strange, I don't discard at all that may be there are some algorithmic errors left that may make my code be a bit inefficient, but making 2 secs go to 2 mins is quite alarming and far away from permissible. Supposing I have no important algorithmic errors, could this excessive overload be caused by a compiling issue? (that wouldn't surprise me, as my knowledge about autoconf/automake/make scripts is quite basic...). I'd just like to discard the fact of having a compilation issue before starting another intensive and detailed analysis of the code. If after another bunch of extra hours and thousands of code lines rechecked, I find that it was a compilation issue, I might be forced to make a pilgrimage to the Himalayas to find myself or something... ;) Thank you all.