anchor.diff:              INTEGER(C_INT), INTENT(IN), VALUE :: lda, ldb, ldc
               REAL(C_FLOAT), INTENT(IN) :: alpha, beta
             END FUNCTION
  +
             ! Query or JIT-generate a function; return zero if it does not exist,
             ! or if JIT is not supported (double-precision).
             TYPE(C_FUNPTR) PURE FUNCTION libxsmm_ddispatch0(              &
  
positive.code:           ENDIF
          END SUBROUTINE
  
          ! Dispatched matrix multiplication (single-precision).
          !DIR$ ATTRIBUTES OFFLOAD:MIC :: libxsmm_smm
          SUBROUTINE libxsmm_smm(                                         &
       &  flags, m, n, k, a, b, c, pa, pb, pc, alpha, beta)
            INTEGER(LIBXSMM_INT_KIND), PARAMETER :: T = LIBXSMM_FLS_KIND
            INTEGER(LIBXSMM_INT_KIND), INTENT(IN) :: flags, m, n, k
            REAL(T), INTENT(IN) :: a(:,:), b(:,:)
            REAL(T), INTENT(INOUT) :: c(:,:)
            TYPE(C_PTR), INTENT(IN), VALUE, OPTIONAL :: pa, pb, pc
            REAL(T), INTENT(IN), OPTIONAL :: alpha, beta
            TYPE(LIBXSMM_SMM_FUNCTION) :: xmm
            IF (LIBXSMM_MAX_MNK.GE.(m * n * k)) THEN
              IF (PRESENT(pa).OR.PRESENT(pb).OR.PRESENT(pc)) THEN
                xmm = libxsmm_sfunction_all(                              &
       &          flags, m, n, k, 0, 0, 0, alpha, beta,                   &
       &          MERGE(LIBXSMM_PREFETCH, LIBXSMM_PREFETCH_SIGNATURE,     &
       &              LIBXSMM_PREFETCH_NONE.NE.LIBXSMM_PREFETCH))
                IF (libxsmm_savailable(xmm)) THEN
                  CALL libxsmm_scall_prf(xmm, a, b, c, pa, pb, pc)
                ELSE
                  CALL libxsmm_sblasmm(                                   &
       &            flags, m, n, k, a, b, c, alpha, beta)
                ENDIF
              ELSE
                xmm = libxsmm_sfunction_ldx(flags, m, n, k, 0, 0, 0)
                IF (libxsmm_savailable(xmm)) THEN
                  CALL libxsmm_scall_abc(xmm, a, b, c)
                ELSE
                  CALL libxsmm_sblasmm(                                   &
       &            flags, m, n, k, a, b, c, alpha, beta)
                ENDIF
              ENDIF
            ELSE
              CALL libxsmm_sblasmm(flags, m, n, k, a, b, c, alpha, beta)
            ENDIF
          END SUBROUTINE
  
          ! Dispatched matrix multiplication (double-precision).
          !DIR$ ATTRIBUTES OFFLOAD:MIC :: libxsmm_dmm
          SUBROUTINE libxsmm_dmm(                                         &
       &  flags, m, n, k, a, b, c, pa, pb, pc, alpha, beta)
            INTEGER(LIBXSMM_INT_KIND), PARAMETER :: T = LIBXSMM_FLD_KIND
            INTEGER(LIBXSMM_INT_KIND), INTENT(IN) :: flags, m, n, k
            REAL(T), INTENT(IN) :: a(:,:), b(:,:)
            REAL(T), INTENT(INOUT) :: c(:,:)
            TYPE(C_PTR), INTENT(IN), VALUE, OPTIONAL :: pa, pb, pc
            REAL(T), INTENT(IN), OPTIONAL :: alpha, beta
            TYPE(LIBXSMM_DMM_FUNCTION) :: xmm
            IF (LIBXSMM_MAX_MNK.GE.(m * n * k)) THEN
              IF (PRESENT(pa).OR.PRESENT(pb).OR.PRESENT(pc)) THEN
                xmm = libxsmm_dfunction_all(                              &
       &          flags, m, n, k, 0, 0, 0, alpha, beta,                   &
       &          MERGE(LIBXSMM_PREFETCH, LIBXSMM_PREFETCH_SIGNATURE,     &
       &              LIBXSMM_PREFETCH_NONE.NE.LIBXSMM_PREFETCH))
                IF (libxsmm_davailable(xmm)) THEN
                  CALL libxsmm_dcall_prf(xmm, a, b, c, pa, pb, pc)
                ELSE
                  CALL libxsmm_dblasmm(                                   &
       &            flags, m, n, k, a, b, c, alpha, beta)
                ENDIF
              ELSE
                xmm = libxsmm_dfunction_ldx(flags, m, n, k, 0, 0, 0)
                IF (libxsmm_davailable(xmm)) THEN
                  CALL libxsmm_dcall_abc(xmm, a, b, c)
                ELSE
                  CALL libxsmm_dblasmm(                                   &
       &            flags, m, n, k, a, b, c, alpha, beta)
                ENDIF
              ENDIF
            ELSE
              CALL libxsmm_dblasmm(flags, m, n, k, a, b, c, alpha, beta)
            ENDIF
          END SUBROUTINE
        END MODULE
  
negative.code: 
          ! Overloaded BLAS routines (single/double precision).
          INTERFACE libxsmm_blasmm
            MODULE PROCEDURE                                              &
       &      libxsmm_sblasmm_ab, libxsmm_dblasmm_ab,                     &
       &      libxsmm_sblasmm, libxsmm_dblasmm
          END INTERFACE
  
          !DIR$ ATTRIBUTES OFFLOAD:MIC :: libxsmm_init
  