Terahertz operation of quantum-well intersubband hot-electron phototransistors