https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119210
--- Comment #5 from xiezhiheng at huawei dot com --- (In reply to Andrew Pinski from comment #3) > So: > mrs x16, tpidr2_el0 > cbnz x16, .L22 <== it will branch to .L22, and miss 'smstart za' > mov x0, x3 > smstart za > bl __arm_tpidr2_restore > .L22: > > > This means it is already started. > > > What kernel version are you using? Could this be a bug in the kernel not > saving/restoring tpidr2_el0 correctly or setting tpidr2_el0 to zero > originally. And I am using kernel 5.10 (5.10.0-216.0.0.115.oe2203sp4.aarch64 openEuler 22.03 (LTS-SP4))