The mechanistic approach would be to simply substitute $b=y/a$ in the first equation to obtain a quadratic in $a$. But seeing the simplicity of the givens, I feel that there must be some better and elegant ways to do this.
The best way I could think of is this:
$(a-b)^2 = (a+b)^2 - 4ab \iff (a-b)^2 = x^2 - 4y \iff a-b = \pm\sqrt{x^2 - 4y}$
Solving this with $a+b=x$, we get the result.
It might be the case that there aren't many ways other than this, but that's okay. If there are, I'd be interested to read them.
Edit: Also, if we know that both $a$ and $b$ are non-negative, can we use this information for a better solution?
We would always get a quadratic.
Maybe one bit easier if we use the following observation (Viète's formulas): $$(Z-a)(Z-b)=Z^2-(a+b)Z+ab\,.$$ So, $a,b$ are just the solutions of $Z^2-xZ+y=0$.