GC Alloc when using a Evaluate Graph as an Update Service Node

Forum rules
Please confirm before reporting
  • Please confirm in advance that it is a problem with LogicToolkit and not with Unity itself, other assets, or the user's project.
  • Please confirm that the problem occurs in a project with the smallest possible configuration and clarify how to reproduce it.
  • Please check if it is described in Known Issues.

Information required to report a bug
  • Logic Toolkit version
  • Unity version
  • How to reproduce

=======

報告する前の確認のお願い
  • Unity本体や他のアセット、ユーザーのプロジェクト側による問題ではなくLogicToolkitの問題であることを事前に確認してください。
  • 可能な限り最小構成のプロジェクトで問題の発生を確認し、再現方法を明確にしてください。
  • 既知の問題に記述されているかを確認してください。

バグを報告するために必要な情報
  • Logic Toolkit バージョン
  • Unity バージョン
  • 再現方法

=======

We accept posts in languages ​​other than English and Japanese, but replies will be sent via machine translation.
Thank you for your understanding.
FunctionOverflu
Posts: 16
Joined: 2025/03/29 09:07

GC Alloc when using a Evaluate Graph as an Update Service Node

Post by FunctionOverflu »

Logic Toolkit version: 1.10.1
Unity: 6000.1.2f1
How to reproduce:

1. Create a logic behaviour in an empty scene
2. Create a Evaluate Graph in the logic editor that does nothing
3. Use the newly created Evaluate Graph as an action run by a Service Node with Methods set to OnUpdate
4. Spot the allocation every frame in the profiler
Hierarchy_Profiler.png
Hierarchy_Profiler.png (98 KiB) Viewed 9243 times
ServiceNodeUpdate.png
ServiceNodeUpdate.png (40.69 KiB) Viewed 9243 times
User avatar
caitsithware
管理人
Posts: 130
Joined: 2024/03/26 01:56

Re: GC Alloc when using a Evaluate Graph as an Update Service Node

Post by caitsithware »

Thank you for reporting this.

I checked and was able to reproduce the issue.
Since it is not considered urgent, we will fix it together with other updates.

Temporary solution
  1. Open Packages/com.caitsithware.logictoolkit/Runtime/Graph/Objects/SubGraphObject.cs in a code editor
  2. Comment out the code from lines 58 to 61 as follows

    Code: Select all

    //if (pool.Count == 0)
    //{
    // s_Pools.Remove(nodeGraphData);
    //}
Post Reply