在Unity中进行速度和GC Alloc的测试 测试脚本: using UnityEngine; using System; using System.Collections; using System.Diagnostics; public class NullableTest : MonoBehaviour { void Start() { Stopwatch stopwatch = new Stopwatch(); stopwatch.Start(); ; i < ; i++) { int…