move qthread struct into proc.h