Project Description

Valgrind currently lacks support for 80-bit extended precision floating point arithmetic on x86_64 (long double). The current implementation uses 64-bit arithmetic instead, which means that programs running on x86_64 with "long double" give different results when running under Valgrind and natively. People were asking for support for this since like forever, but to date nobody went on implementing it. It's a project for a year, unless somebody has time to work on it full time, but one has to start somewhere. :-)

Goal for this Hackweek

  • figure out what needs to be changed in the current implementation
  • figure out what are the possibilities of testing it
  • compile a list of instructions to be implemented
  • write a test program exercising every instruction to be implemented individually
    • must demonstrate no loss of accuracy
    • example: none/tests/amd64/sse4-64.c
  • clone valgrind repo and start commiting

The result of the hackweek should be the test case and some writeup on what else needs to happen.

Resources

  • https://bugs.kde.org/show_bug.cgi?id=197915
  • https://sourceware.org/git/?p=valgrind.git
  • https://en.wikipedia.org/wiki/X87
  • https://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-software-developer-vol-1-manual.pdf
  • https://refspecs.linuxbase.org/elf/x86_64-SysV-psABI.pdf
  • https://valgrind.org/docs/manual/manual-core.html#manual-core.limits
  • https://en.wikibooks.org/wiki/X86Assembly/FloatingPoint

Looking for hackers with the skills:

c x86_64 valgrind assembly floating-point x86

This project is part of:

Hack Week 23

Activity

  • almost 2 years ago: mbrugger liked this project.
  • almost 2 years ago: dfaggioli liked this project.
  • almost 2 years ago: mschreiner liked this project.
  • almost 2 years ago: mschreiner joined this project.
  • almost 2 years ago: wfrisch liked this project.
  • almost 2 years ago: e_bischoff liked this project.
  • almost 2 years ago: mfranc started this project.
  • almost 2 years ago: mfranc added keyword "x86" to this project.
  • almost 2 years ago: mfranc added keyword "floating-point" to this project.
  • almost 2 years ago: mfranc removed keyword floatingpointarithmetic from this project.
  • almost 2 years ago: mfranc added keyword "floatingpointarithmetic" to this project.
  • almost 2 years ago: mfranc added keyword "assembly" to this project.
  • almost 2 years ago: mfranc added keyword "valgrind" to this project.
  • almost 2 years ago: mfranc added keyword "x86_64" to this project.
  • almost 2 years ago: mfranc added keyword "c" to this project.
  • almost 2 years ago: mfranc originated this project.

  • Comments

    Be the first to comment!

    Similar Projects

    pudc - A PID 1 process that barks to the internet by mssola

    Description

    As a fun exercise in order to dig deeper into the Linux kernel, its interfaces, the RISC-V architecture, and all the dragons in between; I'm building a blog site cooked like this:

    • The backend is written in a mixture of C and RISC-V assembly.
    • The backend is actually PID1 (for real, not within a container).
    • We poll and parse incoming HTTP requests ourselves.
    • The frontend is a mere HTML page with htmx.

    The project is meant to be Linux-specific, so I'm going to use io_uring, pidfs, namespaces, and Linux-specific features in order to drive all of this.

    I'm open for suggestions and so on, but this is meant to be a solo project, as this is more of a learning exercise for me than anything else.

    Goals

    • Have a better understanding of different Linux features from user space down to the kernel internals.
    • Most importantly: have fun.

    Resources


    pudc - A PID 1 process that barks to the internet by mssola

    Description

    As a fun exercise in order to dig deeper into the Linux kernel, its interfaces, the RISC-V architecture, and all the dragons in between; I'm building a blog site cooked like this:

    • The backend is written in a mixture of C and RISC-V assembly.
    • The backend is actually PID1 (for real, not within a container).
    • We poll and parse incoming HTTP requests ourselves.
    • The frontend is a mere HTML page with htmx.

    The project is meant to be Linux-specific, so I'm going to use io_uring, pidfs, namespaces, and Linux-specific features in order to drive all of this.

    I'm open for suggestions and so on, but this is meant to be a solo project, as this is more of a learning exercise for me than anything else.

    Goals

    • Have a better understanding of different Linux features from user space down to the kernel internals.
    • Most importantly: have fun.

    Resources