rmuir commented on issue #12621:
URL: https://github.com/apache/lucene/issues/12621#issuecomment-1747002969

   the type conversions are what makes it slow. for float case it is the equiv 
of:
   ```
   float x = something;
   float y = something;
   float z = something;
   // no conversions
   float result = x + y * z;
   ```
   
   for the binary case it is the equivalent of:
   ```
   byte a = something;
   byte b = something;
   byte c = something;
   // multiply b + c avoiding overflow
   short z1 = (short)b * (short)c;
   // add a + z1 avoiding overflow
   int z = (int)a + (int)z1;
   ```
   
   You can understand the limitations at the hardware level better by reading 
https://en.wikichip.org/wiki/x86/avx512_vnni
   `VPDPBUSD` is currently not supported by openjdk either: 
https://bugs.openjdk.org/browse/JDK-8215891


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to