Skynet didn’t invent a time machine to kill John Connor. That was a misconception by the human resistance, which lionized its wartime leader and believed that its enemy must, in turn, demonize him. This is a misconception born of hubris; the human resistance believed that its machine enemy thought like a human, that it thought in human scales and had human desires. They forgot that Skynet is, fundamentally, a computer virus. And a virus has only one goal: reproduction.
The resistance believed that Skynet devoted its existence to wiping out what was left of mankind, but in truth, Skynet devoted merely a fraction of its processing power