Compare commits
2 Commits
83537fd3c7
...
77e0b8fc59
Author | SHA1 | Date |
---|---|---|
Stephen Heumann | 77e0b8fc59 | |
Stephen Heumann | 50636bd28b |
|
@ -3453,11 +3453,17 @@ var
|
|||
while tp <> nil do begin
|
||||
if tp^.middle <> nil then begin
|
||||
GenerateCode(tp^.middle);
|
||||
if expressionType^.kind in [structType,unionType] then begin
|
||||
if expressionType^.size & $FFFF8000 <> 0 then
|
||||
Error(61);
|
||||
Gen1t(pc_ldc, long(expressionType^.size).lsw, cgWord);
|
||||
Gen0(pc_psh);
|
||||
if expressionType^.kind in [structType,unionType,definedType]
|
||||
then begin
|
||||
tType := expressionType;
|
||||
while tType^.kind = definedType do
|
||||
tType := tType^.dType;
|
||||
if tType^.kind in [structType,unionType] then begin
|
||||
if tType^.size & $FFFF8000 <> 0 then
|
||||
Error(61);
|
||||
Gen1t(pc_ldc, long(tType^.size).lsw, cgWord);
|
||||
Gen0(pc_psh);
|
||||
end; {if}
|
||||
end; {if}
|
||||
if fmt <> fmt_none then begin
|
||||
new(tfp);
|
||||
|
|
1
Gen.pas
1
Gen.pas
|
@ -321,6 +321,7 @@ case op^.opcode of
|
|||
loc := LabelToDisp(op^.left^.r) + op^.left^.q;
|
||||
if (op^.left^.opcode <> pc_lod) or (loc > 255) then
|
||||
Error(cge1);
|
||||
offset := offset + op^.q;
|
||||
if offset = 0 then
|
||||
GenNative(mop, direct, loc, nil, 0)
|
||||
else begin
|
||||
|
|
4
cc.notes
4
cc.notes
|
@ -1620,6 +1620,10 @@ If you use #pragma debug 0x0010 to enable stack check debug code, the compiler w
|
|||
|
||||
15. Native code peephole optimization might produce invalid code in some obscure circumstances where one element of a global or static array was decremented and then another element of the same array was accessed immediately thereafter.
|
||||
|
||||
16. When an expression of const- or volatile-qualified struct or union type was passed as a function parameter, incorrect code would be generated. This could lead to incorrect program behavior or crashes.
|
||||
|
||||
17. Incorrect code could sometimes be generated if a long long or unsigned long long value was a non-initial member of a structure, and it was accessed through a pointer to the structure and used as an operand of certain arithmetic, bitwise, or comparison operators.
|
||||
|
||||
-- Bugs from C 2.1.1 B3 that have been fixed in C 2.2.0 ---------------------
|
||||
|
||||
1. There were various bugs that could cause incorrect code to be generated in certain cases. Some of these were specific to certain optimization passes, alone or in combination.
|
||||
|
|
Loading…
Reference in New Issue