Hmmm...that's fun.
It is important to note that we seek the largest possible field, and not the lowest potential versus infinity which might yield a lower result.
So let's consider some obvious cases (all of which I will reduce to a dependence only on $\rho$ and $M$.).
A nearby sphere
We form the material into a sphere of volume $V=M/\rho$ and radius $R = 3/4 V^{1/3}/\pi$, place it next to $p$ and compute the field as $F_G = G M/R^2 = (3/4) G M V^{-2/3} = (3/4) G M^{1/3} \rho^{-2/3}$
A nearby plane segment
We form the material into a disk of thickness $T$ radius $R = 10 t$ (claiming that this is sufficient for a "infinite place" approximation near the center), so that $V = 100 t^3$so that $t = (V/100)^{1/3} = [M/(100 \rho)]^{1/3}$. We place the it such that $p$ borders center on one side. The surface density is $\sigma = \rho * t = 100^{-2/3} \rho^{2/3} M^{1/3}$ and the field is $F_G = 2 \pi G \sigma = 2 \pi 100^{-2/3} G M^{1/3} \rho^{-2/3}$.
Note that so far, both distributions result in a form $F_G = C \times G M^{1/3} \rho^{-2/3}$, so we need only compare the constants. Well, $2 \pi 100^{-2/3} = 2 \pi (0.046) = 0.29$, so the spherical distribution is better than the flat one.