Test suite results for test file tbs/tb0168.pp

Test run data :

Free Pascal Compiler Test Suite Results

View Test suite results

Please specify search criteria:
File:
Operating system:
Processor:
Version
Date
Submitter
Machine
Comment
Limit
Cond
Category
Only failed tests
Hide skipped tests
List all tests

Test file "tbs/tb0168.pp" information:

t_id 405
t_cpu i386
t_adddate 2003/10/03
t_result 0
t_knownrunerror 0
t_opts -Ratt

Detailed test run results:

Record count: 50

Total = 50

OK=3 Percentage= 6.00

Skipped=47 Percentage= 94.00

Result type Cat. Count Percentage First date Last Date
Successfully run 3 6.0 2024/05/21 10:00:00 72 2024/05/21 11:28:00 79
i386 3 100.0 2024/05/21 10:00:00 72 2024/05/21 11:28:00 79
go32v2 3 100.0 2024/05/21 10:00:00 72 2024/05/21 11:28:00 79
3.3.1 3 100.0 2024/05/21 10:00:00 72 2024/05/21 11:28:00 79
Skipping test because for other cpu 47 94.0 2024/05/21 09:12:00 85 2024/05/21 19:46:00 68
powerpc 11 23.4 2024/05/21 18:58:00 44 2024/05/21 19:46:00 68
x86_64 1 2.1 2024/05/21 09:12:00 85 2024/05/21 09:12:00 85
powerpc64 14 29.8 2024/05/21 17:32:00 71 2024/05/21 18:38:00 103
aarch64 21 44.7 2024/05/21 09:57:00 38 2024/05/21 17:55:00 56
linux 35 74.5 2024/05/21 09:12:00 85 2024/05/21 19:46:00 68
darwin 12 25.5 2024/05/21 16:23:00 32 2024/05/21 17:55:00 56
3.3.1 1 2.1 2024/05/21 09:12:00 85 2024/05/21 09:12:00 85
3.2.3 46 97.9 2024/05/21 09:57:00 38 2024/05/21 19:46:00 68

Source:

{ %CPU=i386 }
{ %OPT= -Ratt }

{ Old file: tbs0201.pp }
{ problem with record var-parameters and assembler      OK 0.99.11 (PFV) }

program bug0201;

type rec = record
         a : DWord;
         b : Word;
     end;

{ this is really for tests but
  this should be coded with const r1 and r2 !! }

function x(r1 : rec; r2 : rec; var r3 : rec) : integer; assembler;
asm
   movl r3, %edi
   movl r1, %ebx
   movl r2, %ecx
   movl rec.a(%ebx), %eax
   addl rec.a(%ecx), %eax
   movl %eax, rec.a(%edi)

   movw rec.b(%ebx), %ax
   addw rec.b(%ecx), %ax
   movw %ax, rec.b(%edi)
   movw $1,%ax
end;

var r1, r2, r3 : rec;

begin
     r1.a := 100; r1.b := 200;
     r2.a := 300; r2.b := 400;
     x(r1, r2, r3);
     Writeln(r3.a, ' ', r3.b);
     if (r3.a<>400) or (r3.b<>600) then
       begin
          Writeln('Error in assembler code');
          Halt(1);
       end;
end.

Link to SVN view of tbs/tb0168.pp source.