This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| en:multiasm:papc:chapter_6_10 [2025/10/31 18:27] – [FPU control instructions] ktokarz | en:multiasm:papc:chapter_6_10 [2026/02/18 11:29] (current) – [Basic arithmetic instructions] ktokarz | ||
|---|---|---|---|
| Line 109: | Line 109: | ||
| | **fdivp** | ST(1) / ST(0) | ST(1) | yes | | | **fdivp** | ST(1) / ST(0) | ST(1) | yes | | ||
| </ | </ | ||
| - | The addition and multiplication operations are commutative, | + | The addition and multiplication operations are commutative, |
| <table frevarithmetic> | <table frevarithmetic> | ||
| Line 168: | Line 168: | ||
| <table ftrans> | <table ftrans> | ||
| < | < | ||
| - | ^ Mnemonic | + | ^ Mnemonic |
| | **f2xm1** | | **f2xm1** | ||
| | **fyl2x** | | **fyl2x** | ||
| Line 176: | Line 176: | ||
| ===== FPU control instructions ===== | ===== FPU control instructions ===== | ||
| The FPU control instructions help the programmer to save and restore the contents of chosen registers if there is a need to use them in an interrupt handler or inside a function. It is also possible to initialise the state of the FPU unit or clear errors. | The FPU control instructions help the programmer to save and restore the contents of chosen registers if there is a need to use them in an interrupt handler or inside a function. It is also possible to initialise the state of the FPU unit or clear errors. | ||
| - | The **fincstp*** increments and **fdecstp** decrements the FPU register stack pointer. | + | The **fincstp** increments and **fdecstp** decrements the FPU register stack pointer. |
| The following set of instructions can perform error checking while execution (instructions without " | The following set of instructions can perform error checking while execution (instructions without " | ||
| The **finit** and **fninit** initialise the FPU (after checking error conditions or without checking error conditions). | The **finit** and **fninit** initialise the FPU (after checking error conditions or without checking error conditions). | ||