Why does my macOS always swap while sleeping?
csrutil enable will cause swapping mode reopen.

edit /System/Library/LaunchDaemons/com.apple.dynamic_pager.plist file to disable it;



then restart the SIP mode.
Disable standby, autopoweroff, ttyskeepawake, tcpkeepalive in pmset:

pmset -a standby 0
pmset -a autopoweroff 0
pmset -a ttyskeepawake 0
pmset -a tcpkeepalive 0