Search Issue Tracker
Fixed in 2022.2.X
Fixed in 2020.3.X, 2021.2.X
Votes
0
Found in
2020.3
2020.3.21f1
2021.2
2022.1
Issue ID
1387295
Regression
Yes
AddComponent's general performance is worse in 2020.3 and above when compared to 2019.4
Reproduction steps:
1. Open the attached project "AddComponent_2019.4.23.zip"
2. Switch the platform target to Android, and enable Development Build
3. Build and Run on the project on a device
4. Open the Profiler window and attach it to the Android process running on the device and monitor the CPU usage module with the Timeline view selected
5. Select the 'Start' button on the screen of the device and wait until the button will be replaced from "Start" to "Reset"
6. Pause the process in the Profiler and notice a spike on the timeline that lasts 2 frames
7. Select the first frame of the spike and note on the Main Thread on the below Timeline that many AddComponent calls occur in groups of 2 (e.g group one is 1st and 2nd call of T1, group 2 is T2, etc).
8. Notice the time difference between the 1st and 2nd call of AddComponent on the same script (Please refer to attached profiler screenshot '2019_T_AddComponents.png' for visual representation)
9. Open the attached project "AddComponent_2020.zip" and repeat the steps from step 2
10. Notice the time difference between the 1st and 2nd call of AddComponent on the same script (Visual representation found in the 2020 screenshots)
Expected result: The time AddComponent takes to process, and the time subsequent calls to add the same script remain consistent between versions.
Actual result: The time AddComponent takes to process, and the time subsequent calls to add the same script both take considerably longer on 2020.3 and the reduction in time for the 2nd call to an already loaded script is not as effective as shown in the attached screenshots.
Reproducible with: 2020.3.24f, 2021.2.6f1, 2022.1.0b1
Not reproducible with: 2019.4.33f1
Tested the issue with:
----------, Huawei - (ELS-NX9), Android 10, CPU: NOT FOUND, GPU: Mali-G76
Notes:
-Screenshots are attached in the "ProfilerScreenshots.zip"
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Objects with Universal Render Pipeline/Particles/Lit shader are always lit up when changing their Rendering Layer Mask
- PolySpatial “Trying to set shader on a Material Variant.” error is printed in the console when entering Play Mode
- Error “Shader error in 'YSCloudCover': call to 'tex3D' is ambiguous at Assets/YSCloudCoverText.shader(606) (on d3d11)“ is present when compiling tex3D shader with DXC
- Placeholder asset is not loaded with Advertisement Legacy sample when using the latest version of the package
- Addressables content build fails but the Player build is successful when building a development build
Resolution Note (fix version 2022.2):
Fixed in 2022.1.0a13
Resolution Note (fix version 2021.2):
Fixed in 2021.2.17f1
Resolution Note (fix version 2020.3):
Fixed in 2020.3.31f1