Taraji P. Henson jokingly asked Nia Long if she was on her period after she went nuts on a fellow cast member ... and that's what set off their raging feud on the set of "Empire."
Production sources tell TMZ ... Nia showed up late shortly after beginning her stint on the show, prompting one of the male actors to joke, "Damn, why are you on black people time?"
We're told that sent Nia into a rage ... chewing the guy out. The actor told her it was just a joke but she continued berating him ... and that's when Taraji fired back -- "What are you, on your period? Is it that time, girlfriend?"
Things got super heated ... and it set the tone for a relationship that was barely civil. Taraji has always been super protective of the cast and crew and everyone was in her corner.