mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-06 00:10:19 +02:00
- rm the OP_IMUL to SHL optimization from tcgx86.a_op_const_reg and tcgx86.a_op_const_ref, because it's already done in optimize_op_const, which is called in the beginning of both methods.
git-svn-id: trunk@26491 -
This commit is contained in:
parent
9535837039
commit
820b667e1b
@ -1697,13 +1697,6 @@ unit cgx86;
|
||||
end;
|
||||
OP_MUL,OP_IMUL:
|
||||
begin
|
||||
if not(cs_check_overflow in current_settings.localswitches) and
|
||||
ispowerof2(int64(a),power) then
|
||||
begin
|
||||
list.concat(taicpu.op_const_reg(A_SHL,TCgSize2OpSize[size],power,reg));
|
||||
exit;
|
||||
end;
|
||||
|
||||
if op = OP_IMUL then
|
||||
list.concat(taicpu.op_const_reg(A_IMUL,TCgSize2OpSize[size],a,reg))
|
||||
else
|
||||
@ -1832,13 +1825,6 @@ unit cgx86;
|
||||
End;
|
||||
OP_MUL,OP_IMUL:
|
||||
begin
|
||||
if not(cs_check_overflow in current_settings.localswitches) and
|
||||
ispowerof2(int64(a),power) then
|
||||
begin
|
||||
list.concat(taicpu.op_const_ref(A_SHL,TCgSize2OpSize[size],
|
||||
power,tmpref));
|
||||
exit;
|
||||
end;
|
||||
{ can't multiply a memory location directly with a constant }
|
||||
if op = OP_IMUL then
|
||||
inherited a_op_const_ref(list,op,size,a,tmpref)
|
||||
|
Loading…
Reference in New Issue
Block a user