Merge commit 'v2.0.1-947-g0350ff5'

This commit is contained in:
Test User 2017-10-07 03:52:18 +02:00
commit 778c60c233
3 changed files with 25 additions and 11 deletions

View File

@ -1 +1 @@
v2.0.1-941-g05bb3c1 v2.0.1-946-g5011e20

View File

@ -1587,6 +1587,8 @@ subroutine IO_error(error_ID,el,ip,g,instance,ext_msg)
! DAMASK_marc errors ! DAMASK_marc errors
case (700_pInt) case (700_pInt)
msg = 'invalid materialpoint result requested' msg = 'invalid materialpoint result requested'
case (701_pInt)
msg = 'not supported input file format, use Marc 2016 or earlier'
!------------------------------------------------------------------------------------------------- !-------------------------------------------------------------------------------------------------
! errors related to spectral solver ! errors related to spectral solver

View File

@ -706,7 +706,6 @@ integer(pInt) function mesh_FEasCP(what,myID)
mesh_FEasCP = lookupMap(2_pInt,upper) mesh_FEasCP = lookupMap(2_pInt,upper)
return return
endif endif
! this might be the reason for the heap problems
binarySearch: do while (upper-lower > 1_pInt) binarySearch: do while (upper-lower > 1_pInt)
center = (lower+upper)/2_pInt center = (lower+upper)/2_pInt
if (lookupMap(1_pInt,center) < myID) then if (lookupMap(1_pInt,center) < myID) then
@ -1692,13 +1691,15 @@ subroutine mesh_marc_count_cpElements(fileUnit)
use IO, only: IO_lc, & use IO, only: IO_lc, &
IO_stringValue, & IO_stringValue, &
IO_stringPos, & IO_stringPos, &
IO_countContinuousIntValues IO_countContinuousIntValues, &
IO_error, &
IO_intValue
implicit none implicit none
integer(pInt), intent(in) :: fileUnit integer(pInt), intent(in) :: fileUnit
integer(pInt), allocatable, dimension(:) :: chunkPos integer(pInt), allocatable, dimension(:) :: chunkPos
integer(pInt) :: i integer(pInt) :: i, version
character(len=300):: line character(len=300):: line
mesh_NcpElems = 0_pInt mesh_NcpElems = 0_pInt
@ -1709,15 +1710,26 @@ subroutine mesh_marc_count_cpElements(fileUnit)
do do
read (fileUnit,610,END=620) line read (fileUnit,610,END=620) line
chunkPos = IO_stringPos(line) chunkPos = IO_stringPos(line)
if ( IO_lc(IO_stringValue(line,chunkPos,1_pInt)) == 'version') then
if ( IO_lc(IO_stringValue(line,chunkPos,1_pInt)) == 'hypoelastic') then version = IO_intValue(line,chunkPos,2_pInt)
do i=1_pInt,3_pInt+hypoelasticTableStyle ! Skip 3 or 4 lines if (version < 13) then ! Marc 2016 or earlier
rewind(fileUnit)
do
read (fileUnit,610,END=620) line read (fileUnit,610,END=620) line
chunkPos = IO_stringPos(line)
if ( IO_lc(IO_stringValue(line,chunkPos,1_pInt)) == 'hypoelastic') then
do i=1_pInt,3_pInt+hypoelasticTableStyle ! Skip 3 or 4 lines
read (fileUnit,610,END=620) line
enddo
mesh_NcpElems = mesh_NcpElems + IO_countContinuousIntValues(fileUnit) ! why not simply mesh_NcpElems = IO_countContinuousIntValues(fileUnit)? keyword hypoelastic might appear several times
exit
endif
enddo enddo
mesh_NcpElems = mesh_NcpElems + IO_countContinuousIntValues(fileUnit) ! why not simply mesh_NcpElems = IO_countContinuousIntValues(fileUnit)? else ! Marc2017 and later
exit call IO_error(error_ID=701_pInt)
endif end if
enddo end if
enddo
620 end subroutine mesh_marc_count_cpElements 620 end subroutine mesh_marc_count_cpElements