Cornell Theory Center Aug 23 2000 Porting CCTK to NT at the Cornell Velocity NT Cluster Werner Benger Max-PIanck-Institut für Gravitationsphysik (Albert-Einstein-Institute.

Slides:



Advertisements
Similar presentations
What is Computer Software?. Hardware vs Software Got to have both to get the job done!
Advertisements

The Web Warrior Guide to Web Design Technologies
Java.  Java is an object-oriented programming language.  Java is important to us because Android programming uses Java.  However, Java is much more.
Chapter 8: Programming the Microprocessor. Copyright ©2009 by Pearson Education, Inc. Upper Saddle River, New Jersey All rights reserved. The Intel.
CS490T Advanced Tablet Platform Applications Network Programming Evolution.
Unix Continuum of Tools Do something once: use the command line Do something many times: –Use an alias –Use a shell script Do something that is complex.
Linux+ Guide to Linux Certification, Second Edition
Module 1 Introduction to Network Operating Systems
How Clients and Servers Work Together. Objectives Learn about the interaction of clients and servers Explore the features and functions of Web servers.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 2: Operating-System Structures Modified from the text book.
The Basic Tools Presented by: Robert E., & Jonathan Chase.
Linux Shell. 2 Linux Command-Line Interface ■ Linux shells: A shell is a command interpreter that allows you to type commands from the keyboard to interact.
Perforce (Version Control Software). Perforce is an enterprise version management system in which users connect to a shared file repository. Perforce.
Introduction to The Linaro Toolchain Embedded Processors Training Multicore Software Applications Literature Number: SPRPXXX 1.
1 Introduction to Tool chains. 2 Tool chain for the Sitara Family (but it is true for other ARM based devices as well) A tool chain is a collection of.
INTRODUCTION TO WEB DATABASE PROGRAMMING
Parts of a Computer Why Use Binary Numbers? Source Code - Assembly - Machine Code.
Web Servers Web server software is a product that works with the operating system The server computer can run more than one software product such as .
Unix Primer. Unix Shell The shell is a command programming language that provides an interface to the UNIX operating system. The shell is a “regular”
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
Eclipse Overview Introduction to Web Programming Kirkwood Continuing Education Fred McClurg © Copyright 2015, Fred McClurg, All Rights Reserved.
Development tools cvs, tkdiff, JBuilder, building GATE from the sources.
Enabling the ARM Learning in INDIA ARM DEVELOPMENT TOOL SETUP.
Introduction to NS2 -Network Simulator- -Prepared by Changyong Jung.
July 29, 2003Serguei Mokhov, 1 Makefile Brief Reference COMP 229, 346, 444, 5201 Revision 1.2 Date: July 18, 2004.
Operating Systems Advanced OS - E. OS Advanced Evaluating an Operating System.
Intro to C++ And Some Tools Opening Discussion zHave any questions come up since last class? Have you had a chance to look over the project.
9 Chapter Nine Compiled Web Server Programs. 9 Chapter Objectives Learn about Common Gateway Interface (CGI) Create CGI programs that generate dynamic.
Introduction Use of makefiles to manage the build process Declarative, imperative and relational rules Environment variables, phony targets, automatic.
Shell script
Navigation and Ancillary Information Facility NIF Preparing for Programming Using the SPICE Toolkit January 2009.
Developing C/C++ applications with the Eclipse CDT David Gallardo.
Just as there are many human languages, there are many computer programming languages that can be used to develop software. Some are named after people,
Chapter 2: Linux & POSIX “She sells bash shells by the C shore”
CMT Christian Arnault - LAL - Chep /18 Introduction What is CMT, its goals Operating CMT The concepts in CMT, the internal model Status, implementation.
Editing & Compiling: UNIX vs. IDE and an Intro to Architecture.
1 Programming in C Hello World! Soon I will control the world! Soon I will control the world!
CMake refactoring P. Hristov 19/03/2014. History I  Recursive makefiles (F.Carminati):  Problems in dependencies  Slow  "Recursive Makefiles.
Navigation and Ancillary Information Facility NIF Preparing for Programming Using the SPICE Toolkit January 2008.
Setting up Cygwin Computer Organization I 1 May 2010 ©2010 McQuain Cygwin: getting the setup tool Free, almost complete UNIX environment emulation.
Introduction Copyright © Software Carpentry 2010 This work is licensed under the Creative Commons Attribution License See
CPS120: Introduction to Computer Science Compiling a C++ Program From The Command Line.
1 How to Install OpenGL u Software running under Microsoft Windows makes extensive use of "dynamic link libraries." A dynamic link library (DLL) is a set.
Introduction to UNIX CS 2204 Class meeting 1 *Notes by Doug Bowman and other members of the CS faculty at Virginia Tech. Copyright
Announcements Assignment 1 due Wednesday at 11:59PM Quiz 1 on Thursday 1.
Chapter Linux Basics. Acknowledgements This presentation was prepared by – Banyat Settapanich – Bahran Madaen This presentation will be updated later.
1 CSC160 Chapter 1: Introduction to JavaScript Chapter 2: Placing JavaScript in an HTML File.
1 Week 8 Creating Simple Shell Scripts. 2 Chapter Objectives  In this chapter, you will :  Learn how to create Shell Scripts  Commenting / Making Portable.
EDD/DM Changes for release 2.4 Deb Kerstiens September 4, 1997.
Visual Programming Borland Delphi. Developing Applications Borland Delphi is an object-oriented, visual programming environment to develop 32-bit applications.
Linux Administration Working with the BASH Shell.
Wouter Verkerke, NIKHEF Preparation for La Mainaz or how to run Unix apps and ROOT on your Windows Laptop without installing Linux Wouter Verkerke (NIKHEF)
Environment & Education & More Dan Bothell. Overview Data Teaching Materials Environment Other ACT-R 5.0 and RPM issues.
Cygwin: getting the setup tool
Introduction to Perl: Practical extraction and report language
Tiny http client and server
Client-Server Communication
Introduction to Programming the WWW I
Makefile Tutorial CIS5027 Prof: Dr. Shu-Ching Chen
Prof: Dr. Shu-Ching Chen TA: Samira Pouyanfar Hector Cen Fall 2017
LING 408/508: Computational Techniques for Linguists
Contiki and Code Composer Studio
Cmake Primer.
Electronics II Physics 3620 / 6620
Week 1 – Lesson 2: Creating Shell Scripts, Linux Commands
Lab 4: Introduction to Scripting
Cygwin: getting the setup tool
Preparation for Assignment 2
CSC 253 Lecture 15.
Presentation transcript:

Cornell Theory Center Aug Porting CCTK to NT at the Cornell Velocity NT Cluster Werner Benger Max-PIanck-Institut für Gravitationsphysik (Albert-Einstein-Institute at Golm/Potsdam – AEI) and Konrad-Zuse-Center for Information Technology Berlin (ZIB)

= CYGWIN – Unix GNU Make " CCTK makefiles using lots of gmake special functions = Bash " more powerfull than command.com " Required for `autoconf' configure script " Some shell-commands used in makefiles = Sed " Command line argument conversions when gmake functionality or shell commands are not sufficient = Perl " CCTK Flesh-Thorn interfaces consists of code generated by perl scripts from description files in `Cactus Configuration Language' -.ccl files " Preprocessing of F77,F90,C,C++ = Compilers: C, (C++,) [F77, F90] Porting Cactus to NT – Requirements

Early Difficulties = PERL! " Required at the very earliest step, directly invoked from makefile = ActiveState Perl is installed on the NT Cluster " Incompatible to cygwin perl " Cygwin uses unix-like path names: – /cygdrive/c/temp/Werner/Cactus – //c/temp/Werner/Cactus " ActiveState Perl uses DOS/Windows like path names: – c:\temp\Werner\Cactus c:\temp\Werner\Cactus = Cygwin perl needed to be installed on local workstation, no installation on NT Cluster " Compilation only possible locally = Installation of cygwin perl on NT cluster in local homedir works, but need to specify perl include path on each invokation... = Compilation on NT Cluster very slow anyway...

Cygwin = Cygwin 5.0 installed " Not yet supported by CCTK " Introduces the /cygdrive/ prefix – /cygdrive/c/ for //c in earlier version or c:\ in DOS/Windowsc:\ " Had to adjust makefile includes in a couple of places – $(subst /cygdrive/,//, ) backward compatibility to cygwin 4.0 " external/IEEEIO library explicitely looking for CYGWIN_NT-4.0 – Added support for CYGWIN_NT-5.0 = Environment now set up for use of gcc cygwin compiler – but we want Visual C++!

Cygwin and MS Visual C++ = Unix compiler vs. MS compiler " Path names: c:\temp\Werner\Cactus vs. //c/temp/Werner/Cactusc:\temp\Werner\Cactus " Command line switches: /Ic:\library\include -I/include " Extensions: – Object files:.o vs..obj works, as MSC treats unkown extensions as object files – Libraries: lib.a vs. xxx.lib lib/make/make.thornlib to be modified to transform unix libname into MSC libname – Executable:.exe Ok, already handled " Still want to use cygwin gcc to create dependency information for makefiles – In some parts cygwin pathnames and parameters – Other parts MSC pathnames and parameters – Pathname conversion routines required – #define's and #include paths from MSC need to be set for gcc, too!

Pathname Conversion = Task: Convert /cygdrive/c/temp/Werner/ to c:\temp\Wernerc:\temp\Werner " Using sed is powerful, but requires external tool and is slow " GNU make functions are fast, but limited " Well, can still be done: LETTERS= a b c d e f g h i j k l m n o p q r s t u v w x y z \ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z INCLUDE_PARAMETERS=$(subst -I,/I,$(subst /,\\, $(foreach DRIVE, $(LETTERS), $(filter - I$(DRIVE):%,$(subst //$(DRIVE),$(DRIVE):,$(subst /cygdrive/,//,$(INC_DIRS:%=-I%))))))) INC_DIRS=/cygdrive/h/PROGRA~1/MPIPRO //c/PROGRA~1/MICROS~2/VC98/INCLUDE INCLUDE_PARAMETERS=$(INCLUDE_PARAMETERS) WEYL://c/temp/werner $ make show INC_DIRS=/cygdrive/h/PROGRA~1/MPIPRO //c/PROGRA~1/MICROS~2/VC98/INCLUDE INCLUDE_PARAMETERS= /Ic:\PROGRA~1\MICROS~2\VC98\INCLUDE /Ih:\PROGRA~1\MPIPRO WEYL://c/temp/werner $

Properties of Pathname conversion = - Pathnames must not contain spaces " Uses windows shortcut names instead of long names – //c/PROGRA~1/MICROS~2/VC98/INCLUDE – //c/Program Files/Microsoft Visual Studio/VC98/INCLUDE " Find out by starting `command.com' from bash = + Late evalutation in make " May define make expression first " May set of variable to expanded later " Make function is evaluated not before it is actually used = + Much faster than calling sed scripts = + Doesn't require external tool (directly portable) = - Need to copy the expression for each make variable to be used = - Hardly readable... so better don't touch and avoid using too often

Minor changes = Support for MPIPro  Added shell script: lib/make/extras/MPI/MPIPro  Some fixes in the lib/make/know-architectures/cygwin default variables " CC=cl " CXX="$CC /TP" " AR=lib " Etc. = Editing Thornlist: " `preferred editor' is `notepad' under Windows " Changed lib/make/make.configuration " But this might be a matter of taste, other people might still prefer `vi'... " Can't run notepad from telnet session...

Networking = TCP calls (mostly already done for SC99 NCSA NT Cluster) " Similar, but still minor differences between Unix and Windows – read(),write() vs. recv(), send() – close() vs. Closesocket() – etc. " Conversion of socket descriptor to file descriptor not possible (?) " Cannot use C++ Standard Stream library for sockets!? – No ofstream(int fd) constructor... – Had to provide a `stream emulator class' under windows = TCP Initialization " Windows Socket Layer must be initialized before any TCP networking works!!  WSAStartup() " C++ Constructor Call or CCTK Startup Routine = HTTP Support for MSIE " Requires explicit HTTP header where netscape doesn't " `Movie Thorn': multipart encoding of streamed jpeg images works with Netscape, but not yet with MSIE... (?)

At last: it worked.