mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 10:15:57 +01:00
16 lines
253 B
C
16 lines
253 B
C
/* https://cirosantilli.com/linux-kernel-module-cheat#gcc-inline-assembly */
|
|
|
|
#include <assert.h>
|
|
|
|
int main(void) {
|
|
double io = 4.0;
|
|
__asm__ (
|
|
"fsqrt"
|
|
: "+t" (io)
|
|
:
|
|
:
|
|
);
|
|
assert(io == 2.0);
|
|
return 0;
|
|
}
|