Coder Social home page Coder Social logo

Comments (3)

gbtucker avatar gbtucker commented on August 21, 2024 1

Hi @rajrana22,
Some of the files you listed like ec_base_aliases.c and ec_base_vxs.c would only run on a system with no arch-specific optimizations or no modern instruction sets. This is likely why your print statements are not called. Other versions do split up operations for balancing calculation and what temp can be kept in registers. For example we may opt to load sources and calculate 6 parity at a time before looping through sources for the next 6 parity calculations. Within the inner loop, loads from each source really only "slice" based on the size of vector registers. In the file gf_6vect_dot_prod_avx512.asm you can see we load 64 bytes at a time. Other slicing or blocking is really up to the user as they can send in chunks as they see benefit. The term slice is usually used in RAID or EC for how a single source is split into sources and this is done before passing to ISA-L EC functions.

from isa-l.

rajrana22 avatar rajrana22 commented on August 21, 2024

Hi @gbtucker,
Thank you for your reply! That was very helpful for me.

Unfortunately, I am not very experienced with assembly, so I was wondering if you could help answer some other questions that I have, which are particular to the erasure coding assembly files:

For reference, I am looking specifically at the gf_2vect_dot_prod_avx512.asm file.

  1. What is the control flow of func(gf_2vect_dot_prod_avx512)? What instruction does it execute after mov dest1, [dest1]? How does it get into the .next_vect loop?
  2. What exactly does the bulk of the .next_vect loop do? Specifically, I'm confused about what all of the masks and nibbles are and what they do.
  3. Upon calling the assembly file, apart from the function arguments, what values are loaded into registers? I'm a bit unsure about what values ptr, vec_i, dest2, and pos have, and specifically what they are for.
  4. Overall, I think a high-level understanding of how the assembly files work will help me out a lot, because I'm trying to make modifications to them for my purposes.

from isa-l.

gbtucker avatar gbtucker commented on August 21, 2024
  1. What is the control flow of func(gf_2vect_dot_prod_avx512)? What instruction does it execute after mov dest1, [dest1]? How does it get into the .next_vect loop?

The vpxorq xp1, xp1, xp1 instruction just zeroes out the first accumulator. After that it falls through from the outer loop to the inner loop.

  1. What exactly does the bulk of the .next_vect loop do? Specifically, I'm confused about what all of the masks and nibbles are and what they do.

The flow is simply two loops. The inner loop .next_vect goes through each coefficient and source to multiply and accumulate. The outer loop writes out the parity and resets for next inner loop.

  1. Upon calling the assembly file, apart from the function arguments, what values are loaded into registers? I'm a bit unsure about what values ptr, vec_i, dest2, and pos have, and specifically what they are for.

Only function arguments are passed to these functions. The ptr, vec_i, dest2, and pos are temporary variables to help index the proper offsets into the arrays passed to the functions.

  1. Overall, I think a high-level understanding of how the assembly files work will help me out a lot, because I'm trying to make modifications to them for my purposes.

I hope this helps.

from isa-l.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.