On 22/01/2014, at 6:54 AM, srean wrote: > I usually pass the -pg flag to enable profiling, but that will generate stats > for the C++ functions. > > If there was a way to partially map the C++ functions to Felix code, that > would be very useful.
Of course .. its called "read the C++ code". There are comments in there indicating what's what. There's also a switch to flxg which adds a lot more comments that are normally suppressed because 70% of the output ends up as "informatory comments" if its on :) Felix "functions" don't have their original names because (a) they map to C++ classes (as a last resort) and class names don't overload and (b) because they can be polymorphic (and C++ templates are currently useless and will remain so until the ISO committee allows template arguments to be incomplete types). and (c) Felix has currying etc .. So for these reasons, we have to invent new names for functions and types. Felix does try to make the mapping possible. Generally the horrible names used refer back to declarations which are annotated with comments about their origin in the Felix code. There's a similar problem with typesafe linkage. We can't use it when we want DLLs because until C++ has a standard function to convert a function to a mangled name (as a string) you cannot "dlsym()" a C++ function. Actually most platforms do have a mangler API (otherwise compiler writers would be screwed). So basically .. profiling is tricky in the best of cases, and with Felix it is even harder. Sorry! I don't see any good way around this. However I'm open to any suggestions on ways to provide "some kind of performance measurement tools" as opposed to "profiling". The latter is a comprehensive system, the former is more some "hinting". For example use FLX_REPORT_COLLECTIONS=1 environment variable to see each garbage collection trigger. For many programs, tuning the GC is vital for performance. And not something I really understand how to do either! We can also use "tracing" to "count" executions. That's not the same as timing them but its a good indicator IMHO. -- john skaller skal...@users.sourceforge.net http://felix-lang.org ------------------------------------------------------------------------------ CenturyLink Cloud: The Leader in Enterprise Cloud Services. Learn Why More Businesses Are Choosing CenturyLink Cloud For Critical Workloads, Development Environments & Everything In Between. Get a Quote or Start a Free Trial Today. http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk _______________________________________________ Felix-language mailing list Felix-language@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/felix-language