PetscMalloc1/PetscFree take void pointers
Unroll entity dofs into C pointers

Removes final python calls from inner loop.