More info: the kp message said something about power and rails, so I disconnected everything, so it was on battery power, WiFi instead of LAN cable, no external display, but it still restarts automatically.
In earlier OSs, these behaviors could be influenced by changing "bootargs," or something like that from the command line, but now the restarts are dressed in kernel panic language.
Process: IDECacheDeleteAppExtension [610]
Path: /Applications/Xcode.app/Contents/PlugIns/IDECacheDeleteAppExtension.appex/Contents/MacOS/IDECacheDeleteAppExtension
Identifier: com.apple.dt.IDECacheDeleteAppExtension
Version: 1.0 (1)
Build Info: IDEFrameworks_IDECacheDeleteAppExtension-23275000000000000~1
App Item ID: 497799835
App External ID: 869020508
Code Type: ARM-64 (Native)
Parent Process: launchd [1]
User ID: 501
Date/Time: 2024-10-14 15:30:11.8943 -0700
OS Version: macOS 14.7 (23H124)
Report Version: 12
Anonymous UUID: 2E6EA53F-115C-EA59-EB03-9834EA17B804
This is a new behavior, as I mentioned. I can add the full text from the log, if it would be useful.