Skip to content

Instantly share code, notes, and snippets.

@msullivan

msullivan/kmod_mypyc.c Secret

Created May 21, 2020
Embed
What would you like to do?
char CPyDef_main(void) {
CPyTagged cpy_r_r0;
CPyTagged cpy_r_r1;
CPyTagged cpy_r_r2;
CPyTagged cpy_r_j;
char cpy_r_r3;
CPyTagged cpy_r_r4;
CPyTagged cpy_r_r5;
CPyTagged cpy_r_r6;
CPyTagged cpy_r_i;
char cpy_r_r7;
PyObject *cpy_r_r8;
PyObject *cpy_r_r9;
CPyTagged cpy_r_r10;
CPyTagged cpy_r_r11;
CPyTagged cpy_r_r12;
CPyTagged cpy_r_r13;
char cpy_r_r14;
char cpy_r_r15;
CPyL0: ;
cpy_r_r0 = 0;
cpy_r_r1 = 40;
cpy_r_r2 = cpy_r_r0;
cpy_r_j = cpy_r_r2;
CPyTagged_DecRef(cpy_r_j);
goto CPyL1;
CPyL1: ;
cpy_r_r3 = (Py_ssize_t)cpy_r_r2 < (Py_ssize_t)cpy_r_r1;
if (cpy_r_r3) {
goto CPyL2;
} else
goto CPyL7;
CPyL2: ;
cpy_r_r4 = 0;
cpy_r_r5 = 2000000;
cpy_r_r6 = cpy_r_r4;
cpy_r_i = cpy_r_r6;
goto CPyL3;
CPyL3: ;
cpy_r_r7 = (Py_ssize_t)cpy_r_r6 < (Py_ssize_t)cpy_r_r5;
if (cpy_r_r7) {
goto CPyL4;
} else
goto CPyL9;
CPyL4: ;
cpy_r_r8 = CPyTagged_StealAsObject(cpy_r_i);
cpy_r_r9 = PyObject_Str(cpy_r_r8);
CPy_DecRef(cpy_r_r8);
if (unlikely(cpy_r_r9 == NULL)) {
CPy_AddTraceback("kmod.py", "main", 4, CPyStatic_globals);
goto CPyL8;
} else
goto CPyL10;
CPyL5: ;
cpy_r_r10 = 2;
cpy_r_r11 = cpy_r_r6 + cpy_r_r10;
cpy_r_r6 = cpy_r_r11;
cpy_r_i = cpy_r_r11;
goto CPyL3;
CPyL6: ;
cpy_r_r12 = 2;
cpy_r_r13 = cpy_r_r2 + cpy_r_r12;
cpy_r_r2 = cpy_r_r13;
cpy_r_j = cpy_r_r13;
CPyTagged_DecRef(cpy_r_j);
goto CPyL1;
CPyL7: ;
cpy_r_r14 = 1; /* None */
return cpy_r_r14;
CPyL8: ;
cpy_r_r15 = 2;
return cpy_r_r15;
CPyL9: ;
CPyTagged_DecRef(cpy_r_i);
goto CPyL6;
CPyL10: ;
CPy_DecRef(cpy_r_r9);
goto CPyL5;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment