Miguel Osorio | 40caa9e | 2021-05-27 21:45:20 -0700 | [diff] [blame] | 1 | --- |
| 2 | title: "OTBN Code Snippets" |
| 3 | --- |
Rupert Swarbrick | 1047ba2 | 2020-07-20 11:32:59 +0100 | [diff] [blame] | 4 | |
| 5 | This directory contains some code snippets that give examples of how |
| 6 | to do various tasks in OTBN code. |
| 7 | |
Miguel Osorio | 40caa9e | 2021-05-27 21:45:20 -0700 | [diff] [blame] | 8 | - `modexp.s`: An example of how to do modular exponentiation. |
| 9 | - `pseudo-ops.s`: An example of the pseudo-operations supported by the OTBN ISA. |
| 10 | - `mul256.s`: An example of a 256x256 bit multiply using the MULQACC |
| 11 | instruction. |
| 12 | - `mul384.s`: An example of a 384x384 bit multiply using the MULQACC |
| 13 | instruction. |
| 14 | - `barrett384.s`: An example of a modular multiplication kernel based on |
| 15 | Barrett reduction. |
Rupert Swarbrick | c803d02 | 2020-10-20 11:16:45 +0100 | [diff] [blame] | 16 | |
| 17 | Also included in this directory is a Makefile fragment that can be |
| 18 | used to assemble and link the snippets. This can be used standalone or |
| 19 | included in another Makefile. |