Handle long long in pc_equ/pc_neq optimizations.

This commit is contained in:
Stephen Heumann 2021-02-13 17:03:49 -06:00
parent 32ae4c2e17
commit 75234dbf83
1 changed files with 14 additions and 0 deletions

14
DAG.pas
View File

@ -1404,6 +1404,13 @@ case op^.opcode of {check for optimizations of this node}
op^.left := nil;
op^.right := nil;
end;
cgQuad,cgUQuad: begin
op^.opcode := pc_ldc;
op^.q := ord((op^.left^.qval.lo = op^.right^.qval.lo) and
(op^.left^.qval.hi = op^.right^.qval.hi));
op^.left := nil;
op^.right := nil;
end;
cgReal,cgDouble,cgComp,cgExtended: begin
op^.opcode := pc_ldc;
op^.q := ord(op^.left^.rval = op^.right^.rval);
@ -1845,6 +1852,13 @@ case op^.opcode of {check for optimizations of this node}
op^.left := nil;
op^.right := nil;
end;
cgQuad,cgUQuad: begin
op^.opcode := pc_ldc;
op^.q := ord((op^.left^.qval.lo <> op^.right^.qval.lo) or
(op^.left^.qval.hi <> op^.right^.qval.hi));
op^.left := nil;
op^.right := nil;
end;
cgReal,cgDouble,cgComp,cgExtended: begin
op^.opcode := pc_ldc;
op^.q := ord(op^.left^.rval <> op^.right^.rval);