The House voted, 191 to 188, yesterday to repeal gasoline price controls and the allocation system which some blame for lines at the gas pumps earlier this year.

Gasoline prices have been controlled since 1973 when the price of oil was controlled and the retail price ceiling of gasoline has been tied to the price of crude oil.

Rep. John Dingell (D-Mich.), manager of the Energy Department authorization bill to which the amendment was attached, said he will try to reverse the action when the House resumes debate on the bill next week. Dingell said that if the United States suffers another oil "crisis" such as the indicated reduction by Saudi Arabia of 1 million barrels a day in oil production, the retail price of gasoline here could be pushed to $2 a gallon.

Sponsors of the amendment said there was no chance gas prices would be pushed so high. They contended it makes no sense to phase out controls on crude oil, as President Carter is doing, and leave controls on only one of its byproducts, gasoline. Prices of home heating oil and other byproducts have been decontrolled. In fact, Carter had intended to ask Congress to end gasoline controls last year but held up because of the fight over natural gas and the soaring gasoline prices last spring.

Votes during the past two days show the House is changing position on energy price controls from when it was preventing then-President Ford from lifting them on oil and then went along with President Carter's plan to continue them on natural gas. In three votes, the House now has refused to reimpose controls on crude oil and heating oil and has voted to remove controls from gasoline.

Much of the support for yesterday's amendment came from members angry at the allocation system -- authority for the president to move gasoline from one area to another to relieve shortages -- which they felt largely was to blame for last spring's gas lines. They said out-of-date statistics or other flaws caused the system ot work unfairly in many areas.

But in knocking out the allocation authority, the sponsors inadvertently also repealed authority for emergency allocation to meet agriculture and health and safety needs.

Rep. Phil Gramm (D-Tex.) offered an amendment to restore emergency allocation powers, Rep. Toby Moffett (D-Conn.) opposed it, saying that if repeal of controls and allocation authority was good for some it was good for all. The Gramm amendment won, 257 to 119.

The 56 absentees yesterday included a large number from consumer-oriented northeastern states. Now that Democratic leaders realize this is a tough issue, they can work on some possible switches and be sure all their troops are on hand before the next vote.

The only Washington area member to vote to remove gasoline price controls was Maryland Republican Marjorie S. Holt.