deallocate-BCGS.inc
#ifdef use_allocatable
if (allocated(d)) deallocate( d )
#else
# if defined(mmsl)
if (ipd .ne. 0) then
call MMRELBLK ('d-BCGS', '-BCGS', ipd, memerr)
endif
# elif defined(mms)
if (ipd .ne. 0) call RELVAR ('d-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipd .ne. 0) call FREE (ipd)
# elif defined(aix)
if (ipd .ne. 0) call FREE (%val(ipd))
# elif defined(cray)
if (ipd .ne. 0) call HPDEALLC (ipd, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(h)) deallocate( h )
#else
# if defined(mmsl)
if (iph .ne. 0) then
call MMRELBLK ('h-BCGS', '-BCGS', iph, memerr)
endif
# elif defined(mms)
if (iph .ne. 0) call RELVAR ('h-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (iph .ne. 0) call FREE (iph)
# elif defined(aix)
if (iph .ne. 0) call FREE (%val(iph))
# elif defined(cray)
if (iph .ne. 0) call HPDEALLC (iph, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(q)) deallocate( q )
#else
# if defined(mmsl)
if (ipq .ne. 0) then
call MMRELBLK ('q-BCGS', '-BCGS', ipq, memerr)
endif
# elif defined(mms)
if (ipq .ne. 0) call RELVAR ('q-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipq .ne. 0) call FREE (ipq)
# elif defined(aix)
if (ipq .ne. 0) call FREE (%val(ipq))
# elif defined(cray)
if (ipq .ne. 0) call HPDEALLC (ipq, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(r)) deallocate( r )
#else
# if defined(mmsl)
if (ipr .ne. 0) then
call MMRELBLK ('r-BCGS', '-BCGS', ipr, memerr)
endif
# elif defined(mms)
if (ipr .ne. 0) call RELVAR ('r-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipr .ne. 0) call FREE (ipr)
# elif defined(aix)
if (ipr .ne. 0) call FREE (%val(ipr))
# elif defined(cray)
if (ipr .ne. 0) call HPDEALLC (ipr, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(u)) deallocate( u )
#else
# if defined(mmsl)
if (ipu .ne. 0) then
call MMRELBLK ('u-BCGS', '-BCGS', ipu, memerr)
endif
# elif defined(mms)
if (ipu .ne. 0) call RELVAR ('u-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipu .ne. 0) call FREE (ipu)
# elif defined(aix)
if (ipu .ne. 0) call FREE (%val(ipu))
# elif defined(cray)
if (ipu .ne. 0) call HPDEALLC (ipu, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(g)) deallocate( g )
#else
# if defined(mmsl)
if (ipg .ne. 0) then
call MMRELBLK ('g-BCGS', '-BCGS', ipg, memerr)
endif
# elif defined(mms)
if (ipg .ne. 0) call RELVAR ('g-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipg .ne. 0) call FREE (ipg)
# elif defined(aix)
if (ipg .ne. 0) call FREE (%val(ipg))
# elif defined(cray)
if (ipg .ne. 0) call HPDEALLC (ipg, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(v)) deallocate( v )
#else
# if defined(mmsl)
if (ipv .ne. 0) then
call MMRELBLK ('v-BCGS', '-BCGS', ipv, memerr)
endif
# elif defined(mms)
if (ipv .ne. 0) call RELVAR ('v-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipv .ne. 0) call FREE (ipv)
# elif defined(aix)
if (ipv .ne. 0) call FREE (%val(ipv))
# elif defined(cray)
if (ipv .ne. 0) call HPDEALLC (ipv, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(w)) deallocate( w )
#else
# if defined(mmsl)
if (ipw .ne. 0) then
call MMRELBLK ('w-BCGS', '-BCGS', ipw, memerr)
endif
# elif defined(mms)
if (ipw .ne. 0) call RELVAR ('w-BCGS', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipw .ne. 0) call FREE (ipw)
# elif defined(aix)
if (ipw .ne. 0) call FREE (%val(ipw))
# elif defined(cray)
if (ipw .ne. 0) call HPDEALLC (ipw, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(work)) deallocate( work )
#else
# if defined(mmsl)
if (ipwork .ne. 0) then
call MMRELBLK ('work-BCG', '-BCGS', ipwork, memerr)
endif
# elif defined(mms)
if (ipwork .ne. 0) call RELVAR ('work-BCG', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipwork .ne. 0) call FREE (ipwork)
# elif defined(aix)
if (ipwork .ne. 0) call FREE (%val(ipwork))
# elif defined(cray)
if (ipwork .ne. 0) call HPDEALLC (ipwork, memerr, 0)
# endif
#endif
#ifdef use_allocatable
if (allocated(xold)) deallocate( xold )
#else
# if defined(mmsl)
if (ipxold .ne. 0) then
call MMRELBLK ('xold-BCG', '-BCGS', ipxold, memerr)
endif
# elif defined(mms)
if (ipxold .ne. 0) call RELVAR ('xold-BCG', memerr)
# elif defined(sun) || defined(hpux) || defined(irix) || defined(osf1)
if (ipxold .ne. 0) call FREE (ipxold)
# elif defined(aix)
if (ipxold .ne. 0) call FREE (%val(ipxold))
# elif defined(cray)
if (ipxold .ne. 0) call HPDEALLC (ipxold, memerr, 0)
# endif
#endif