Strictly speaking harmonic function is just a matter of root movements and even more essentially pre-dominant, dominant, and tonic identities. In this regard
V I - just two Roman numerals, a progression of roots - is all harmonic function cares about. Melodic matters are irrelevant. It's just a dominant to tonic progression.
However, if we are actually discussing cadences, rhythmic and melodic matters are essential. Strictly speaking a cadence should be the end of something. That may or may not be a rhythmic stop. Also, the quality of the cadence is determined my melodic factors. A cadence involving
V I is classified as authentic. Melodic factors determine the type further. Perfect authentic is when the bass moves dominant to tonic and the soprano ends on the tonic. If any of those melodic factors changes, but the chords are still
V I, it will be imperfect authentic.
Those different classes of cadence are important especially as formal structural elements in "classical" music. Imperfect cadences have a sense of not full and complete ends and might be used to set up subsequent, continuing phrases. Perfect cadences would be used for conclusive, final endings.
Ascending and descending chord movement and its effect on harmonic function
That wasn't really phrases as a question, but the answer is: ascending and descending melodic voice leading factors do not change harmonic function.
Does this have any impact on the harmonic function (not sure if this is the right term here) of the cadence?
It isn't really clear if you mean strictly "harmonic function" or something like "function of the cadence." But I don't think the answer needs to be either/or. Both things should be understood.
Melodic factors don't change harmonic function, but they change the quality and function of cadences.