The chainlines above describe the selected cranks. They are not a universal rule for every frame or every member of either product family.
02
Start with what you already own.
Your frame
Keep its model and year at the center of the decision. A conventional hanger-mounted recipe does not establish Full Mount compatibility. For Transmission, verify the UDH interface and exact frame; then confirm ring and crank clearance.
Changing from the selected XT cassette to either GX cassette changes the required freehub from MICRO SPLINE to XD. Ask the hub maker whether the exact hub can be converted, and which body, end cap and small parts are required. A whole new wheel is not automatically necessary.
Treat these as a documented combination. Both GX examples fit XD, but that shared interface does not make their cassettes interchangeable in the rear drivetrain. Keep the selected chain and matching connector with its recipe.
Record spindle, shell, chainline and ring mount before deciding. The selected XT crank uses a different spindle interface from DUB. A Hope crank offers another documented route, with its own bottom bracket and ring.
A drivetrain change does not by itself select a new brake. Check handlebar space, shifter clamp and any integrated mounting adapter against the actual brake lever. Do not assume an integrated Shimano or SRAM mount fits another lever.
These examples use a 32T ring to keep the comparison consistent. Choose ring size for your riding and permitted frame clearance, then repeat chain-length and setup checks. Arm length is a separate rider-fit choice.
Bring your shop the frame model/year and a list or clear photos of the current rear hub, freehub, crank, bottom bracket, brake lever and shifter mounts. Mark each item as keep, replace or needs verification.
Have the shop confirm the exact variants, fittings and setup before ordering. A matching interface is useful evidence; it does not establish every clearance or approve the assembled bike.