NB: This Coq documentation contains a revised version of the Coq implementation of these papers [1], [2], [3], [4], and is also the support for ongoing research. A partial archive (14/01/2001) is available at here. Drop us a line if you are interested in a complete, up-to-date archive.

Library multi_add_prg

Require Import machine_int.
Require Import mips_cmd.

Local Open Scope mips_cmd_scope.
Import expr_m.

Definition multi_add (k one a b c t j atmp : reg) :=
  addiu j r0 zero16 ;
  addiu t c zero16 ;
  multu r0 r0 ;
  while.while (bne j k) (
    lwxs atmp j a ;
    maddu atmp one ;
    lwxs atmp j b ;
    maddu atmp one ;
    mflhxu atmp ;
    sw atmp zero16 t ;
    addiu t t four16 ;
    addiu j j one16).