We demonstrate that a recently introduced heuristic optimization algorithm [Phys. Rev. E 83, 046709 (2011)] that combines a local search with triadic crossover genetic updates is capable of sampling nearly uniformly among ground-state configurations in spin-glass-like Hamiltonians with
p-spin interactions in
d space dimensions that have highly degenerate ground states. Using this algorithm we probe the zero-temperature ferromagnet to spin-glass transition point
qc of two example models, the disordered version of the two-dimensional three-spin Baxter-Wu model [
qc=0.1072(1)] and the three-dimensional Edwards-Anderson model [
qc=0.2253(7)], by computing the Binder ratio of the ground-state magnetization.
We employ a novel algorithm using a quasiexact embedded-cluster matching technique as minimization method within a genetic algorithm to reliably obtain numerically exact ground states of the Edwards-Anderson XY spin-glass model with bimodal coupling distribution for square lattices of up to 28 x 28 spins. Contrary to previous conjectures, the ground state of each disorder replica is nondegenerate up to a global O(2) rotation. The scaling of spin and chiral defect energies induced by applying several different sets of boundary conditions exhibits strong crossover effects. This suggests that previous calculations have yielded results far from the asymptotic regime. The novel algorithm and the aspect-ratio scaling technique consistently give theta(s)=-0.308(30) and theta(c)=-0.114(16) for the spin and chiral stiffness exponents, respectively.