separated into proc.h and proc.cpp