© Jo Van Hoey 2019
J. Van HoeyBeginning x64 Assembly Programminghttps://doi.org/10.1007/978-1-4842-5076-1_36

36. AVX Matrix Operations

Jo Van Hoey1 
(1)
Hamme, Belgium
 

Instead of summing up a number of possibly interesting AVX instructions, let’s look at some matrix operations using AVX. This is a long chapter with several pages of code; a lot will be familiar, but we will introduce several new instructions here.

We will show matrix multiplication and matrix inversion. In the next chapter, we will show how to transpose a matrix.

Example Matrix Code

Listing 36-1 shows the example code.
; matrix4x4.asm
extern printf
section .data
      fmt0   db    10,"4x4 DOUBLE PRECISION FLOATING POINT MATRICES",10,0
      fmt1   db    10,"This is matrixA:",10,0
      fmt2   db    10,"This ...

Get Beginning x64 Assembly Programming: From Novice to AVX Professional now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.