We've seen it before, that Konoha plays dirty when it comes to traitors and spies. Remember Yamato disguising as Sasori?

Rin ran from the village, was meant to be collected by Mist Anbu, but the Anbu were assassinated by Konoha, and Konoha Anbu were wearing the deceased Mist anbu's masks. Just imagine this scene, she thinks she is finally safe, and happily runs towards her home villages Anbu, and one of them takes off his mask. And it is Kakashi. He walks up to her, used Raikiri or Chidori, I'm pretty sure it was still Chidori here, but anyhow, uses it, looks her in the eye, says he knows she has been spying, and tells her he loves her. Then he kills her. This is why he is crying as he does it.

--Enter Obito--

Now I'm basing this all off of a few assumptions, and a fact, but bear with me...

Assumption #1 - Rin was fleeing Konoha with valuable information back to her home village of the mist

Assumption #2 - Rin was a sleeper spy set by the mist

Assumption #3 - Konoha knew that Mist anbu would be waiting to secure her in her flight from the village, so they sent a team of Anbu to kill the Mist Anbu ( thats why it looked like a battle was going on) who were going to collect her, and then put the mist masks on, and waited for her.

The Anbu in this scene (Middle to the right where they state "they still got us" or something along those lines) are ones which were not killed when Konoha assassinated the team to secure her, ones in top image are the disguised Konoha Anbu

Assumption #4 - Kakashi was already in the Anbu, thats why he was there, and he wanted to end Rin's espionage face to face, because he loved her, and wanted to be the one to end it. Thats why he was crying.
Fact - Obito starts screaming his "Woooooaaaaahhhh" after smashing an Anbu mask and seeing..a Konoha Headband here. Notice how he holds the anbu's head still, and then that look of "OH SHIT" comes on his face when he recognizes the Konoha headband. Then he starts going crazyier than before.