Laggy/Freezing frames when people leave group #161


  • Defect
  • Fixed
Closed
Assigned to _ForgeUser117147
  • coaleyed created this issue Apr 23, 2010

    What steps will reproduce the problem?
    1. Self explanatory.
    2. Seems to have returned from earlier 400 versions, started when i D/L v512.
    3.

    What is the expected output? What do you see instead?
    Maybe some lag, but not a small lock up.

    What version of the product are you using?
    517 currently.

    Do you have an error log of what happened?
    No crashes, no logs.  Just a performance issue.

    Please provide any additional information below.

  • coaleyed added the tags New Defect Apr 23, 2010
  • _ForgeUser65911 posted a comment Apr 24, 2010

    Yes I noticed recently that it is creating stuff from scratch like mad whenever the raid size changes. This needs a good working over along with the reloading during combat only showing 1 group bug.

  • _ForgeUser65911 removed a tag New Apr 24, 2010
  • _ForgeUser65911 added a tag Accepted Apr 24, 2010
  • _ForgeUser4684987 posted a comment Sep 4, 2010

    GridFrame.lua line 25

    if (name == "unit") then
    	if value then
    		local unit = SecureButton_GetModifiedUnit(self)
    		self.unit = unit
    
    		Grid2Frame:Debug("updated", self:GetName(), name, value, unit)
    		Grid2Frame:UpdateIndicators(self)
    		Grid2:SetFrameUnit(self, unit)
    

    I added a counter to check how many times it goes through this when someone joins a 40man raid, and made it output it to a chatframe. The counter said 77 times when _one_ joins. That doesnt seem right that it has to update 77 units when one joins. This is really ruining my pvp atm, I hope there is a quick solution.

    I'm using r529 atm.

    Edit: With the counter starting @ zero when I joined Isle of Conquest, when the gates opened 70seconds later the counter had hit 2000 already (with 39man in the raid). I do hope some of these loops can be avoided.

    The counter I added was

    ChatFrame3:AddMessage("CounterPriv: "..CounterPriv..". "..value.." "..unit)
    

    The output when one joined a 40man raid was;

    [20:28:27] CounterPriv: 6726. raid1 raid1
    [20:28:27] CounterPriv: 6727. raid5 raid5
    [20:28:27] CounterPriv: 6728. raid3 raid3
    [20:28:27] CounterPriv: 6729. raid4 raid4
    [20:28:27] CounterPriv: 6730. raid2 raid2
    [20:28:27] CounterPriv: 6731. raid10 raid10
    [20:28:27] CounterPriv: 6732. raid9 raid9
    [20:28:27] CounterPriv: 6733. raid7 raid7
    [20:28:27] CounterPriv: 6734. raid8 raid8
    [20:28:27] CounterPriv: 6735. raid6 raid6
    [20:28:27] CounterPriv: 6736. raid39 raid39
    [20:28:27] CounterPriv: 6737. raid13 raid13
    [20:28:27] CounterPriv: 6738. raid12 raid12
    [20:28:27] CounterPriv: 6739. raid14 raid14
    [20:28:27] CounterPriv: 6740. raid11 raid11
    [20:28:27] CounterPriv: 6741. raid16 raid16
    [20:28:27] CounterPriv: 6742. raid18 raid18
    [20:28:27] CounterPriv: 6743. raid19 raid19
    [20:28:27] CounterPriv: 6744. raid17 raid17
    [20:28:27] CounterPriv: 6745. raid15 raid15
    [20:28:27] CounterPriv: 6746. raid21 raid21
    [20:28:27] CounterPriv: 6747. raid23 raid23
    [20:28:27] CounterPriv: 6748. raid20 raid20
    [20:28:27] CounterPriv: 6749. raid22 raid22
    [20:28:27] CounterPriv: 6750. raid24 raid24
    [20:28:27] CounterPriv: 6751. raid28 raid28
    [20:28:27] CounterPriv: 6752. raid29 raid29
    [20:28:27] CounterPriv: 6753. raid25 raid25
    [20:28:27] CounterPriv: 6754. raid26 raid26
    [20:28:27] CounterPriv: 6755. raid27 raid27
    [20:28:27] CounterPriv: 6756. raid34 raid34
    [20:28:27] CounterPriv: 6757. raid33 raid33
    [20:28:27] CounterPriv: 6758. raid30 raid30
    [20:28:27] CounterPriv: 6759. raid32 raid32
    [20:28:27] CounterPriv: 6760. raid31 raid31
    [20:28:28] CounterPriv: 6761. raid35 raid35
    [20:28:28] CounterPriv: 6762. raid36 raid36
    [20:28:28] CounterPriv: 6763. raid38 raid38
    [20:28:28] CounterPriv: 6764. raid37 raid37
    [20:28:28] CounterPriv: 6765. raid1 raid1
    [20:28:28] CounterPriv: 6766. raid5 raid5
    [20:28:28] CounterPriv: 6767. raid3 raid3
    [20:28:28] CounterPriv: 6768. raid4 raid4
    [20:28:28] CounterPriv: 6769. raid2 raid2
    [20:28:28] CounterPriv: 6770. raid10 raid10
    [20:28:28] CounterPriv: 6771. raid9 raid9
    [20:28:28] CounterPriv: 6772. raid7 raid7
    [20:28:28] CounterPriv: 6773. raid8 raid8
    [20:28:28] CounterPriv: 6774. raid6 raid6
    [20:28:28] CounterPriv: 6775. raid39 raid39
    [20:28:28] CounterPriv: 6776. raid13 raid13
    [20:28:28] CounterPriv: 6777. raid12 raid12
    [20:28:28] CounterPriv: 6778. raid14 raid14
    [20:28:28] CounterPriv: 6779. raid11 raid11
    [20:28:28] CounterPriv: 6780. raid16 raid16
    [20:28:28] CounterPriv: 6781. raid18 raid18
    [20:28:28] CounterPriv: 6782. raid19 raid19
    [20:28:28] CounterPriv: 6783. raid17 raid17
    [20:28:28] CounterPriv: 6784. raid15 raid15
    [20:28:28] CounterPriv: 6785. raid21 raid21
    [20:28:28] CounterPriv: 6786. raid23 raid23
    [20:28:28] CounterPriv: 6787. raid20 raid20
    [20:28:28] CounterPriv: 6788. raid22 raid22
    [20:28:28] CounterPriv: 6789. raid24 raid24
    [20:28:28] CounterPriv: 6790. raid28 raid28
    [20:28:28] CounterPriv: 6791. raid29 raid29
    [20:28:28] CounterPriv: 6792. raid25 raid25
    [20:28:28] CounterPriv: 6793. raid26 raid26
    [20:28:28] CounterPriv: 6794. raid27 raid27
    [20:28:28] CounterPriv: 6795. raid34 raid34
    [20:28:28] CounterPriv: 6796. raid33 raid33
    [20:28:28] CounterPriv: 6797. raid30 raid30
    [20:28:28] CounterPriv: 6798. raid32 raid32
    [20:28:28] CounterPriv: 6799. raid31 raid31
    [20:28:28] CounterPriv: 6800. raid35 raid35
    [20:28:28] CounterPriv: 6801. raid36 raid36
    [20:28:28] CounterPriv: 6802. raid38 raid38
    [20:28:28] CounterPriv: 6803. raid37 raid37
    

    And this is just the ones beeing updated, there are many many more beeing removed(I noticed when using the Grid2Frame debugger), but my counter doesnt count those.

    77updates when one joins :)

    By the looks of the output, Grid2 updates every frame twice when one joins.

    ..maybe add queue system that will only allow Grid2 to update 6 frames per second. Each 1/6 second a frame may be updated, if the queue gets higher than 30(5sec delay) the end of it is purged. And with a queue system like that, it will also be possible to let the user choose the frequency he/she wants Grid2 to update frames. ..maybe? :) ( http://www.wowwiki.com/Using_OnUpdate_correctly )


    Edited Sep 4, 2010
  • _ForgeUser4684987 posted a comment Sep 4, 2010

    Sorry for posting twice in a row, but I felt this needed its own post. When I exited AV (40man raid) I got this output;

    [22:16:39] removed: 990. Grid2LayoutHeader2UnitButton8
    [22:16:39] removed: 991. Grid2LayoutHeader2UnitButton9
    [22:16:39] removed: 992. Grid2LayoutHeader2UnitButton10
    [22:16:39] removed: 993. Grid2LayoutHeader2UnitButton11
    [22:16:39] removed: 994. Grid2LayoutHeader2UnitButton12
    [22:16:39] removed: 995. Grid2LayoutHeader2UnitButton13
    [22:16:39] removed: 996. Grid2LayoutHeader2UnitButton14
    [22:16:39] removed: 997. Grid2LayoutHeader2UnitButton15
    (...)
    [22:16:40] removed: 1631. Grid2LayoutHeader3UnitButton1
    [22:16:40] removed: 1632. Grid2LayoutHeader3UnitButton2
    [22:16:40] removed: 1633. Grid2LayoutHeader3UnitButton3
    [22:16:40] removed: 1634. Grid2LayoutHeader3UnitButton4
    [22:16:40] removed: 1635. Grid2LayoutHeader3UnitButton5
    [22:16:40] removed: 1636. Grid2LayoutHeader3UnitButton6
    [22:16:40] removed: 1637. Grid2LayoutHeader3UnitButton7
    [22:16:40] removed: 1638. Grid2LayoutHeader3UnitButton8
    [22:16:40] removed: 1639. Grid2LayoutHeader3UnitButton9
    [22:16:40] removed: 1640. Grid2LayoutHeader3UnitButton10
    [22:16:40] removed: 1641. Grid2LayoutHeader3UnitButton11
    [22:16:40] removed: 1642. Grid2LayoutHeader3UnitButton12
    [22:16:40] removed: 1643. Grid2LayoutHeader3UnitButton13
    [22:16:40] removed: 1644. Grid2LayoutHeader3UnitButton14
    [22:16:40] removed: 1645. Grid2LayoutHeader3UnitButton15
    (...)
    [22:16:40] removed: 1886. Grid2LayoutHeader3UnitButton1
    [22:16:40] removed: 1887. Grid2LayoutHeader3UnitButton2
    [22:16:40] removed: 1888. Grid2LayoutHeader3UnitButton3
    [22:16:40] removed: 1889. Grid2LayoutHeader3UnitButton4
    [22:16:40] removed: 1890. Grid2LayoutHeader3UnitButton5
    [22:16:40] removed: 1891. Grid2LayoutHeader3UnitButton6
    [22:16:40] removed: 1892. Grid2LayoutHeader3UnitButton7
    [22:16:40] removed: 1893. Grid2LayoutHeader3UnitButton8
    [22:16:40] removed: 1894. Grid2LayoutHeader3UnitButton9
    [22:16:40] removed: 1895. Grid2LayoutHeader3UnitButton10
    [22:16:40] removed: 1896. Grid2LayoutHeader3UnitButton11
    [22:16:40] removed: 1897. Grid2LayoutHeader3UnitButton12
    [22:16:40] removed: 1898. Grid2LayoutHeader3UnitButton13
    [22:16:40] removed: 1899. Grid2LayoutHeader3UnitButton14
    [22:16:40] removed: 1900. Grid2LayoutHeader3UnitButton15
    

    with the code;

    ChatFrame3:AddMessage("removed: "..bCounter..". "..self:GetName())
    

    inside "else" in the "GridFrameEvents:OnAttributeChanged(name, value)" function.

    I removed some of the lines, but as you can see from the count, its 910/2 = 455 per second when exiting AV. 269 loops where its seems Grid2LayoutHeader3UnitButton1 -> Grid2LayoutHeader3UnitButton15 is beeing removed, and honestly that should get done in 15 loops :)

    I wish I knew more about luaprogramming so I could help more. This optimizing of grid is just awesome that you guys do. Thanks alot!


    Edited Sep 4, 2010
  • _ForgeUser117147 posted a comment Sep 9, 2010

    Submitted a patch in Rev 530 that should help.

    Note that the event handler is called by Blizzard API, so I have no control over how many time it is called. I can however try to reduce to a minimum the amount of processing done when it is called, which is exactly what rev530 is about.

    Please reopen this ticket if the fix is not sufficient.

  • _ForgeUser117147 removed a tag Accepted Sep 9, 2010
  • _ForgeUser117147 added a tag Fixed Sep 9, 2010

To post a comment, please login or register a new account.