Attacks:Vergil has 4 attacks:
Yamato Combo: He strikes twice with the katana's scabbard before drawing it in a horizontal slash.
Rapid Slash: A move where he dashes forward quickly while brandishing Yamato.
Upper Slash: He performs an upward draw, then slashes downward.
Judgement Cut: A distance slash attack marked by dark purple orbs.
All of these except for Judgement Cut can be dodged by jumping and Air Hiking; follow through with Helm Breaker after you jump to begin returning damage. After enough hits, Vergil will grunt loudly and be knocked back several paces; this means that he's regained his balance and will block if you try to continue attacking.
Strategy*** Spoiler - click to reveal ***
First playthrough
The first thing to note about Vergil is that, like Agni & Rudra, he is capable of blocking your attacks if you try striking when his guard is up. Unlike them, you cannot just jump over him and attack from his back. He leaves himself open during and for a brief period after his attacks (which mostly have a rather long recovery time).
Vergil can teleport around the battlefield; when he teleports right next to you, he'll execute either Yamato Combo or Upper Slash. If he teleports away, he's preparing to use Judgement Cut. To dodge the slash orbs, keep moving, as there is a short delay between the orb formation and the actual slash (you can run towards him so you can begin attacking when he stops). Rapid Slash is a relatively infrequent move, as he mainly reserves it for retaliating after blocking one of your attacks.
Second playthrough
Beowulf is a great weapon here; with a high damage output and the distance-closing properties of Killer Bee, it becomes easy to reach Vergil and attack even when he's using Judgement Cut. In addition, due to the angle of Killer Bee, stray slash orbs won't form on you while you're in your brief cooldown animation.
Note, however, that while it may be tempting to use Quicksilver to deal extra damage, it's only good for evading Vergil's attacks because Vergil is vulnerable for 13 hits (some attacks, like Helm Breaker, count as 2 hits), rather than a certain amount of time, and he can actually block your extra attacks while Time Lag is in effect.
If you are playing on Dante Must Die, Vergil gains the ability to use Spiral Swords (telegraphed by a purple orb surrounding him, and he says "Don't get so cocky...") These can present a problem when he teleports right next to you, so whenever you hear the teleporting sound, jumping away or using Sky Star is generally advisable. After a few moments, they rearrange themselves to either circle you horizontally (and eventually stab toward you simultaneously; avoidable by jumping), circle you diagonally from above (similar to the horizontal pattern, but they fire one at a time so you only need to keep moving instead of jumping), or point at you from around Vergil (fires individually; easy to dodge by running or side rolling, but can be a bit tricky if he's too close).
Defeating Vergil automatically ends the mission.