~chirality-flow/chiralityflow/ChiralityFlowMG

« back to all changes in this revision

Viewing changes to vendor/StdHEP/src/stdhep/stdxwcm1.F

  • Committer: andrew.lifson at lu
  • Date: 2021-09-02 13:57:34 UTC
  • Revision ID: andrew.lifson@thep.lu.se-20210902135734-4eybgli0iljkax9b
added fresh copy of MG5_aMC_v3.2.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
      subroutine stdxwcm1(ilbl,istream,lok)
 
2
 
 
3
C...Purpose: to write begin/end run information in a standard format
 
4
C
 
5
C       if ilbl = 100   write STDHEP begin run record
 
6
C       if ilbl = 200   write STDHEP end run record
 
7
C
 
8
C       lok = 0 if no problems were encountered
 
9
 
 
10
#include "stdcm1.inc"
 
11
#include "stdcnt.inc"
 
12
#include "stdlun.inc"
 
13
#include "mcfio.inc"
 
14
 
 
15
      integer ilbl,lok
 
16
      integer xdr_stdhep_cm1
 
17
      external xdr_stdhep_cm1
 
18
 
 
19
      lok=0
 
20
      if(nevtlh.eq.0) nevtlh = nlhwrt
 
21
      if(ilbl.eq.100)then
 
22
        if(mcfio_block(istream, MCFIO_STDHEPBEG, xdr_stdhep_cm1)
 
23
     1      .eq. -1) go to 800
 
24
        if(mcfio_NextEvent(istream) .eq. -1) go to 900
 
25
      elseif(ilbl.eq.200)then
 
26
        if(mcfio_block(istream, MCFIO_STDHEPEND, xdr_stdhep_cm1)
 
27
     1      .eq. -1) go to 800
 
28
        if(mcfio_NextEvent(istream) .eq. -1) go to 900
 
29
      else
 
30
        lok = 3
 
31
        write (lnhout,701) ilbl
 
32
      endif
 
33
 
 
34
      return
 
35
  800 write (lnhout,801) ilbl
 
36
      lok=2
 
37
      stop
 
38
  900 write (lnhout,901)
 
39
      lok=1
 
40
      stop
 
41
  701 format(/5X,'STDXWCM1: called with improper label ',i4)
 
42
  801 format(/5X,'STDXWCM1: error filling stdhep cm1 block for label '
 
43
     1       ,i4)
 
44
  901 format(/5X,'STDXWCM1: error writing stdhep cm1 block ')
 
45
      end
 
46