Instruction FYL2XP1
问题 I'm wondering why the instruction FYL2XP1 on x86-architecture computes exactly the mathematical formula y · log 2 ( x + 1). What's special with this formula? 回答1: The y operand is usually a compile time constant, for the moment forget about the x + 1 . Since log_b(x) = log_b(2) * log_2(x) the instruction allows to compute the logarithm in any base of x + 1 . Note that log_b(2) is a constant since it is seldom necessary to compute the logarithm with a degree of freedom in the base. FYL2XP1 and