On Tue, Apr 8, 2014 at 6:26 AM, TAY wee-beng <zon...@gmail.com> wrote:
> On 8/4/2014 7:58 AM, Matthew Knepley wrote: > > On Mon, Apr 7, 2014 at 6:46 PM, TAY wee-beng <zon...@gmail.com> wrote: > >> On 8/4/2014 12:40 AM, Matthew Knepley wrote: >> >> How about just including petsc.h90 so you get everything. >> >> Thanks, >> >> Matt >> >> Sorry this is my 2nd email. See below for the 1st email. Using >> petsc.h90 gave the error "... segmentation violation signal raised .... >> > > Right, the solution there is not to use a buggy compiler. I suggest gcc. > It is also faster for a lot of code than Intel. > > > My impression was intel is mostly faster. However, does it apply to > gfortran too? Is it also faster for a lot of code than Intel fortran? I'll > give it a go if it's so. However, I remember changing a no. of options to > build and in the end, it was slower. that's a few yrs ago though. > Anything is faster than a seg-faulting compiler. However, we have just run a number of tests in which gcc was faster. Matt > Matt > > >> On Mon, Apr 7, 2014 at 5:19 AM, TAY wee-beng <zon...@gmail.com> wrote: >> >>> Sorry I realised that >>> >>> *#include "finclude/petscdmda.h90"* >>> *#include "finclude/petscksp.h90"* >>> >>> also gave errors: >>> >>> */home/wtay/Lib/petsc-3.4.4_shared_rel/include/finclude/ftn-custom/petscdmda.h90(10): >>> error #5082: Syntax error, found ',' when expecting one of: ( % [ : . = =>* >>> * PetscInt, pointer :: array(:)* >>> *------------------^* >>> */home/wtay/Lib/petsc-3.4.4_shared_rel/include/finclude/ftn-custom/petscdmda.h90(10): >>> error #5082: Syntax error, found END-OF-STATEMENT when expecting one of: ) >>> ,* >>> * PetscInt, pointer :: array(:)* >>> *---------------------------------------^* >>> */home/wtay/Lib/petsc-3.4.4_shared_rel/include/finclude/ftn-custom/petscdmda.h90(11): >>> error #5082: Syntax error, found IDENTIFIER 'N' when expecting one of: ( % >>> [ : . = =>* >>> * PetscInt n* >>> *--------------------^* >>> */home/wtay/Lib/petsc-3.4.4_shared_rel/include/finclude/ftn-custom/petscdmda.h90(12): >>> error #5082: Syntax error, found IDENTIFIER 'IERR' when expecting one of: ( >>> % [ : . = =>* >>> * PetscErrorCode ierr* >>> *-------------------------^* >>> */home/wtay/Lib/petsc-3.4.4_shared_rel/include/finclude/ftn-custom/petscdmda.h90(13): >>> error #5082: Syntax error, found IDENTIFIER 'V' when expecting one of: ( % >>> [ : . = =>* >>> >>> Thank you >>> >>> Yours sincerely, >>> >>> TAY wee-beng >>> >>> On 7/4/2014 6:16 PM, TAY wee-beng wrote: >>> >> >> Here's the 1st email: >> >> Hi, >>> >>> I encountered the error below when compiling my code using intel fortran: >>> >>> /tmp/ifortlPEDlK.i90: catastrophic error: **Internal compiler error: >>> segmentation violation signal raised** Please report this error along with >>> the circumstances in which it occurred in a Software Problem Report. Note: >>> File and line given may not be explicit cause of this error. >>> >>> In the end, I realised that it is due to using *petsc.h90*: >>> >>> module PETSc_solvers >>> >>> use set_matrix >>> >>> ... >>> >>> implicit none >>> >>> contains >>> >>> subroutine semi_momentum_simple_xyz(du,dv,dw) >>> >>> *#include "finclude/petsc.h90"* >>> >>> integer :: i,j,k,ijk,ierr,II !,ro... >>> >>> If I use : >>> >>> >>> >>> >>> *#include "finclude/petsc.h" or * >>> *#include "finclude/petscdmda.h90"* >>> *#include "finclude/petscksp.h90"* >>> >>> Then there is no problem. >>> >>> May I know why this is happening? >>> >>> Although I can now compile and build successfully, is this the right way >>> to go? >>> >>> -- >>> Thank you >>> >>> Yours sincerely, >>> >>> TAY wee-beng >>> >>> >>> >> >> >> -- >> What most experimenters take for granted before they begin their >> experiments is infinitely more interesting than any results to which their >> experiments lead. >> -- Norbert Wiener >> >> >> > > > -- > What most experimenters take for granted before they begin their > experiments is infinitely more interesting than any results to which their > experiments lead. > -- Norbert Wiener > > > -- What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead. -- Norbert Wiener