Let $X,Y \geq 1$. I am interested in the number of solutions of the following diophantine equations: $$S_1\colon \, \, x_1y_1^3 = x_2 y_2^3 $$ Let $N_1(X,Y) $ denote the number of solutions to $S_1$ with $1\leq x_i \leq X$ and $1\leq y_i \leq Y$. There are the obvious solutions $x_1=x_2$ and $y_1=y_2$ which contribute $XY$. The true order of magnitude should be $XY \log(XY)^A$ with some small power of log. I would like to get $A$ as small as possible.
Also consider the equation $S_2$ given by $$ x_1(y_1^3 - y_2^3) = x_2 (z_1^3 -z_2^3)$$ with $1\leq x_i\leq X$ and $1\leq y_i,z_i \leq Y$ with $y_1\neq y_2$ and $z_1\neq z_2$. Let $N_2(X,Y)$ denote the corresponding number of solutions. I expect something like $N_2(X,Y) \ll XY^2\log(XY)^B$, with $B$ again hopefully small.
Is there some clever way to get the exponent of the logarithm small?