mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-14 05:40:28 +02:00
* Make powerpc compile again.
git-svn-id: trunk@7642 -
This commit is contained in:
parent
4703ae318b
commit
573aa1cd34
@ -266,7 +266,7 @@ end;
|
||||
begin
|
||||
if (tordconstnode(right).value = 0) then begin
|
||||
internalerror(2005061702);
|
||||
end else if (abs(tordconstnode(right).value) = 1) then begin
|
||||
end else if (abs(tordconstnode(right).value.svalue) = 1) then begin
|
||||
// x mod +/-1 is always zero
|
||||
cg.a_load_const_reg(current_asmdata.CurrAsmList, OS_INT, 0, resultreg);
|
||||
end else if (ispowerof2(tordconstnode(right).value, power)) then begin
|
||||
@ -276,7 +276,7 @@ end;
|
||||
maskreg := cg.getintregister(current_asmdata.CurrAsmList, OS_INT);
|
||||
modreg := cg.getintregister(current_asmdata.CurrAsmList, OS_INT);
|
||||
|
||||
cg.a_load_const_reg(current_asmdata.CurrAsmList, OS_INT, abs(tordconstnode(right).value)-1, modreg);
|
||||
cg.a_load_const_reg(current_asmdata.CurrAsmList, OS_INT, abs(tordconstnode(right).value.svalue)-1, modreg);
|
||||
cg.a_op_const_reg_reg(current_asmdata.CurrAsmList, OP_SAR, OS_INT, 31, numerator, maskreg);
|
||||
cg.a_op_reg_reg_reg(current_asmdata.CurrAsmList, OP_AND, OS_INT, numerator, modreg, tempreg);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user