diff --git a/tinyasm/matinvert.cpp b/tinyasm/matinvert.cpp index b307c39240..3429f9f464 100644 --- a/tinyasm/matinvert.cpp +++ b/tinyasm/matinvert.cpp @@ -3,8 +3,12 @@ PetscErrorCode mymatinvert(PetscInt* n, PetscScalar* mat, PetscInt* piv, PetscInt* info, PetscScalar* work) { - PetscCallBLAS("LAPACKgetrf",LAPACKgetrf_(n,n,mat,n,piv,info)); - PetscCallBLAS("LAPACKgetri",LAPACKgetri_(n,mat, n, piv,work,n,info)); + PetscBLASInt *n_blas, *piv_blas, *info_blas; + PetscCall(PetscBLASIntCast(*n, n_blas)); + PetscCall(PetscBLASIntCast(*piv, piv_blas)); + PetscCall(PetscBLASIntCast(*info, info_blas)); + PetscCallBLAS("LAPACKgetrf",LAPACKgetrf_(n_blas, n_blas, mat, n_blas, piv_blas, info_blas)); + PetscCallBLAS("LAPACKgetri",LAPACKgetri_(n_blas, mat, n_blas, piv_blas, work, n_blas, info_blas)); return 0; } diff --git a/tinyasm/tinyasm.cpp b/tinyasm/tinyasm.cpp index 6df4793b15..4c78e46be1 100644 --- a/tinyasm/tinyasm.cpp +++ b/tinyasm/tinyasm.cpp @@ -49,7 +49,7 @@ class BlockJacobi { int numBlocks = dofsPerBlock.size(); PetscInt dof; - int biggestBlock = 0; + PetscInt biggestBlock = 0; for(int p=0; pdata = (void*)blockjacobi; ierr = PetscLogEventEnd(PC_tinyasm_SetASMLocalSubdomains, pc, 0, 0, 0);CHKERRQ(ierr); - return ierr; + return (int) ierr; }); }