Richard
Richard

Reputation: 15592

Floating-point computation without syscall?

I am reading Robert Love's book on Linux kernel (which says no FP computation inside kernel). And I am wondering how floating point computation is done in user space.

For instance, does 3.14 + 5.26 (in C) invoke any syscall to do the job?

Upvotes: 1

Views: 112

Answers (1)

Patricia Shanahan
Patricia Shanahan

Reputation: 26185

On most modern processors, simple double addition such as 3.14 + 5.26 would be done by hardware commands, just like integer addition.

Upvotes: 3

Related Questions