We address the problem of time optimal software pipelining of loops with control flows, one of the most difficult open problems
in the area of parallelizing compilers.We present a necessary condition for loops with control flows to have equivalent time
optimal programs, generalizing the result by Schwiegelshohn et al., which has been the most significant theoretical result on the problem. As part of the formal treatment of the problem,
we propose a new formalization of software pipelining, which provides a basis of our proof as well as a new theoretical framework
for software pipelining research. Being the first generalized result on the problem, our work described in this paper forms an important first step towards time optimal software
pipelining.