#35408: Optimize post-migrate permission creation
-------------------------------------+-------------------------------------
     Reporter:  Adam Johnson         |                    Owner:  Adam
         Type:                       |  Johnson
  Cleanup/optimization               |                   Status:  assigned
    Component:  contrib.auth         |                  Version:  dev
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  1
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Comment (by Adam Johnson):

 I repeated the profiling with the latest version of the patch, on top of
 the latest `main` commit. The numbers are similar.

 Before optimization stats:

 * Total 12,387,798 function calls taking 5.589 seconds.
 * 88 calls to create_permissions() take 483ms, ~8.6% of the total time.

 After optimization stats:

 * Total 11,797,519 function calls taking 5.207 seconds.
 * 88 calls to create_permissions() take 241ms, ~4.6% of the total time.
 * 590,279 function calls and 242ms saved.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/35408#comment:2>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018f4023ddd8-1cf5e084-7bd8-4595-af69-02ffdcf67a2e-000000%40eu-central-1.amazonses.com.

Reply via email to