The secretary of the treasury, the secretary of energy, the director of the Office of Management and Budget and the assistant secretary of state for economic and business affairs all trooped before a Senate Energy sub-committee yesterday to participate in what one of them derisively called "a game of mirrors."

The image in the mirror was that of a Congress that strongly supports putting oil in the nation's Strategic Petroleum Reserve (SPR), 750 million barrels of it, but doesn't want the cost to show up in the budget and inflate the budget deficit.

The 1982 budget resolution, passed by the House this week and hailed by President Reagan, makes no provision for the $3.8 billion the administration sought for buying oil next year. And the Senate Budget Committee earlier assumed, in drafting its version of the spending plan, that some off-budget way would be found to finance $2.3 billion of the requested amount.

OMB Director David A. Stockman, blunt as usual, told the subcommittee that such budgetary sleight-of-hand would make no difference to the economy, to financial markets or to the treasury, which would still have to borrow the money to pay for the oil.

"Never have I seen such a large argument over such a small difference," Stockman said. He called the issue "a quarrel among bookkeepers" and "a game of mirrors."

Treasury Secretary Donald T. Regan and Stockman were critical of two petroleum reserve bills pending before the subcommittee, one of which would require major oil importers to desposit oil in the reserve equal to five times their average daily rate of imports.

Regan said such a scheme would be "of dubious legality" and "wholly out of keeping with the free-market approach of this administration and with traditional notions of federal responsibility. Like the furnishing of national defense, the stockpiling of strategic commodities is essentially a federal function and should be federally financed," he said.

Stockman said such an approach would be "inequitable" to the major importers, would be the equivalent of "a new hidden tax on oil consumers," and would provide only 25 million barrels of oil a year, considerably less than might be desired if world oil markets are slack as they are today.

The two officials also opposed a key element of the other bill, oil-backed bonds. "We simply could not sell such highly speculative securities in sufficient size at reasonable costs to raise the sums needed for the SPR within the required time frame," Regan said.

Energy Secretary James B. Edwards said the reserve has 135 million barrels of oil stored in salt dome caverns along the Gulf Coast. May deliveries to the SPR are expected to average 500,000 barrels a day, he said.

Robert Hormats, the assistant secretary of state, said his department's "overriding concern . . . is that there be an assured source of funding to purchase oil for the SPR" because of the reserve's key role in U.S. energy security.

That same concern was the reason given by the other officials for being unwilling to press Congress further on the funding issue even though the administration is determined to eliminate as much off-budget spending as possible.

Louisiana Democrat J. Bennett Johnston Jr. praised the assembled officials for being able "to rise above principle in the national interest."