There could be many reasons for the plant's decline. But Rosemary is quite sensitive to correct watering. Too much or too little followed by too much can cause the roots to rot. This kind of top growth die-back can be a symptom of trouble at the roots. Growing in mulch alone, which would be largely inert of nutrients, one presumes you have been providing regular fertilizer. Such a decline could also be caused by a nutrient or soil pH problem.