[Samsung Galaxy Nexus] breversa:
Hi [MENTION=1111361]gabrielex[/MENTION],

Sorry that you're having the same problem, but I'm glad I'm not alone ! ^^

I also experience hard freezes and random reboots. They seem to appear when the phone has "lots to do", especially when turning airplane mode off or getting back somewhere with data connection after being in a no service area for a few hours. The phone would become irresponsive for tens of seconds and even minutes, then poof!, soft reboot (and soft reboots with the Galaxy Nexus means SIM card not detected).

I sometimes experience "Android UI" ANR (Application Not Responding).

I'm also not using any Facebook app. However, I'm using the Xposed framework with several modules, microG Unified NLP backend, AFWall+, and all my apps have privacy protection enabled. Pico GApps are installed and severely restricted.

Play Services and Signal Messenger have battery optimization disabled.

I started using OS Monitor (https://fossdroid.com/a/os-monitor.html) to check CPU and I/O usage, but fail to see anything relevant : CPU rarely goes above 50%. It usually stays around 5-30%, with "Android system" and "System interface" (ksmd a bit also) apps/processes being the highest offenders. I feel that it's the UI that's somehow slows down to a crawl (background processes seem to do fine actually) then either freezes or makes the phone reboot, but I can bring no proof of that.

What else can I say ?

I'm currently using build 13.0-20160820-SNAPSHOT-ZNH5YAO0J5-maguro, but the sluggishness/lagginess/chopiness/irresponsiveness started with previous builds already.

I get lots of fatal logcat messages originating from a DEBUG app :

09-24 15:40:21.830 F/DEBUG (171): CM Version: '13.0-20160820-SNAPSHOT-ZNH5YAO0J5-maguro'
09-24 15:40:21.830 F/DEBUG (171): Build fingerprint: 'google/yakju/maguro:4.3/JWR66Y/776638:user/release-keys'
09-24 15:40:21.830 F/DEBUG (171): Revision: '0'
09-24 15:40:21.830 F/DEBUG (171): ABI: 'arm'
09-24 15:40:21.830 F/DEBUG (171): pid: 7971, tid: 7971, name: busybox >>> busybox <<<
09-24 15:40:21.830 F/DEBUG (171): signal 13 (SIGPIPE), code 0 (SI_USER), fault addr --------
09-24 15:40:21.832 F/DEBUG (171): r0 ffffffe0 r1 404eb000 r2 000000b7 r3 00000888
09-24 15:40:21.832 F/DEBUG (171): r4 4020c478 r5 000000b7 r6 404eb000 r7 00000004
09-24 15:40:21.832 F/DEBUG (171): r8 401a9a15 r9 00000001 sl 00000000 fp 0000000c
09-24 15:40:21.832 F/DEBUG (171): ip 000000b7 sp bede6990 lr 401db37f pc 401d5798 cpsr 000d0010
09-24 15:40:21.857 F/DEBUG (171):
09-24 15:40:21.857 F/DEBUG (171): backtrace:
09-24 15:40:21.857 E/DEBUG (171): AM write failed: Broken pipe
09-24 15:40:21.857 F/DEBUG (171): #00 pc 00042798 /system/lib/libc.so (write+12)
09-24 15:40:21.857 F/DEBUG (171): #01 pc 0004837b /system/lib/libc.so (__swrite+70)
09-24 15:40:21.857 F/DEBUG (171): #02 pc 00037d89 /system/lib/libc.so (__sflush+48)
09-24 15:40:21.857 F/DEBUG (171): #03 pc 00037bdf /system/lib/libc.so (fclose+58)
09-24 15:40:21.858 F/DEBUG (171): #04 pc 00016a2b /system/lib/libc.so (_ZL16malloc_fini_implv+22)
09-24 15:40:21.858 F/DEBUG (171): #05 pc 000406a5 /system/lib/libc.so (pthread_once+54)
09-24 15:40:21.858 F/DEBUG (171): #06 pc 0001735f /system/lib/libc.so (malloc_debug_fini+10)
09-24 15:40:21.858 F/DEBUG (171): #07 pc 0004854b /system/lib/libc.so (__cxa_finalize+138)
09-24 15:40:21.858 F/DEBUG (171): #08 pc 000166cb /system/lib/libc.so (exit+10)
09-24 15:40:21.858 F/DEBUG (171): #09 pc 0000727b /system/xbin/busybox
09-24 15:40:21.917 F/DEBUG (171):
09-24 15:40:21.917 F/DEBUG (171): Tombstone written to: /data/tombstones/tombstone_00

TL;DR :

I don't have the slightest relevant hint about what makes my phone become almost unusable. :(

I'll give it a try a few more days (pleas tell me if I can provide any more information), then clean-flash it again to see if it helps.