What ever the depth of penetration may be but the resulting EDS spectrum will only represent surface composition and for detailed and bulk specimen XRD or XRF should be used.
Dear Muhammad Kashif Samoon , you have written "What ever the depth of penetration may be but the resulting EDS spectrum will only represent surface composition". But actually EDS is not a surface technique. In many cases it's not a problem for EDS to determine a bulk composition.
Next you have written "for detailed and bulk specimen XRD or XRF should be used". But XRD in most cases is useless for composition. XRF for bulk analysis could be better than EDS, but it does not mean that EDS cannot be used. By the way there other means than XRF for bulk analysis.
And finally there was nothing about bulk analysis in the original question.