]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
A raw-data file and Tree size limit is increased to 20GB. Wherever is needed the...
authorcvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 16 Jan 2008 16:19:04 +0000 (16:19 +0000)
committercvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 16 Jan 2008 16:19:04 +0000 (16:19 +0000)
RAW/AliMDC.cxx
RAW/AliMDC.h
RAW/AliRawDB.cxx
RAW/AliRawDB.h
RAW/alimdc_main.cxx
RAW/mdc.cxx
RAW/mdc.h

index 2a7ae0e7b2a3b284c0e7737ed1108fff23edc6fe..63ccc25c0da5a1d4c3fbe3603d04e1ef6e9e031c 100644 (file)
@@ -1,4 +1,4 @@
-// @(#) $Id$
+// @(#)alimdc:$Name:  $:$Id$
 // Author: Fons Rademakers  26/11/99
 // Updated: Dario Favretto  15/04/2003
 
@@ -119,6 +119,10 @@ AliMDC::AliMDC(Int_t compress, Bool_t deleteFiles, EFilterMode filterMode,
   // Optional 'guidFileFolder' specifies the folder in which *.guid files
   // will be stored. In case this option is not given, the *.guid files
   // will be written to the same folder as the raw-data files.
+
+  // Set the maximum tree size to 19GB
+  // in order to allow big raw data files
+  TTree::SetMaxTreeSize(20000000000LL);
  
   // This line is needed in case of a stand-alone application w/o
   // $ROOTSYS/etc/system.rootrc file
@@ -234,11 +238,11 @@ Int_t AliMDC::ProcessEvent(void* event, Bool_t isIovecArray)
 // or, if isIovecArray is kTRUE, a pointer to an array of iovecs with one
 // iovec per subevent (used by the event builder).
 // The return value is the number of written bytes or an error code
-  const UInt_t kFileSizeErrorLevel   = 1900000000;
+  const Long64_t kFileSizeErrorLevel   = 19000000000LL;
 
-  UInt_t currentFileSize = GetTotalSize();
+  Long64_t currentFileSize = GetTotalSize();
   if(currentFileSize > kFileSizeErrorLevel) {
-    Error("ProcessEvent", "file size (%u) exceeds the limit "
+    Error("ProcessEvent", "file size (%lu) exceeds the limit "
          , currentFileSize);
     return kErrFileSize;
   }
@@ -415,7 +419,7 @@ Int_t AliMDC::ProcessEvent(void* event, Bool_t isIovecArray)
 }
 
 //______________________________________________________________________________
-Int_t AliMDC::GetTotalSize()
+Long64_t AliMDC::GetTotalSize()
 {
 // return the total current raw DB file size
 
index bc59cd5cf5d8f8bebf7f14e4fe5de08730f3d017..4306430e5bd9996c83ff678c5dacd7fdaf9a93dd 100644 (file)
@@ -1,6 +1,6 @@
 #ifndef ALIMDC_H
 #define ALIMDC_H
-// @(#) $Id$
+// @(#)alimdc:$Name:  $:$Id$
 // Author: Fons Rademakers  26/11/99
 
 /* Copyright(c) 1998-2003, ALICE Experiment at CERN, All rights reserved. *
@@ -71,7 +71,7 @@ public:
                   Double_t maxFileSize = 0,
                   const char* fs1 = NULL, const char* fs2 = NULL);
    Int_t      ProcessEvent(void* event, Bool_t isIovecArray = kFALSE);
-   Int_t      GetTotalSize();
+   Long64_t   GetTotalSize();
    Int_t      Close();
 
    Int_t      Run(const char* inputFile, Bool_t loop,
index a02f225e43fdbf50609da97397378a36a0a49500..88095a953894100a1c24a6dbbd419d8699d215b0 100644 (file)
@@ -1,4 +1,4 @@
-// @(#) $Id$
+// @(#)alimdc:$Name:  $:$Id$
 // Author: Fons Rademakers  26/11/99
 
 /**************************************************************************
@@ -49,7 +49,7 @@
 
 ClassImp(AliRawDB)
 
-const char *AliRawDB::fgkAliRootTag = "$Name$";
+const char *AliRawDB::fgkAliRootTag = "$Rev$";
 
 // Split TPC into 9 branches in order to avoid problems with big memory
 // consumption in case of TPC events w/o zero-suppression
@@ -267,7 +267,7 @@ void AliRawDB::MakeTree()
    // Create ROOT Tree object container.
 
    fTree = new TTree("RAW", Form("ALICE raw-data tree (%s)", GetAliRootTag()));
-   fTree->SetAutoSave(2000000000);  // autosave when 2 Gbyte written
+   fTree->SetAutoSave(21000000000LL);  // autosave when 21 Gbyte written
 
    fTree->BranchRef();
 
@@ -292,7 +292,7 @@ void AliRawDB::MakeTree()
 
    if (fESD) {
      fESDTree = new TTree("esdTree", Form("ALICE HLT ESD tree (%s)", GetAliRootTag()));
-     fESDTree->SetAutoSave(2000000000);  // autosave when 2 Gbyte written
+     fESDTree->SetAutoSave(21000000000LL);  // autosave when 21 Gbyte written
      split   = 0;
      fESDTree->Branch("ESD", "AliESDEvent", &fESD, bufsize, split);
    }
@@ -383,10 +383,10 @@ Int_t AliRawDB::Fill()
 }
 
 //______________________________________________________________________________
-Int_t AliRawDB::GetTotalSize()
+Long64_t AliRawDB::GetTotalSize()
 {
    // Return the total size of the trees
-  Int_t total = 0;
+  Long64_t total = 0;
 
   {
     Int_t skey = 0;
@@ -395,7 +395,7 @@ Int_t AliRawDB::GetTotalSize()
       TKey *key = dir->GetKey(fTree->GetName());
       if (key) skey = key->GetKeylen();
     }
-    total += skey + fTree->GetZipBytes();
+    total += (Long64_t)skey + fTree->GetZipBytes();
   }
 
   if(fESDTree)
@@ -406,7 +406,7 @@ Int_t AliRawDB::GetTotalSize()
        TKey *key = dir->GetKey(fESDTree->GetName());
        if (key) skey = key->GetKeylen();
       }
-      total += skey + fESDTree->GetZipBytes();
+      total += (Long64_t)skey + fESDTree->GetZipBytes();
     }
 
   return total;
@@ -463,7 +463,7 @@ const char *AliRawDB::GetAliRootTag()
 
   TString version = fgkAliRootTag;
   version.Remove(TString::kBoth,'$');
-  version.ReplaceAll("Name","AliRoot version");
+  version.ReplaceAll("LastChangedRevision","AliRoot version");
 
   return version.Data();
 }
index 112c58fd8658ba44c614593923dac46edc5334f3..58593051abf79e43b3efa2d082981a0ebc895ee9 100644 (file)
@@ -1,6 +1,6 @@
 #ifndef ALIRAWDB_H
 #define ALIRAWDB_H
-// @(#) $Id$
+// @(#)alimdc:$Name:  $:$Id$
 // Author: Fons Rademakers  26/11/99
 
 /* Copyright(c) 1998-2003, ALICE Experiment at CERN, All rights reserved. *
@@ -51,7 +51,7 @@ public:
    virtual Bool_t      Create(const char* fileName = NULL);
    virtual Int_t       Close();
    Int_t               Fill();
-   Int_t               GetTotalSize();
+   Long64_t            GetTotalSize();
 
    void         WriteStats(AliStats* stats);
 
index e2007dde49a842723e385a95f5e722d0476b9255..846ca09c64c9a0d2c6f0cb77ec6332fda647abbb 100644 (file)
@@ -1,4 +1,4 @@
-// @(#) $Id$
+// @(#)alimdc:$Name:  $:$Id$
 // Author: Fons Rademakers  26/11/99
 
 //////////////////////////////////////////////////////////////////////////
@@ -210,17 +210,17 @@ int main(int argc, char **argv)
    // no special arg checking so don't make errors
    if (argv[iarg][0] == '-') {
       delFiles = kTRUE;
-      maxFileSize = atoi(argv[iarg]+1);
+      maxFileSize = atoll(argv[iarg]+1);
    } else
-      maxFileSize = atoi(argv[iarg]);
-   if (maxFileSize < 1000 || maxFileSize > 2.e9) {
+      maxFileSize = atoll(argv[iarg]);
+   if (maxFileSize < 1000 || maxFileSize > 20.e9) {
       Error(argv[0], "unreasonable file size %f\n", maxFileSize);
       return 1;
    }
    iarg++;
 
    maxTagSize = atoi(argv[iarg]);
-   if (maxTagSize > 0 && (maxTagSize < 1000 || maxTagSize > 2.e9)) {
+   if (maxTagSize > 0 && (maxTagSize < 1000 || maxTagSize > 20.e9)) {
       Error(argv[0], "unreasonable tag file size %f\n", maxTagSize);
       return 1;
    }
index b32735d69c7c1432c0f211d258e9b7b0f3065f96..07205273d76ed1e2cc45e97f061bbf3411cf0528 100644 (file)
@@ -51,7 +51,7 @@ int alimdcProcessEvent(void* alimdc, void* event, int isIovecArray)
   return ((AliMDC*)alimdc)->ProcessEvent(event, isIovecArray);
 }
 
-int alimdcGetTotalFileSize(void* alimdc)
+long long alimdcGetTotalFileSize(void* alimdc)
 {
 // return the total current file size
 
index 1801f88aeed787904e1e0b3593e26d4350ab66e0..37db1927ba8e318c02b82d9b04592c4144ad09c1 100644 (file)
--- a/RAW/mdc.h
+++ b/RAW/mdc.h
@@ -20,7 +20,7 @@ void* alimdcCreate(int compress, int filterMode,
                   const char* guidFileFolder);
 int   alimdcOpen(void* alimdc, int mode, const char* fileName);
 int   alimdcProcessEvent(void* alimdc, void* event, int isIovecArray);
-int   alimdcGetTotalFileSize(void* alimdc);
+long long  alimdcGetTotalFileSize(void* alimdc);
 int   alimdcClose(void* alimdc);
 void  alimdcDelete(void* alimdc);
 void  alimdcEnableDebug();