1
                                                                     Exhibit 5.1
                                                                     -----------





                                              December 30, 1994


IMRS Inc.
777 Long Ridge Road
Stamford, CT  06902

       RE: Registration Statement on Form S-8 Relating to the Pillar
           Corporation 1988 Stock Option Plan and the Pillar Corporation
           1992 Long-Term Equity Incentive Plan (collectively referred to
           herein as the "Plans")
           --------------------------------------------------------------

Dear Sir or Madam:

        Reference is made to the above-captioned Registration Statement on Form
S-8 (the "Registration Statement") to be filed on behalf of IMRS Inc., a
Delaware corporation ("IMRS"), with the Securities and Exchange Commission
under the Securities Act of 1933, as amended, relating to an aggregate of
70,258 shares of Common Stock, $.01 par value, (the "Shares") of IMRS issuable
pursuant to the Plans of Pillar Corporation, a California corporation
("Pillar") and a wholly-owned subsidiary of IMRS by virtue of a merger
transaction completed in November 1994.

        We have examined, are familiar with, and have relied as to factual
matters solely upon, copies of the Plans, the Amended and Restated Articles of
Organization, By-Laws, minute books and stock records of Pillar, the Amended
and Restated Articles of Organization, Amended and Restated By-Laws, minute
books and stock records of IMRS, and originals of such other documents,
certificates and proceedings as we have deemed necessary for the purpose of
rendering this opinion.

        Based on the foregoing, we are of the opinion that the Shares have been
duly authorized and, when issued and paid for in accordance with the terms of
the related Plan, will be validly issued, fully paid and nonassessable.

        We hereby consent to the filing of this opinion as Exhibit 5.1 to the
Registration Statement.

                                                Very truly yours,


                                                /S/ TESTA, HURWITZ & THIBEAULT
                                                ------------------------------


                                                TESTA, HURWITZ & THIBEAULT