Is there a reason why quick_add_integer_constant takes a char* and a length, instead of a (much quicker and cleaner) struct pike_string* which would enable it to work more efficiently in collaboration with MK_STRING() ?
The quick* functions in program.c are typically called via the corresponding ADD_*() macros (in this case ADD_INT_CONSTANT()). The "quick" in the name has mostly to do with the string-lengths being calculated statically, and probably ought to have been "simple", since the functions are intended to be easy to use from C-code.
If you already have a struct pike_string, you would probably want to call add_constant() directly rather than {quick_,}add_integer_constant().
I see that the functions do not seem to be used anywhere, so I propose to change the (internal) interface definition for them to actually make them quick.
It seems you missed that it is used by the ADD_INT_CONSTANT() macro, there's quite a few uses of ADD_INT_CONSTANT() in eg builtin_functions.c and modules/system/*.c.