         Edinburgh IMP77 Compiler - Version 8.4-2024.12.18

     1  %begin
 0000 C8 00 00 01                           ENTER 0000,1
     2    %comment %begin
     3    %recordformat rf ( %integer i, %real r, %integer i2)
     4    %comment   %recordformat rf ( %integer i, %real r, %integer i2)
     5  
     6    %comment 
     7    %record (rf) rec1, rec2
     8    %comment   %record (rf) rec1, rec2
     9  
    10    %record (rf) %name %array recna1(2:3)
 0004 C7 45 D4 01 00 00 00                  MOV DWORD PTR [%EBP-44],#1
 000B C7 45 D8 02 00 00 00                  MOV DWORD PTR [%EBP-40],#2
 0012 C7 45 DC 03 00 00 00                  MOV DWORD PTR [%EBP-36],#3
 0019 C7 45 E0 89 00 00 00                  MOV DWORD PTR [%EBP-32],#137
 0020 8D 45 D4                              LEA %EAX,[%EBP-44]
 0023 50                                    PUSH %EAX
 0024 E8 0A 00                              CALL '_IMPADEF' (EXTERN 10)
 0027 83 C4 04                              ADD %ESP,#4
 002A 8D 4D D4                              LEA %ECX,[%EBP-44]
 002D 89 E3                                 MOV %EBX,%ESP
 002F 29 D3                                 SUB %EBX,%EDX
 0031 89 5D CC                              MOV [%EBP-52],%EBX
 0034 89 4D D0                              MOV [%EBP-48],%ECX
 0037 01 C3                                 ADD %EBX,%EAX
 0039 89 DC                                 MOV %ESP,%EBX
    11    %comment   %record (rf) %name %array recna1(2:3)
    12  
    13    %record (rf) %name %array %name recnan1
    14    %comment   %record (rf) %name %array %name recnan1
    15  
    16    %comment 
    17  
    18    ! SETUP
    19    
    20    rec1 = rec2
 003B 8D 7D F0                              LEA %EDI,[%EBP-16]
 003E B9 0C 00 00 00                        MOV %ECX,#12
 0043 8D 75 E4                              LEA %ESI,[%EBP-28]
 0046 F3 A4                                 REP MOVSB
    21    %comment   rec1 = rec2
    22  
    23    recnan1 == recna1
 0048 8B 45 D0                              MOV %EAX,[%EBP-48]
 004B 89 45 C8                              MOV [%EBP-56],%EAX
 004E 8B 45 CC                              MOV %EAX,[%EBP-52]
 0051 89 45 C4                              MOV [%EBP-60],%EAX
    24    %comment   recnan1 == recna1
    25  
    26    ! TEST
    27    
    28    recnan1(2) == rec1
 0054 6A 02                                 PUSH #2
 0056 FF 75 C8                              PUSH DWORD PTR [%EBP-56]
 0059 E8 09 00                              CALL '_IMPAREF' (EXTERN 9)
 005C 83 C4 08                              ADD %ESP,#8
 005F 89 C6                                 MOV %ESI,%EAX
 0061 03 75 C4                              ADD %ESI,[%EBP-60]
 0064 8D 45 F0                              LEA %EAX,[%EBP-16]
 0067 89 06                                 MOV [%ESI],%EAX
    29    %comment   recnan1(2) == rec1   ... the (2) is missing
    30  
    31    rec2 = recnan1(2)
 0069 6A 02                                 PUSH #2
 006B FF 75 C8                              PUSH DWORD PTR [%EBP-56]
 006E E8 09 00                              CALL '_IMPAREF' (EXTERN 9)
 0071 83 C4 08                              ADD %ESP,#8
 0074 89 C7                                 MOV %EDI,%EAX
 0076 03 7D C4                              ADD %EDI,[%EBP-60]
 0079 89 7D C0                              MOV [%EBP-64],%EDI
 007C 8D 7D E4                              LEA %EDI,[%EBP-28]
 007F B9 0C 00 00 00                        MOV %ECX,#12
 0084 8B 75 C0                              MOV %ESI,[%EBP-64]
 0087 8B 36                                 MOV %ESI,[%ESI]
 0089 F3 A4                                 REP MOVSB
    32    %comment   rec2 = recnan1(2)   ... the (2) is missing
    33  
    34    %comment   
    35    %comment %endofprogram
    36  %endofprogram
 008B C9                                    LEAVE
 008C C3                                    RET

    10 Statements compiled



 ELF object file generated from IMP source file: '/home/gtoal/src/compilers101/new-parser/imps/tests/test62.imp'
 +----------+---------------------+---------+---------+---------+------------+
 | Sections |       Symbols       | Code    | Data    | Diag    | Total size |
 +----------+----------+----------+---------+---------+---------+------------+
 |  (count) | Internal | External | (bytes) | (bytes) | (bytes) | (bytes)    |
 +----------+----------+----------+---------+---------+---------+------------+
 |       11 |        4 |        8 |     147 |       0 |      32 |        179 |
 +----------+----------+----------+---------+---------+---------+------------+


