if its just light speckles in the mucus then dont worry, your just coughing too hard and rupturing a capillary (tiny blood vessels) in the lungs, wind pip or throat...

if there is alot of blood (enough to fill a tea spoon) then go to your doctors