mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 11:09:42 +02:00
* optimization in the 8087/80287 version of fpc_arctan_real(): when calculating
arctan([-]1/d), use fxch to swap the two arguments, instead of using fdivr, since fpatan can do the division for free git-svn-id: trunk@26227 -
This commit is contained in:
parent
a7b4953795
commit
c88be4550d
@ -132,7 +132,7 @@
|
||||
|
||||
@@greater_than_one:
|
||||
{ d > 1 }
|
||||
fdivr st(1), st // 1 1/d
|
||||
fxch st(1) // d 1
|
||||
fpatan // arctan(1/d)
|
||||
fld tbyte [Extended_PIO2] // pi/2 arctan(1/d)
|
||||
fsubrp st(1), st // pi/2-arctan(1/d)
|
||||
@ -171,7 +171,7 @@
|
||||
|
||||
@@less_than_minus_one:
|
||||
{ d < -1; -d > 1 }
|
||||
fdivr st(1), st // 1 -1/d
|
||||
fxch st(1) // -d 1
|
||||
fpatan // arctan(-1/d)
|
||||
fld tbyte [Extended_PIO2] // pi/2 arctan(-1/d)
|
||||
fsubp st(1), st // arctan(-1/d)-pi/2
|
||||
|
Loading…
Reference in New Issue
Block a user