I assume you mean maximum degree of accuracy for polynomials, that is, you require that the formula is exact for polynomial functions of degree up to $d$, and you look for the maximum possible $d$. This is the most usual requirement, although not necessarily the best one (see for instance^{1} http://eprints.maths.ox.ac.uk/1116/1/NA-06-07.pdf).

The maximum $d$ achievable clearly depends on the number of terms $n$ in the formula $\sum_{i=1}^n w_if(x_i)$ that you are allowing for. So you are comparing apples and oranges in your examples: Simpson has a higher order than the Trapezoidal Rule, but this is compensated by the fact that it requires more function evaluations; it is just a trade-off in many cases. Note, also, that the orders that you are stating for these two rules are for quadrature without a weight function, while you have $w(x)=(1-x)^{1/2}(1+x)^{-1/2}$ added as a weight function. This changes the problem, because now "exact for polynomials" means a different thing.

It is a classical theorem, often taught in advanced numerical analysis courses, that Gaussian quadrature (for a specific weight function) has the highest possible order of accuracy among all those with a given number of terms --- see e.g. Stoer, Bulirsch, *Introduction to numerical analysis* Sec. 3.6.

Your weight function is a special case of the Gauss-Jacobi weight $w(x)=(1-x)^\alpha(1+x)^\beta$, so you should look for formulas giving weights and nodes for Gauss-Jacobi quadrature.

^{1}Wayback Machine link, the article is: *Trefethen, Lloyd N.*, **Is Gauss quadrature better than Clenshaw-Curtis?**, SIAM Rev. 50, No. 1, 67-87 (2008). ZBL1141.65018, MR2403058.