Skip to content

Instantly share code, notes, and snippets.

/-

Created October 12, 2017 23:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/47496363b7a4f15ffd57038492afb3e3 to your computer and use it in GitHub Desktop.
Save anonymous/47496363b7a4f15ffd57038492afb3e3 to your computer and use it in GitHub Desktop.
0000000000012120 <_Z14popcount_int32mPm>:
12120: 48 c1 ef 03 shr rdi,0x3
12124: 45 31 c0 xor r8d,r8d
12127: 31 c0 xor eax,eax
12129: 0f 1f 80 00 00 00 00 nop DWORD PTR [rax+0x0]
12130: 48 85 ff test rdi,rdi
12133: 74 42 je 12177 <_Z14popcount_int32mPm+0x57>
12135: ba 04 00 00 00 mov edx,0x4
1213a: 31 c9 xor ecx,ecx
1213c: 0f 1f 40 00 nop DWORD PTR [rax+0x0]
12140: f3 48 0f b8 0c ce popcnt rcx,QWORD PTR [rsi+rcx*8]
12146: 48 01 c1 add rcx,rax
12149: 8d 42 fd lea eax,[rdx-0x3]
1214c: f3 48 0f b8 04 c6 popcnt rax,QWORD PTR [rsi+rax*8]
12152: 48 01 c8 add rax,rcx
12155: 8d 4a fe lea ecx,[rdx-0x2]
12158: f3 48 0f b8 0c ce popcnt rcx,QWORD PTR [rsi+rcx*8]
1215e: 48 01 c1 add rcx,rax
12161: 8d 42 ff lea eax,[rdx-0x1]
12164: f3 48 0f b8 04 c6 popcnt rax,QWORD PTR [rsi+rax*8]
1216a: 48 01 c8 add rax,rcx
1216d: 89 d1 mov ecx,edx
1216f: 83 c2 04 add edx,0x4
12172: 48 39 cf cmp rdi,rcx
12175: 77 c9 ja 12140 <_Z14popcount_int32mPm+0x20>
12177: 48 85 ff test rdi,rdi
1217a: 74 4b je 121c7 <_Z14popcount_int32mPm+0xa7>
1217c: ba 04 00 00 00 mov edx,0x4
12181: 31 c9 xor ecx,ecx
12183: 66 66 66 66 2e 0f 1f data32 data32 data32 nop WORD PTR cs:[rax+rax*1+0x0]
1218a: 84 00 00 00 00 00
12190: f3 48 0f b8 0c ce popcnt rcx,QWORD PTR [rsi+rcx*8]
12196: 48 01 c1 add rcx,rax
12199: 8d 42 fd lea eax,[rdx-0x3]
1219c: f3 48 0f b8 04 c6 popcnt rax,QWORD PTR [rsi+rax*8]
121a2: 48 01 c8 add rax,rcx
121a5: 8d 4a fe lea ecx,[rdx-0x2]
121a8: f3 48 0f b8 0c ce popcnt rcx,QWORD PTR [rsi+rcx*8]
121ae: 48 01 c1 add rcx,rax
121b1: 8d 42 ff lea eax,[rdx-0x1]
121b4: f3 48 0f b8 04 c6 popcnt rax,QWORD PTR [rsi+rax*8]
121ba: 48 01 c8 add rax,rcx
121bd: 89 d1 mov ecx,edx
121bf: 83 c2 04 add edx,0x4
121c2: 48 39 cf cmp rdi,rcx
121c5: 77 c9 ja 12190 <_Z14popcount_int32mPm+0x70>
121c7: 41 83 c0 02 add r8d,0x2
121cb: 41 81 f8 10 27 00 00 cmp r8d,0x2710
121d2: 0f 85 58 ff ff ff jne 12130 <_Z14popcount_int32mPm+0x10>
121d8: c3 ret
121d9: 00 00 add BYTE PTR [rax],al
121db: 00 00 add BYTE PTR [rax],al
121dd: 00 00 add BYTE PTR [rax],al
...
00000000000121e0 <_Z14popcount_int64mPm>:
121e0: 41 56 push r14
121e2: 53 push rbx
121e3: 48 c1 ef 03 shr rdi,0x3
121e7: 4c 8d 57 ff lea r10,[rdi-0x1]
121eb: 49 c1 ea 02 shr r10,0x2
121ef: 45 8d 4a 01 lea r9d,[r10+0x1]
121f3: 41 83 e1 01 and r9d,0x1
121f7: 4d 8d 41 ff lea r8,[r9-0x1]
121fb: 4d 29 d0 sub r8,r10
121fe: 45 31 db xor r11d,r11d
12201: 31 c0 xor eax,eax
12203: eb 1b jmp 12220 <_Z14popcount_int64mPm+0x40>
12205: 66 66 2e 0f 1f 84 00 data32 nop WORD PTR cs:[rax+rax*1+0x0]
1220c: 00 00 00 00
12210: 31 c9 xor ecx,ecx
12212: 4d 85 c9 test r9,r9
12215: 0f 85 83 00 00 00 jne 1229e <_Z14popcount_int64mPm+0xbe>
1221b: e9 b8 00 00 00 jmp 122d8 <_Z14popcount_int64mPm+0xf8>
12220: 48 85 ff test rdi,rdi
12223: 0f 84 af 00 00 00 je 122d8 <_Z14popcount_int64mPm+0xf8>
12229: 4d 85 d2 test r10,r10
1222c: 74 e2 je 12210 <_Z14popcount_int64mPm+0x30>
1222e: 4d 89 c6 mov r14,r8
12231: 31 c9 xor ecx,ecx
12233: 66 66 66 66 2e 0f 1f data32 data32 data32 nop WORD PTR cs:[rax+rax*1+0x0]
1223a: 84 00 00 00 00 00
12240: f3 48 0f b8 1c ce popcnt rbx,QWORD PTR [rsi+rcx*8]
12246: 48 01 c3 add rbx,rax
12249: f3 48 0f b8 44 ce 08 popcnt rax,QWORD PTR [rsi+rcx*8+0x8]
12250: 48 01 d8 add rax,rbx
12253: f3 48 0f b8 5c ce 10 popcnt rbx,QWORD PTR [rsi+rcx*8+0x10]
1225a: f3 48 0f b8 54 ce 18 popcnt rdx,QWORD PTR [rsi+rcx*8+0x18]
12261: 48 01 c3 add rbx,rax
12264: 48 01 da add rdx,rbx
12267: f3 48 0f b8 44 ce 20 popcnt rax,QWORD PTR [rsi+rcx*8+0x20]
1226e: 48 01 d0 add rax,rdx
12271: f3 48 0f b8 54 ce 28 popcnt rdx,QWORD PTR [rsi+rcx*8+0x28]
12278: 48 01 c2 add rdx,rax
1227b: f3 48 0f b8 5c ce 30 popcnt rbx,QWORD PTR [rsi+rcx*8+0x30]
12282: f3 48 0f b8 44 ce 38 popcnt rax,QWORD PTR [rsi+rcx*8+0x38]
12289: 48 01 d3 add rbx,rdx
1228c: 48 01 d8 add rax,rbx
1228f: 48 83 c1 08 add rcx,0x8
12293: 49 83 c6 02 add r14,0x2
12297: 75 a7 jne 12240 <_Z14popcount_int64mPm+0x60>
12299: 4d 85 c9 test r9,r9
1229c: 74 3a je 122d8 <_Z14popcount_int64mPm+0xf8>
1229e: f3 48 0f b8 14 ce popcnt rdx,QWORD PTR [rsi+rcx*8]
122a4: 48 c1 e1 03 shl rcx,0x3
122a8: 48 01 c2 add rdx,rax
122ab: 48 89 c8 mov rax,rcx
122ae: 48 83 c8 08 or rax,0x8
122b2: f3 48 0f b8 04 06 popcnt rax,QWORD PTR [rsi+rax*1]
122b8: 48 01 d0 add rax,rdx
122bb: 48 89 ca mov rdx,rcx
122be: 48 83 ca 10 or rdx,0x10
122c2: f3 48 0f b8 14 16 popcnt rdx,QWORD PTR [rsi+rdx*1]
122c8: 48 01 c2 add rdx,rax
122cb: 48 83 c9 18 or rcx,0x18
122cf: f3 48 0f b8 04 0e popcnt rax,QWORD PTR [rsi+rcx*1]
122d5: 48 01 d0 add rax,rdx
122d8: 41 83 c3 01 add r11d,0x1
122dc: 41 81 fb 10 27 00 00 cmp r11d,0x2710
122e3: 0f 85 37 ff ff ff jne 12220 <_Z14popcount_int64mPm+0x40>
122e9: 5b pop rbx
122ea: 41 5e pop r14
122ec: c3 ret
122ed: 00 00 add BYTE PTR [rax],al
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment