Forming terrestrial planets & impacts
341 Pages
English

Forming terrestrial planets & impacts

-

Downloading requires you to have access to the YouScribe library
Learn all about the services we offer

Description

  • cours magistral - matière potentielle : 11 overview
  • cours magistral - matière potentielle : impacts
  • cours magistral - matière potentielle : universität heidelberg ws
Forming terrestrial planets & impacts Lecture 11 Lecture Universität Heidelberg WS 11/12 Dr. C. Mordasini Based partially on script of Prof. W. Benz Mentor Prof. T. Henning
  • evolution of a simulation with jupiter
  • rich bodies
  • fraction of the final mass of the planets
  • numerical experiment by raymond
  • stages of terrestrial planet formation
  • influence of jupiter
  • mass fraction
  • terrestrial planets
  • mass
  • solar system

Subjects

Informations

Published by
Reads 32
Language English

STREAMS Programming Guide
Sun Microsystems, Inc.
2550 Garcia Avenue
Mountain View, CA 94043-1100
U.S.A.
Part No: 802-5893
August 1997Copyright 1997 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California 94303-4900 U.S.A. All rights reserved.
This product or document is protected by copyright and distributed under licenses restricting its use, copying, distribution, and
decompilation. No part of this product or document may be reproduced in any form by any means without prior written authorization of
Sun and its licensors, if any. Third-party software, including font technology, is copyrighted and licensed from Sun suppliers.
Parts of the product may be derived from Berkeley BSD systems, licensed from the University of California. UNIX is a registered
trademark in the U.S. and other countries, exclusively licensed through X/Open Company, Ltd.
Sun, Sun Microsystems, the Sun logo, SunSoft, SunDocs, SunExpress, tags does not print or display in your document. Do not modify any
text except the attributions you type.–> and Solaris are trademarks, registered trademarks, or service marks of Sun Microsystems, Inc. in
the U.S. and other countries. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC
International, Inc. in the U.S. and other countries. Products bearing SPARC trademarks are based upon an architecture developed by Sun
Microsystems, Inc.
TM
The OPEN LOOK and Sun Graphical User Interface was developed by Sun Microsystems, Inc. for its users and licensees. Sun
acknowledges the pioneering efforts of Xerox in researching and developing the concept of visual or graphical user interfaces for the
computer industry. Sun holds a non-exclusive license from Xerox to the Xerox Graphical User Interface, which license also covers Sun’s
licensees who implement OPEN LOOK GUIs and otherwise comply with Sun’s written license agreements.
RESTRICTED RIGHTS: Use, duplication, or disclosure by the U.S. Government is subject to restrictions of FAR 52.227–14(g)(2)(6/87) and
FAR 52.227–19(6/87), or DFAR 252.227–7015(b)(6/95) and DFAR 227.7202–3(a).
DOCUMENTATION IS PROVIDED “AS IS” AND ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES,
INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR
NON-INFRINGEMENT, ARE DISCLAIMED, EXCEPT TO THE EXTENT THAT SUCH DISCLAIMERS ARE HELD TO BE LEGALLY
INVALID.
Copyright 1997 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, Californie 94303-4900 Etats-Unis. Tous droits réservés.
Ce produit ou document est protégé par un copyright et distribué avec des licences qui en restreignent l’utilisation, la copie, la
distribution, et la décompilation. Aucune partie de ce produit ou document ne peut être reproduite sous aucune forme, par quelque
moyen que ce soit, sans l’autorisation préalable et écrite de Sun et de ses bailleurs de licence, s’il y en a. Le logiciel détenu par des tiers, et
qui comprend la technologie relative aux polices de caractères, est protégé par un copyright et licencié par des fournisseurs de Sun.
Des parties de ce produit pourront être dérivées du système Berkeley BSD licenciés par l’Université de Californie. UNIX est une marque
déposée aux Etats-Unis et dans d’autres pays et licenciée exclusivement par X/Open Company, Ltd.
Sun, Sun Microsystems, le logo Sun, SunSoft, SunDocs, SunExpress, et Solaris sont des marques de fabrique ou des marques déposées, ou
marques de service, de Sun Microsystems, Inc. aux Etats-Unis et dans d’autres pays. Toutes les marques SPARC sont utilisées sous licence
et sont des marques de fabrique ou des marques déposées de SPARC International, Inc. aux Etats-Unis et dans d’autres pays. Les produits
portant les marques SPARC sont basés sur une architecture développée par Sun Microsystems, Inc.
TML’interface d’utilisation graphique OPEN LOOK et Sun a été par Sun Microsystems, Inc. pour ses utilisateurs et licenciés.
Sun reconnaît les efforts de pionniers de Xerox pour la recherche et le développement du concept des interfaces d’utilisation visuelle ou
graphique pour l’industrie de l’informatique. Sun détient une licence non exclusive de Xerox sur l’interface graphique Xerox,
cette licence couvrant également les licenciés de Sun qui mettent en place l’interface d’utilisation graphique OPEN LOOK et qui en outre
se conforment aux licences écrites de Sun.
CETTE PUBLICATION EST FOURNIE “EN L’ETAT” ET AUCUNE GARANTIE, EXPRESSE OU IMPLICITE, N’EST ACCORDEE, Y
COMPRIS DES GARANTIES CONCERNANT LA VALEUR MARCHANDE, L’APTITUDE DE LA PUBLICATION A REPONDRE A UNE
UTILISATION PARTICULIERE, OU LE FAIT QU’ELLE NE SOIT PAS CONTREFAISANTE DE PRODUIT DE TIERS. CE DENI DE
GARANTIE NE S’APPLIQUERAIT PAS, DANS LA MESURE OU IL SERAIT TENU JURIDIQUEMENT NUL ET NON AVENU.
Please
RecycleContents
Preface xv
Part I Application Programming Interface
1. Overview of STREAMS 3
What Is STREAMS? 3
STREAMS Definitions 4
Stream 5
Stream-Head 5
Module 5
Driver 5
Messages 5
Queues 6
streamio 6
Multiplexing 7
Polling 7
Flow Control 7
When to Use STREAMS 7
How STREAMS Works—Application Interface 8
Opening a Stream 8
Closing a Stream 9
Contents iii¤
Controlling Data Flow 9
Simple Stream Example 9
How STREAMS Works—Kernel-level 10
Stream Head 10
Modules 11
Drivers 13
Messages 13
Message Queueing Priority 14
Queues 15
Multiplexing 16
Multithreading 17
STREAMS in Operation 17
Service Interfaces 17
Manipulating Modules 17
2. STREAMS Application-level Components 21 Interfaces 21
STREAMS System Calls 21
Action Summary 23
Opening a STREAMS Device File 23
Initializing Details 24
Queueing 24
Adding and Removing Modules 24
Closing the Stream 25
Closing Delay Details 25
Stream Construction Example 25
Inserting Modules 26
Module and Driver Control 27
3. STREAMS Application-level Mechanisms 31
iv STREAMS Programming Guide August 1997Message Handling 31
Modifying Messages 31
Message Types 32
Control of Stream-Head Processing 32
Message Queueing and Priorities 34
Controlling Flow and Priorities 34
Accessing the Service Provider 35
Closing the Service Provider 38
Sending Data to Service Provider 38
Receiving Data 39
Input and Output Polling 40
Synchronous Input and Output 41
Asynchronous Input and Output 45
Signals 46
Stream as a Controlling Terminal 47
Job Control 47
Allocation and Deallocation 50
Hungup Streams 50
Hangup Signals 51
Accessing the Controlling Terminal 51
4. STREAMS Driver and Module Interfaces 53
System Calls Used 53
Module and Driver ioctl(2)s 54
General ioctl(2) Processing 55
I_STR ioctl(2) Processing 56
Transparent ioctl(2) Processing 56
I_LIST ioctl(2) 57
Other ioctl(2) Commands 59
Contents v¤
Message Direction 61
Flush Handling 62
Flushing Priority Bands 62
5. STREAMS Administration 63
Tools Available 63
Autopush Facility 64
Application Interface 65
Administration Tool Description 67
strace(1M) 67
strlog(9F) 67
strqget(9F) 68
strqset(9F) 68
strerr(1M) 68
6. Pipes and Queues 69
Overview of Pipes and FIFOs 69
Creating and Opening Pipes and FIFOs 70
Using Pipes and FIFOs 71
Flushing Pipes and FIFOs 73
Named Streams 74
Unique Connections 74
Part II Kernel Interfaces
7. STREAMS Framework —Kernel Level 79
Overview of Streams in Kernel Space 79
Stream Head 80
Kernel–level Messages 80
Message Types 80
Message Structure 83
Message Linkage 85
vi STREAMS Programming Guide August 1997Queued Messages 85
Shared Data 86
Sending and Receiving Messages 87
Message Queues and Message Priority 88
Queues 90
queue(9S) Structure 90
Using Queue Information 92
Entry Points 93
open Routine 94
close Routine 96
The put Procedure 97
service Procedure 100
qband(9S) Structure 102
Message Processing 104
Flow Control (in Service Procedures) 105
8. Messages - Kernel Level 111
ioctl(2) Processing 111
Message Allocation and Freeing 112
Recovering From No Buffers 114
Releasing Callback Requests 116
Extended STREAMS Buffers 117
esballoc(9F) Example 118
General ioctl(2) Processing 120
I_STR ioctl(2) Processing 121
Transparent ioctl(2) Messages 123
Transparent ioctl(2) Examples 126
Flush Handling 137
Flushing Priority Bands 138
Contents vii¤
Driver and Module Service Interfaces 143
Service Interface Library Example 145
Message Type Change Rules 151
Signals 152
9. STREAMS Drivers 153 Device Drivers 153
Basic Driver Topics 154
STREAMS Driver Topics 154
STREAMS Configuration Entry Points 155 Initialization Entry Points 156
STREAMS Table-Driven Entry Points 156 Queue Processing Entry Points 157
STREAMS Interrupt Handlers 158
Driver Unloading 159
STREAMS Driver Sample Code 159
Printer Driver Example 159
Cloning 171
Loop-Around Driver 175
Summary 187
Answers to Frequently Asked Questions 187
10. Modules 189
Module Overview 189
STREAMS Module Configuration 189
Module Procedures 190
Filter Module Example 193
Flow Control 196
Design Guidelines 198
Answers to Frequently Asked Questions 199
viii STREAMS Programming Guide August 199711. Configuration 201
Configuring STREAMS Drivers and Modules 201
modlinkage(9S) 202
modldrv(9S) 202
modlstrmod(9S) 203
dev_ops(9S) 203
cb_ops(9S) 203
streamtab(9S) 204
qinit(9S) 204
Entry Points 205
pts(7D) example 205
STREAMS Module Configuration 209
Compilation 209
Kernel Loading 210
Checking Module Type 210
Tunable Parameters 210
autopush(1M) Facility 211
Application Interface 211
12. MultiThreaded STREAMS 215
MT STREAMS Overview 215
MT Framework 216
STREAMS Integrity 217
Message Ordering 217
MT Configurations 217
MT SAFE modules 218
MT UNSAFE Modules 218
Preparing to Port 218
Porting to the SunOS 5.x System 220
Contents ix¤
MT SAFE Modules 221
MT STREAMS Perimeters 221
Perimeter options 222
MT Configuration 223
qprocson(9F)/qprocsoff(9F) 223
qtimeout(9F)/ qunbufcall(9F) 224
qwriter(9F)) 224
qwait(9F) 225
Asynchronous Callbacks 225
Close Race Conditions 225
Module Unloading and esballoc(9F) 226
Use of q_next 226
MT SAFE Modules using Explicit Locks 226
Constraints When Using Locks 227
Preserving Message Ordering 227
Sample Multithreaded Device Driver 228
Sample Multithreaded Module with Outer Perimeter 234
13. Multiplexing 241
Overview of Multiplexing 241
Building a Multiplexer 242
Dismantling a Multiplexer 246
Routing Data Through a Multiplexer 247
Connecting And Disconnecting Lower Streams 248
Connecting Lower Streams 248
Disconnecting Lower Streams 249
Multiplexer Construction Example 250
Multiplexing Driver 251
Upper Write-Put Procedure 253
x STREAMS Programming Guide August 1997