|
@@ -8611,17 +8611,10 @@ unit aoptx86;
|
|
begin
|
|
begin
|
|
{ Always accept if optimising for size }
|
|
{ Always accept if optimising for size }
|
|
Result := (cs_opt_size in current_settings.optimizerswitches) or
|
|
Result := (cs_opt_size in current_settings.optimizerswitches) or
|
|
- (
|
|
|
|
-{$ifdef x86_64}
|
|
|
|
- { XCHG takes 3 cycles on AMD Athlon64 }
|
|
|
|
- (current_settings.optimizecputype >= cpu_core_i)
|
|
|
|
-{$else x86_64}
|
|
|
|
- { From the Pentium M onwards, XCHG only has a latency of 2 rather
|
|
|
|
|
|
+ { From the Pentium M onwards, XCHG only has a latency of 2 rather
|
|
than 3, so it becomes a saving compared to three MOVs with two of
|
|
than 3, so it becomes a saving compared to three MOVs with two of
|
|
them able to execute simultaneously. [Kit] }
|
|
them able to execute simultaneously. [Kit] }
|
|
- (current_settings.optimizecputype >= cpu_PentiumM)
|
|
|
|
-{$endif x86_64}
|
|
|
|
- );
|
|
|
|
|
|
+ (CPUX86_HAS_FAST_XCHG in cpu_capabilities[current_settings.optimizecputype]);
|
|
end;
|
|
end;
|
|
|
|
|
|
var
|
|
var
|