[Swift-commit] r6337 - in SwiftTutorials/IO: . staging-normal

davidk at ci.uchicago.edu davidk at ci.uchicago.edu
Wed Mar 6 10:59:48 CST 2013


Author: davidk
Date: 2013-03-06 10:59:48 -0600 (Wed, 06 Mar 2013)
New Revision: 6337

Added:
   SwiftTutorials/IO/staging-normal/
   SwiftTutorials/IO/staging-normal/catsn-absolute.swift
   SwiftTutorials/IO/staging-normal/catsn-random.swift
   SwiftTutorials/IO/staging-normal/cf
   SwiftTutorials/IO/staging-normal/gendata.pl
   SwiftTutorials/IO/staging-normal/setup.sh
   SwiftTutorials/IO/staging-normal/sites.xml
Log:
staging-normal scripts


Added: SwiftTutorials/IO/staging-normal/catsn-absolute.swift
===================================================================
--- SwiftTutorials/IO/staging-normal/catsn-absolute.swift	                        (rev 0)
+++ SwiftTutorials/IO/staging-normal/catsn-absolute.swift	2013-03-06 16:59:48 UTC (rev 6337)
@@ -0,0 +1,12 @@
+type file;
+
+app (file o) cat (file i)
+{
+  cat @i stdout=@o;
+}
+
+file out[]<simple_mapper; location=".", prefix="catsn.",suffix=".out">;
+foreach j in [1:@toInt(@arg("n","10"))] {
+  file data <"file:///home/davidk/test4/data/data.txt">;
+  out[j] = cat(data);
+}

Added: SwiftTutorials/IO/staging-normal/catsn-random.swift
===================================================================
--- SwiftTutorials/IO/staging-normal/catsn-random.swift	                        (rev 0)
+++ SwiftTutorials/IO/staging-normal/catsn-random.swift	2013-03-06 16:59:48 UTC (rev 6337)
@@ -0,0 +1,13 @@
+type file;
+
+app (file o) cat (file i)
+{
+  cat @i stdout=@o;
+}
+
+file input_files[]<filesys_mapper; location="data", pattern="tmp.*">;
+
+foreach j in input_files {
+  file output<single_file_mapper; location="data", file=@strcat(@filename(j), ".out")>;
+  output = cat(j);
+}

Added: SwiftTutorials/IO/staging-normal/cf
===================================================================
--- SwiftTutorials/IO/staging-normal/cf	                        (rev 0)
+++ SwiftTutorials/IO/staging-normal/cf	2013-03-06 16:59:48 UTC (rev 6337)
@@ -0,0 +1,8 @@
+wrapperlog.always.transfer=true
+sitedir.keep=true
+execution.retries=0
+lazy.errors=true
+status.mode=provider
+use.provider.staging=false
+provider.staging.pin.swiftfiles=false
+use.wrapper.staging=false

Added: SwiftTutorials/IO/staging-normal/gendata.pl
===================================================================
--- SwiftTutorials/IO/staging-normal/gendata.pl	                        (rev 0)
+++ SwiftTutorials/IO/staging-normal/gendata.pl	2013-03-06 16:59:48 UTC (rev 6337)
@@ -0,0 +1,22 @@
+#!/usr/bin/perl
+
+use strict;
+
+my @characters=('a'..'z', 'A'..'Z', '0'..'9');
+my $string="";
+my $length = $ARGV[0];
+my $width_count=0;
+
+foreach (1..$length) 
+{
+   if($width_count == 80) {
+      $string .= "\n";
+      $width_count=0;
+      next;
+   }
+   $string .= $characters[rand @characters];
+   $width_count++;
+}
+
+print $string;
+


Property changes on: SwiftTutorials/IO/staging-normal/gendata.pl
___________________________________________________________________
Added: svn:executable
   + *

Added: SwiftTutorials/IO/staging-normal/setup.sh
===================================================================
--- SwiftTutorials/IO/staging-normal/setup.sh	                        (rev 0)
+++ SwiftTutorials/IO/staging-normal/setup.sh	2013-03-06 16:59:48 UTC (rev 6337)
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+NUMFILES=500
+FILESIZE=10
+FILESIZE=$(($FILESIZE*1000000))
+
+if [ -n "$GROUP" ]; then
+   cp $RUNDIR/* .
+fi
+
+mkdir -p data
+for count in `seq 1 $NUMFILES` 
+do
+   FILENAME=`mktemp -p data`
+   ./gendata.pl $FILESIZE > $FILENAME
+done
+


Property changes on: SwiftTutorials/IO/staging-normal/setup.sh
___________________________________________________________________
Added: svn:executable
   + *

Added: SwiftTutorials/IO/staging-normal/sites.xml
===================================================================
--- SwiftTutorials/IO/staging-normal/sites.xml	                        (rev 0)
+++ SwiftTutorials/IO/staging-normal/sites.xml	2013-03-06 16:59:48 UTC (rev 6337)
@@ -0,0 +1,10 @@
+<config>
+   <pool handle="local">
+      <execution provider="local" url="none"/>
+      <profile namespace="karajan" key="jobThrottle">0</profile>
+      <profile namespace="karajan" key="initialScore">10000</profile>
+      <filesystem provider="local"/>
+      <workdirectory>/home/davidk/swiftwork</workdirectory>
+      <scratch>/scratch/local/davidk/swiftwork</scratch>
+   </pool>
+</config>




More information about the Swift-commit mailing list