Skip to content

Commit ebcea11

Browse files
committed
Merge pull request #1715 from pguyot/w24/remove-unnecessary-context_ensure_fpregs
Remove unnecessary context_ensure_fpregs calls These changes are made under both the "Apache 2.0" and the "GNU Lesser General Public License 2.1 or later" license terms (dual license). SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later
2 parents 7d5f78d + 94ecbec commit ebcea11

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

src/libAtomVM/opcodesswitch.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6025,7 +6025,6 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
60256025
#ifdef IMPL_EXECUTE_LOOP
60266026
TRACE("fmove/2 fp%i, %c%i\n", freg, T_DEST_REG(dreg));
60276027
// Space should be available on heap as compiler added an allocate opcode
6028-
context_ensure_fpregs(ctx);
60296028
term float_value = term_from_float(ctx->fr[freg], &ctx->heap);
60306029
WRITE_REGISTER(dreg, float_value);
60316030
#endif
@@ -6090,7 +6089,6 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
60906089
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
60916090
feclearexcept(FE_OVERFLOW);
60926091
#endif
6093-
context_ensure_fpregs(ctx);
60946092
ctx->fr[freg3] = ctx->fr[freg1] + ctx->fr[freg2];
60956093
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
60966094
if (fetestexcept(FE_OVERFLOW)) {
@@ -6137,7 +6135,6 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
61376135
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
61386136
feclearexcept(FE_OVERFLOW);
61396137
#endif
6140-
context_ensure_fpregs(ctx);
61416138
ctx->fr[freg3] = ctx->fr[freg1] - ctx->fr[freg2];
61426139
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
61436140
if (fetestexcept(FE_OVERFLOW)) {
@@ -6184,7 +6181,6 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
61846181
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
61856182
feclearexcept(FE_OVERFLOW);
61866183
#endif
6187-
context_ensure_fpregs(ctx);
61886184
ctx->fr[freg3] = ctx->fr[freg1] * ctx->fr[freg2];
61896185
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
61906186
if (fetestexcept(FE_OVERFLOW)) {
@@ -6231,7 +6227,6 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
62316227
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
62326228
feclearexcept(FE_OVERFLOW | FE_DIVBYZERO);
62336229
#endif
6234-
context_ensure_fpregs(ctx);
62356230
ctx->fr[freg3] = ctx->fr[freg1] / ctx->fr[freg2];
62366231
#ifdef HAVE_PRAGMA_STDC_FENV_ACCESS
62376232
if (fetestexcept(FE_OVERFLOW | FE_DIVBYZERO)) {

0 commit comments

Comments
 (0)