Its a horrible thing for a small child to die, and even more terrible to witness it. However, knowing that you were trained to help and did your best should give you some small comfort.
On my 2nd day of clinical during EMT school we had a 6 y.o. boy who fell out of a three story window onto concrete below. I was working in the Trauma room that day and the medics who brought him in worked him all the way in and then we resumed cpr in the trauma room. However, as i'm sure you know, cpr secondary to trauma really can't fix the leak so the doctor called it.
While the nurses and doctors were crying, I walked over and started prepping him for his mother who had just arrived at the hospital. We could hear her crying from the trauma room and it broke my heart to hear her. However, I kept it together and did my job. I'm blessed with the fact that my family is all medical so I was able to talk it through with my family as well as my instructors. I also knew that that young soul is in a better place.
Then, much to my delight- I helped deliver a new baby boy the next week. Life and Death.
We never really know whats coming at us- the thing is just to be prepared and do our best.
My heart goes out to you, it takes a certain kind of person to be in this field.