The Senate on Thursday completed a five-year, half-trillion-dollar farm bill that cuts farm subsidies and land conservation spending by about $2 billion a year but largely protects sugar growers and some 46 million food stamp beneficiaries. The 64-35 vote for passage defied political odds. Many inside and outside of Congress had predicted that legislation so expensive and so complicated would have little chance of advancing in an election year.