Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

quaddouble wrapper sets fpu precision to 53 bits for entire sage session #468

Closed
sagetrac-bober mannequin opened this issue Aug 20, 2007 · 3 comments
Closed

quaddouble wrapper sets fpu precision to 53 bits for entire sage session #468

sagetrac-bober mannequin opened this issue Aug 20, 2007 · 3 comments

Comments

@sagetrac-bober
Copy link
Mannequin

sagetrac-bober mannequin commented Aug 20, 2007

sage/rings/real_rqdf.pyx contains the following code:

cdef class RealQuadDoubleField_class(Field):
    """
    Real Quad Double Field
    """

    def __init__(self):
        fpu_fix_start(self.cwf)        

    def __dealloc__(self):
        fpu_fix_end(self.cwf)

On systems where fpu_fix_start() does something, it sets the fpu precision to 53 bits. A poor side effect of this is that the type long double ought to have 64 bits of precision on some systems, but it doesn't when it is used in code run from SAGE.

The short term fix will be to rewrite the wrapper to have an fpu_fix_start() and fpu_fix_end() call before and after every arithmetic operation on a RealQuadDouble element, and nowhere else, to make sure that the quaddouble wrapper doesn't ever unexpected change the fpu precision.

It would also be nice to have a doctest that can check the fpu precision, so it can be checked that nothing ever changes it unexpectedly.

Component: basic arithmetic

Keywords: quaddouble, fpu, ReadQuadDouble

Issue created by migration from https://trac.sagemath.org/ticket/468

@sagetrac-bober sagetrac-bober mannequin self-assigned this Aug 20, 2007
@sagetrac-bober
Copy link
Mannequin Author

sagetrac-bober mannequin commented Aug 23, 2007

Attachment: 5834.patch.gz

This patch should fix this issue.

@sagetrac-bober
Copy link
Mannequin Author

sagetrac-bober mannequin commented Aug 23, 2007

x86 specific fpu stuff -- see ticket discussion (this should NOT be included in sage)

@sagetrac-bober
Copy link
Mannequin Author

sagetrac-bober mannequin commented Aug 23, 2007

comment:1

Attachment: 5835-fpu-status.patch.gz

The attachment 5835-fpu-status.patch provides a module for checking/setting the fpu precision on an x86 processor, which can be useful for debugging problems like this one. Some example usage of this patch:

sage: import sage.misc.fpu as fpu
sage: fpu.get_precision()
'extended'
sage: fpu.set_double_precision()
sage: fpu.get_precision()
'double'
sage: fpu.set_single_precision()
sage: fpu.get_precision()
'single'
sage: fpu.set_extended_precision()
sage: fpu.get_precision()
'extended'

This patch should NOT be included in sage currently, as it relies on an x86 processor to function, and also just isn't written very nicely in general.

@sagetrac-bober sagetrac-bober mannequin added this to the sage-2.9 milestone Aug 29, 2007
@mwhansen mwhansen modified the milestones: sage-2.9, sage-2.8.7 Oct 12, 2007
vbraun pushed a commit that referenced this issue Mar 26, 2023
    
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-
action) from 2 to 3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/codecov/codecov-
action/releases">codecov/codecov-action's releases</a>.</em></p>
<blockquote>
<h2>v3.0.0</h2>
<h3>Breaking Changes</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/689">#689</a> Bump to node16 and small fixes</li>
</ul>
<h3>Features</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/688">#688</a> Incorporate <code>gcov</code> arguments for
the Codecov uploader</li>
</ul>
<h3>Dependencies</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/548">#548</a> build(deps-dev): bump jest-junit from 12.2.0
to 13.0.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/603">#603</a> [Snyk] Upgrade <code>@​actions/core</code>
from 1.5.0 to 1.6.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/628">#628</a> build(deps): bump node-fetch from 2.6.1 to
3.1.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/634">#634</a> build(deps): bump node-fetch from 3.1.1 to
3.2.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/636">#636</a> build(deps): bump openpgp from 5.0.1 to
5.1.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/652">#652</a> build(deps-dev): bump
<code>@​vercel/ncc</code> from 0.30.0 to 0.33.3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/653">#653</a> build(deps-dev): bump
<code>@​types/node</code> from 16.11.21 to 17.0.18</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/659">#659</a> build(deps-dev): bump
<code>@​types/jest</code> from 27.4.0 to 27.4.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/667">#667</a> build(deps): bump actions/checkout from 2 to
3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/673">#673</a> build(deps): bump node-fetch from 3.2.0 to
3.2.3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/683">#683</a> build(deps): bump minimist from 1.2.5 to
1.2.6</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/685">#685</a> build(deps): bump
<code>@​actions/github</code> from 5.0.0 to 5.0.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/681">#681</a> build(deps-dev): bump
<code>@​types/node</code> from 17.0.18 to 17.0.23</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/682">#682</a> build(deps-dev): bump typescript from 4.5.5
to 4.6.3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/676">#676</a> build(deps): bump
<code>@​actions/exec</code> from 1.1.0 to 1.1.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/675">#675</a> build(deps): bump openpgp from 5.1.0 to
5.2.1</li>
</ul>
<h2>v2.1.0</h2>
<h2>2.1.0</h2>
<h3>Features</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/515">#515</a> Allow specifying version of Codecov
uploader</li>
</ul>
<h3>Dependencies</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/499">#499</a> build(deps-dev): bump
<code>@​vercel/ncc</code> from 0.29.0 to 0.30.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/508">#508</a> build(deps): bump openpgp from 5.0.0-5 to
5.0.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/514">#514</a> build(deps-dev): bump
<code>@​types/node</code> from 16.6.0 to 16.9.0</li>
</ul>
<h2>v2.0.3</h2>
<h2>2.0.3</h2>
<h3>Fixes</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/464">#464</a> Fix wrong link in the readme</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/485">#485</a> fix: Add override OS and linux default to
platform</li>
</ul>
<h3>Dependencies</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/447">#447</a> build(deps): bump openpgp from 5.0.0-4 to
5.0.0-5</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/458">#458</a> build(deps-dev): bump eslint from 7.31.0 to
7.32.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/465">#465</a> build(deps-dev): bump <code>@​typescript-
eslint/eslint-plugin</code> from 4.28.4 to 4.29.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/466">#466</a> build(deps-dev): bump <code>@​typescript-
eslint/parser</code> from 4.28.4 to 4.29.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/468">#468</a> build(deps-dev): bump
<code>@​types/jest</code> from 26.0.24 to 27.0.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/470">#470</a> build(deps-dev): bump
<code>@​types/node</code> from 16.4.0 to 16.6.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/472">#472</a> build(deps): bump path-parse from 1.0.6 to
1.0.7</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/473">#473</a> build(deps-dev): bump
<code>@​types/jest</code> from 27.0.0 to 27.0.1</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/codecov/codecov-
action/blob/main/CHANGELOG.md">codecov/codecov-action's
changelog</a>.</em></p>
<blockquote>
<h2>3.1.1</h2>
<h3>Fixes</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/661">#661</a> Update deprecation warning</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/593">#593</a> Create codeql-analysis.yml</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/712">#712</a> README: fix typo</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/725">#725</a> fix: Remove a blank row</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/726">#726</a> Update README.md with correct badge
version</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/633">#633</a> Create scorecards-analysis.yml</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/747">#747</a> fix: add more verbosity to validation</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/750">#750</a> Regenerate scorecards-analysis.yml</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/774">#774</a> Switch to v3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/783">#783</a> Fix network entry in table</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/791">#791</a> Trim arguments after splitting them</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/769">#769</a> Plumb failCi into verification
function.</li>
</ul>
<h3>Dependencies</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/713">#713</a> build(deps-dev): bump typescript from 4.6.3
to 4.6.4</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/714">#714</a> build(deps): bump node-fetch from 3.2.3 to
3.2.4</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/724">#724</a> build(deps): bump github/codeql-action from
1 to 2</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/717">#717</a> build(deps-dev): bump
<code>@​types/jest</code> from 27.4.1 to 27.5.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/729">#729</a> build(deps-dev): bump
<code>@​types/node</code> from 17.0.25 to 17.0.33</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/734">#734</a> build(deps-dev): downgrade
<code>@​types/node</code> to 16.11.35</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/723">#723</a> build(deps): bump actions/checkout from 2 to
3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/733">#733</a> build(deps): bump
<code>@​actions/github</code> from 5.0.1 to 5.0.3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/732">#732</a> build(deps): bump
<code>@​actions/core</code> from 1.6.0 to 1.8.2</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/737">#737</a> build(deps-dev): bump
<code>@​types/node</code> from 16.11.35 to 16.11.36</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/749">#749</a> build(deps): bump ossf/scorecard-action from
1.0.1 to 1.1.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/755">#755</a> build(deps-dev): bump typescript from 4.6.4
to 4.7.3</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/759">#759</a> build(deps-dev): bump
<code>@​types/node</code> from 16.11.36 to 16.11.39</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/762">#762</a> build(deps-dev): bump
<code>@​types/node</code> from 16.11.39 to 16.11.40</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/746">#746</a> build(deps-dev): bump
<code>@​vercel/ncc</code> from 0.33.4 to 0.34.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/757">#757</a> build(deps): bump ossf/scorecard-action from
1.1.0 to 1.1.1</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/760">#760</a> build(deps): bump openpgp from 5.2.1 to
5.3.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/748">#748</a> build(deps): bump actions/upload-artifact
from 2.3.1 to 3.1.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/766">#766</a> build(deps-dev): bump typescript from 4.7.3
to 4.7.4</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/799">#799</a> build(deps): bump openpgp from 5.3.0 to
5.4.0</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/798">#798</a> build(deps): bump
<code>@​actions/core</code> from 1.8.2 to 1.9.1</li>
</ul>
<h2>3.1.0</h2>
<h3>Features</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/699">#699</a> Incorporate <code>xcode</code> arguments for
the Codecov uploader</li>
</ul>
<h3>Dependencies</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/694">#694</a> build(deps-dev): bump
<code>@​vercel/ncc</code> from 0.33.3 to 0.33.4</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/696">#696</a> build(deps-dev): bump
<code>@​types/node</code> from 17.0.23 to 17.0.25</li>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/698">#698</a> build(deps-dev): bump jest-junit from 13.0.0
to 13.2.0</li>
</ul>
<h2>3.0.0</h2>
<h3>Breaking Changes</h3>
<ul>
<li><a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/689">#689</a> Bump to node16 and small fixes</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="codecov/codecov-action@d9f34f8cd5
cb3b3eb79b3e4b5dae3a16df499a70"><code>d9f34f8</code></a> release: update
changelog and version to 3.1.1 (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/828">#828</a>)</li>
<li><a href="codecov/codecov-action@0e9e7b4e8a
4cbde89b1d36ffe91a812536089d02"><code>0e9e7b4</code></a> Plumb failCi
into verification function. (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/769">#769</a>)</li>
<li><a href="codecov/codecov-action@7f20bd4c41
51750a1d013be0901b7e35a46c2aad"><code>7f20bd4</code></a> build(deps):
bump <code>@​actions/core</code> from 1.8.2 to 1.9.1 (<a
href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/798">#798</a>)</li>
<li><a href="codecov/codecov-action@13bc2536ab
285b021e72dfb3cd53e56f5c1f4e26"><code>13bc253</code></a> build(deps):
bump openpgp from 5.3.0 to 5.4.0 (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/799">#799</a>)</li>
<li><a href="codecov/codecov-action@5c0da1b28f
1c589bf17db0088d610ae638f4ccb7"><code>5c0da1b</code></a> Trim arguments
after splitting them (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/791">#791</a>)</li>
<li><a href="codecov/codecov-action@68d5f6d0be
32fb7f92b47e97218cf01690e6e3b5"><code>68d5f6d</code></a> Fix
<code>network</code> entry in table (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/783">#783</a>)</li>
<li><a href="codecov/codecov-action@2a829b95de
aeea2d11d127cc0358005714ff35ea"><code>2a829b9</code></a> Switch to v3
(<a href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/774">#774</a>)</li>
<li><a href="codecov/codecov-action@8e09eaf1b4
7fbb5da0e32a27bf08cd11929a1b4a"><code>8e09eaf</code></a> build(deps-
dev): bump typescript from 4.7.3 to 4.7.4 (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/766">#766</a>)</li>
<li><a href="codecov/codecov-action@39e222921f
d6f8ff1aae5c56948ff1599a2b57d1"><code>39e2229</code></a> build(deps):
bump actions/upload-artifact from 2.3.1 to 3.1.0 (<a
href="https://github-redirect.dependabot.com/codecov/codecov-
action/issues/748">#748</a>)</li>
<li><a href="codecov/codecov-action@b2b7703473
2e1f073c09521d4f31f4db18b099e2"><code>b2b7703</code></a> build(deps):
bump openpgp from 5.2.1 to 5.3.0 (<a href="https://github-
redirect.dependabot.com/codecov/codecov-
action/issues/760">#760</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/codecov/codecov-action/compare/v2...v3">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility score](https://dependabot-
badges.githubapp.com/badges/compatibility_score?dependency-
name=codecov/codecov-action&package-manager=github_actions&previous-
version=2&new-version=3)](https://docs.github.com/en/github/managing-
security-vulnerabilities/about-dependabot-security-updates#about-
compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>
    
URL: #35183
Reported by: dependabot[bot]
Reviewer(s): Tobias Diez
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants