Descriptiongiven this code:
class A:
def f(self):
pass
Jeff suggested fix up the name in compiler_function so that c->u->u_name = 'A.f' instead of 'f'. This change does make it all the way through into the code object created by assemble(), such that co->co_name = 'A.f'. This also makes it all the way through to the "py::LlvmFunctionBuilder fbuilder(global_data, code);" line in _PyCode_ToLlvmIr() such that the name sent into Function::Create() is 'A.f'.
I've manually stepped through the compiler/assemble functions a few times and things seem to be working as expected.
However, when I try testing this with "sudo opcontrol --reset; sudo opcontrol --start-daemon; sudo opcontrol --start; PYTHONPATH=../tests/lib/django/ ./python ../tests/performance/bm_django.py -n 100; sudo opcontrol --stop", and then "opreport -g -l ./python |less", the results still show things like #render5.
I'm not really sure where to look next in order to figure out why what is coming out of the profiler doesn't match the name we are setting up in the code object. Collin suggested I upload this patch now so folks can take a look.
Patch Set 1 #
MessagesTotal messages: 1
|