Changes in / [41fcd94:eb7f20c]


Ignore:
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • doc/papers/general/Paper.tex

    r41fcd94 reb7f20c  
    22
    33\usepackage{fullpage}
    4 \usepackage{epic,eepic}
    54\usepackage{xspace,calc,comment}
    65\usepackage{upquote}                                                                    % switch curled `'" to straight
     
    3736%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3837
    39 \newcommand{\Textbf}[2][red]{{\color{#1}{\textbf{#2}}}}
     38\newcommand{\Textbf}[1]{{\color{red}\textbf{#1}}}
    4039\newcommand{\TODO}[1]{\textbf{TODO}: {\itshape #1}} % TODO included
    4140%\newcommand{\TODO}[1]{} % TODO elided
     
    10531052\label{s:WithClauseStatement}
    10541053
    1055 Grouping heterogenous data into \newterm{aggregate}s (structure/union) is a common programming practice, and an aggregate can be further organized into more complex structures, such as arrays and containers:
     1054Grouping heterogenous data into \newterm{aggregate}s is a common programming practice, and an aggregate can be further organized into more complex structures, such as arrays and containers:
    10561055\begin{cfa}
    1057 struct S {                                                                      $\C{// aggregate}$
    1058         char c;                                                                 $\C{// fields}$
     1056struct S {                                                              $\C{// aggregate}$
     1057        char c;                                                         $\C{// fields}$
    10591058        int i;
    10601059        double d;
     
    10621061S s, as[10];
    10631062\end{cfa}
    1064 However, routines manipulating aggregates must repeat the aggregate name to access its containing fields:
     1063However, routines manipulating aggregates have repeition of the aggregate name to access its containing fields:
    10651064\begin{cfa}
    10661065void f( S s ) {
    1067         `s.`c; `s.`i; `s.`d;                                    $\C{// access containing fields}$
     1066        `s.`c; `s.`i; `s.`d;                            $\C{// access containing fields}$
    10681067}
    10691068\end{cfa}
     
    10711070\begin{C++}
    10721071class C {
    1073         char c;                                                                 $\C{// fields}$
     1072        char c;                                                         $\C{// fields}$
    10741073        int i;
    10751074        double d;
    1076         int mem() {                                                             $\C{// implicit "this" parameter}$
    1077                 `this->`c; `this->`i; `this->`d;        $\C{// access containing fields}$
     1075        int mem() {                                                     $\C{// implicit "this" parameter}$
     1076                `this->`c; `this->`i; `this->`d;$\C{// access containing fields}$
    10781077        }
    10791078}
    10801079\end{C++}
    1081 Nesting of member routines in a \lstinline[language=C++]@class@ allows eliding \lstinline[language=C++]@this->@ because of lexical scoping.
    1082 However, for other aggregate parameters, qualification is necessary:
    1083 \begin{cfa}
    1084 struct T { double m, n; };
    1085 int C::mem( T & t ) {                                           $\C{// multiple aggregate parameters}$
    1086         c; i; d;                                                                $\C{\color{red}// this-\textgreater.c, this-\textgreater.i, this-\textgreater.d}$
    1087         `t.`m; `t.`n;                                                   $\C{// must qualify}$
    1088 }
    1089 \end{cfa}
     1080Nesting of member routines in a \lstinline[language=C++]@class@ allows eliding \lstinline[language=C++]@this->@ because of nested lexical-scoping.
    10901081
    10911082% In object-oriented programming, there is an implicit first parameter, often names @self@ or @this@, which is elided.
     
    10971088% \TODO{Fill out section. Be sure to mention arbitrary expressions in with-blocks, recent change driven by Thierry to prioritize field name over parameters.}
    10981089
    1099 To simplify the programmer experience, \CFA provides a @with@ clause/statement (see Pascal~\cite[\S~4.F]{Pascal}) to elide aggregate qualification to fields by opening a scope containing the field identifiers.
    1100 Hence, the qualified fields become variables with the side-effect that it is easier to optimizing field references in a block.
     1090\CFA provides a @with@ clause/statement (see Pascal~\cite[\S~4.F]{Pascal}) to elide aggregate qualification to fields by opening a scope containing field identifiers.
     1091Hence, the qualified fields become variables, and making it easier to optimize field references in a block.
    11011092\begin{cfa}
    1102 void f( S s ) `with( s )` {                                     $\C{// with clause}$
    1103         c; i; d;                                                                $\C{\color{red}// s.c, s.i, s.d}$
     1093void f( S s ) `with( s )` {                             $\C{// with clause}$
     1094        c; i; d;                                                        $\C{\color{red}// s.c, s.i, s.d}$
    11041095}
    11051096\end{cfa}
     
    11071098\begin{cfa}
    11081099int mem( S & this ) `with( this )` {            $\C{// with clause}$
    1109         c; i; d;                                                                $\C{\color{red}// this.c, this.i, this.d}$
     1100        c; i; d;                                                        $\C{\color{red}// this.c, this.i, this.d}$
    11101101}
    11111102\end{cfa}
    1112 with the generality of opening multiple aggregate-parameters:
     1103The key generality over the object-oriented approach is that one aggregate parameter \lstinline[language=C++]@this@ is not treated specially over other aggregate parameters:
    11131104\begin{cfa}
     1105struct T { double m, n; };
    11141106int mem( S & s, T & t ) `with( s, t )` {        $\C{// multiple aggregate parameters}$
    1115         c; i; d;                                                                $\C{\color{red}// s.c, s.i, s.d}$
    1116         m; n;                                                                   $\C{\color{red}// t.m, t.n}$
     1107        c; i; d;                                                        $\C{\color{red}// s.c, s.i, s.d}$
     1108        m; n;                                                           $\C{\color{red}// t.m, t.n}$
    11171109}
    11181110\end{cfa}
    1119 
    1120 In detail, the @with@ clause/statement has the form:
     1111The equivalent object-oriented style is:
    11211112\begin{cfa}
    1122 $\emph{with-statement}$:
    1123         'with' '(' $\emph{expression-list}$ ')' $\emph{compound-statement}$
    1124 \end{cfa}
    1125 and may appear as the body of a routine or nested within a routine body.
    1126 Each expression in the expression-list provides a type and object.
    1127 The type must be an aggregate type.
    1128 (Enumerations are already opened.)
    1129 The object is the implicit qualifier for the open structure-fields.
    1130 
    1131 All expressions in the expression list are open in ``parallel'' within the compound statement.
    1132 This semantic is different from Pascal, which nests the openings.
    1133 The difference between parallel and nesting occurs for fields with the same name but different type:
    1134 \begin{cfa}
    1135 struct S { int i; int j; double m; } s, w;
    1136 struct T { int i; int k; int m } t, w;
    1137 with( s, t ) {
    1138         j + k;                                                                  $\C{// unambiguous, s.j + t.m}$
    1139         m = 5.0;                                                                $\C{// unambiguous, t.m = 5.0}$
    1140         m = 1;                                                                  $\C{// unambiguous, s.m = 1}$
    1141         int a = s.i + m;                                                $\C{// unambiguous, a = s.i + t.i}$
    1142         int b = s.i + t.i;                                              $\C{// unambiguous, qualification}$
    1143         sout | (double)m | endl;                                $\C{// unambiguous, cast}$
    1144         i;                                                                              $\C{// ambiguous}$
    1145 }
    1146 \end{cfa}
    1147 \CFA's ability to overload variables means usages of field with the same names can be automatically disambiguated, eliminating most qualification.
    1148 Qualification or a cast is used to disambiguate.
    1149 A cast may be necessary to disambiguate between the overload variables in a @with@ expression:
    1150 \begin{cfa}
    1151 with( w ) { ... }                                                       $\C{// ambiguous, same name and no context}$
    1152 with( (S)w ) { ... }                                            $\C{// unambiguous}$
    1153 \end{cfa}
    1154 
    1155 \begin{cfa}
    1156 struct S { int i, j; } sv;
    1157 with( sv ) {
    1158         S & sr = sv;
    1159         with( sr ) {
    1160                 S * sp = &sv;
    1161                 with( *sp ) {
    1162                         i = 3; j = 4;                                   $\C{\color{red}// sp-{\textgreater}i, sp-{\textgreater}j}$
    1163                 }
    1164                 i = 3; j = 4;                                           $\C{\color{red}// sr.i, sr.j}$
    1165         }
    1166         i = 3; j = 4;                                                   $\C{\color{red}// sv.i, sv.j}$
     1113int S::mem( T & t ) {                                   $\C{// multiple aggregate parameters}$
     1114        c; i; d;                                                        $\C{\color{red}// this-\textgreater.c, this-\textgreater.i, this-\textgreater.d}$
     1115        `t.`m; `t.`n;
    11671116}
    11681117\end{cfa}
     
    11731122        struct S1 { ... } s1;
    11741123        struct S2 { ... } s2;
    1175         `with( s1 )` {                                                  $\C{// with statement}$
     1124        `with( s1 )` {                                          $\C{// with statement}$
    11761125                // access fields of s1 without qualification
    1177                 `with( s2 )` {                                          $\C{// nesting}$
     1126                `with( s2 )` {                                  $\C{// nesting}$
    11781127                        // access fields of s1 and s2 without qualification
    11791128                }
     
    11851134\end{cfa}
    11861135
     1136When opening multiple structures, fields with the same name and type are ambiguous and must be fully qualified.
     1137For fields with the same name but different type, context/cast can be used to disambiguate.
     1138\begin{cfa}
     1139struct S { int i; int j; double m; } a, c;
     1140struct T { int i; int k; int m } b, c;
     1141`with( a, b )` {
     1142        j + k;                                                  $\C{// unambiguous, unique names define unique types}$
     1143        i;                                                              $\C{// ambiguous, same name and type}$
     1144        a.i + b.i;                                              $\C{// unambiguous, qualification defines unique names}$
     1145        m;                                                              $\C{// ambiguous, same name and no context to define unique type}$
     1146        m = 5.0;                                                $\C{// unambiguous, same name and context defines unique type}$
     1147        m = 1;                                                  $\C{// unambiguous, same name and context defines unique type}$
     1148}
     1149`with( c )` { ... }                                     $\C{// ambiguous, same name and no context}$
     1150`with( (S)c )` { ... }                                  $\C{// unambiguous, same name and cast defines unique type}$
     1151\end{cfa}
     1152
     1153The components in the "with" clause
     1154
     1155  with ( a, b, c ) { ... }
     1156
     1157serve 2 purposes: each component provides a type and object. The type must be a
     1158structure type. Enumerations are already opened, and I think a union is opened
     1159to some extent, too. (Or is that just unnamed unions?) The object is the target
     1160that the naked structure-fields apply to. The components are open in "parallel"
     1161at the scope of the "with" clause/statement, so opening "a" does not affect
     1162opening "b", etc. This semantic is different from Pascal, which nests the
     1163openings.
     1164
     1165Having said the above, it seems reasonable to allow a "with" component to be an
     1166expression. The type is the static expression-type and the object is the result
     1167of the expression. Again, the type must be an aggregate. Expressions require
     1168parenthesis around the components.
     1169
     1170  with( a, b, c ) { ... }
     1171
     1172Does this now make sense?
     1173
     1174Having written more CFA code, it is becoming clear to me that I *really* want
     1175the "with" to be implemented because I hate having to type all those object
     1176names for fields. It's a great way to drive people away from the language.
     1177
    11871178
    11881179\subsection{Exception Handling ???}
     
    11981189
    11991190\subsection{Alternative Declaration Syntax}
    1200 
    1201 \newcommand{\R}[1]{\Textbf{#1}}
    1202 \newcommand{\B}[1]{{\Textbf[blue]{#1}}}
    1203 \newcommand{\G}[1]{{\Textbf[OliveGreen]{#1}}}
    1204 
    1205 C declaration syntax is notoriously confusing and error prone.
    1206 For example, many C programmers are confused by a declaration as simple as:
    1207 \begin{flushleft}
    1208 \lstDeleteShortInline@%
    1209 \begin{tabular}{@{}ll@{}}
    1210 \begin{cfa}
    1211 int * x[5]
    1212 \end{cfa}
    1213 &
    1214 \raisebox{-0.75\totalheight}{\input{Cdecl}}
    1215 \end{tabular}
    1216 \lstMakeShortInline@%
    1217 \end{flushleft}
    1218 Is this an array of 5 pointers to integers or a pointer to an array of 5 integers?
    1219 The fact this declaration is unclear to many C programmers means there are productivity and safety issues even for basic programs.
    1220 Another example of confusion results from the fact that a routine name and its parameters are embedded within the return type, mimicking the way the return value is used at the routine's call site.
    1221 For example, a routine returning a pointer to an array of integers is defined and used in the following way:
    1222 \begin{cfa}
    1223 int `(*`f`())[`5`]` {...};                              $\C{// definition}$
    1224  ... `(*`f`())[`3`]` += 1;                              $\C{// usage}$
    1225 \end{cfa}
    1226 Essentially, the return type is wrapped around the routine name in successive layers (like an onion).
    1227 While attempting to make the two contexts consistent is a laudable goal, it has not worked out in practice.
    1228 
    1229 \CFA provides its own type, variable and routine declarations, using a different syntax.
    1230 The new declarations place qualifiers to the left of the base type, while C declarations place qualifiers to the right of the base type.
    1231 In the following example, \R{red} is the base type and \B{blue} is qualifiers.
    1232 The \CFA declarations move the qualifiers to the left of the base type, \ie move the blue to the left of the red, while the qualifiers have the same meaning but are ordered left to right to specify a variable's type.
    1233 \begin{quote}
    1234 \lstDeleteShortInline@%
    1235 \lstset{moredelim=**[is][\color{blue}]{+}{+}}
    1236 \begin{tabular}{@{}l@{\hspace{3em}}l@{}}
    1237 \multicolumn{1}{c@{\hspace{3em}}}{\textbf{\CFA}}        & \multicolumn{1}{c}{\textbf{C}}        \\
    1238 \begin{cfa}
    1239 +[5] *+ `int` x1;
    1240 +* [5]+ `int` x2;
    1241 +[* [5] int]+ f`( int p )`;
    1242 \end{cfa}
    1243 &
    1244 \begin{cfa}
    1245 `int` +*+ x1 +[5]+;
    1246 `int` +(*+x2+)[5]+;
    1247 +int (*+f`( int p )`+)[5]+;
    1248 \end{cfa}
    1249 \end{tabular}
    1250 \lstMakeShortInline@%
    1251 \end{quote}
    1252 The only exception is bit field specification, which always appear to the right of the base type.
    1253 % Specifically, the character ©*© is used to indicate a pointer, square brackets ©[©\,©]© are used to represent an array or function return value, and parentheses ©()© are used to indicate a routine parameter.
    1254 However, unlike C, \CFA type declaration tokens are distributed across all variables in the declaration list.
    1255 For instance, variables ©x© and ©y© of type pointer to integer are defined in \CFA as follows:
    1256 \begin{quote}
    1257 \lstDeleteShortInline@%
    1258 \begin{tabular}{@{}l@{\hspace{3em}}l@{}}
    1259 \multicolumn{1}{c@{\hspace{3em}}}{\textbf{\CFA}}        & \multicolumn{1}{c}{\textbf{C}}        \\
    1260 \begin{cfa}
    1261 `*` int x, y;
    1262 \end{cfa}
    1263 &
    1264 \begin{cfa}
    1265 int `*`x, `*`y;
    1266 \end{cfa}
    1267 \end{tabular}
    1268 \lstMakeShortInline@%
    1269 \end{quote}
    1270 The downside of this semantics is the need to separate regular and pointer declarations:
    1271 \begin{quote}
    1272 \lstDeleteShortInline@%
    1273 \begin{tabular}{@{}l@{\hspace{3em}}l@{}}
    1274 \multicolumn{1}{c@{\hspace{3em}}}{\textbf{\CFA}}        & \multicolumn{1}{c}{\textbf{C}}        \\
    1275 \begin{cfa}
    1276 `*` int x;
    1277 int y;
    1278 \end{cfa}
    1279 &
    1280 \begin{cfa}
    1281 int `*`x, y;
    1282 
    1283 \end{cfa}
    1284 \end{tabular}
    1285 \lstMakeShortInline@%
    1286 \end{quote}
    1287 which is prescribing a safety benefit.
    1288 Other examples are:
    1289 \begin{quote}
    1290 \lstDeleteShortInline@%
    1291 \begin{tabular}{@{}l@{\hspace{3em}}l@{\hspace{2em}}l@{}}
    1292 \multicolumn{1}{c@{\hspace{3em}}}{\textbf{\CFA}}        & \multicolumn{1}{c@{\hspace{2em}}}{\textbf{C}} \\
    1293 \begin{cfa}
    1294 [ 5 ] int z;
    1295 [ 5 ] * char w;
    1296 * [ 5 ] double v;
    1297 struct s {
    1298         int f0:3;
    1299         * int f1;
    1300         [ 5 ] * int f2;
    1301 };
    1302 \end{cfa}
    1303 &
    1304 \begin{cfa}
    1305 int z[ 5 ];
    1306 char * w[ 5 ];
    1307 double (* v)[ 5 ];
    1308 struct s {
    1309         int f0:3;
    1310         int * f1;
    1311         int * f2[ 5 ]
    1312 };
    1313 \end{cfa}
    1314 &
    1315 \begin{cfa}
    1316 // array of 5 integers
    1317 // array of 5 pointers to char
    1318 // pointer to array of 5 doubles
    1319 
    1320 // common bit field syntax
    1321 
    1322 
    1323 
    1324 \end{cfa}
    1325 \end{tabular}
    1326 \lstMakeShortInline@%
    1327 \end{quote}
    1328 
    1329 All type qualifiers, \eg ©const©, ©volatile©, etc., are used in the normal way with the new declarations and also appear left to right, \eg:
    1330 \begin{quote}
    1331 \lstDeleteShortInline@%
    1332 \begin{tabular}{@{}l@{\hspace{1em}}l@{\hspace{1em}}l@{}}
    1333 \multicolumn{1}{c@{\hspace{1em}}}{\textbf{\CFA}}        & \multicolumn{1}{c@{\hspace{1em}}}{\textbf{C}} \\
    1334 \begin{cfa}
    1335 const * const int x;
    1336 const * [ 5 ] const int y;
    1337 \end{cfa}
    1338 &
    1339 \begin{cfa}
    1340 int const * const x;
    1341 const int (* const y)[ 5 ]
    1342 \end{cfa}
    1343 &
    1344 \begin{cfa}
    1345 // const pointer to const integer
    1346 // const pointer to array of 5 const integers
    1347 \end{cfa}
    1348 \end{tabular}
    1349 \lstMakeShortInline@%
    1350 \end{quote}
    1351 All declaration qualifiers, \eg ©extern©, ©static©, etc., are used in the normal way with the new declarations but can only appear at the start of a \CFA routine declaration,\footnote{\label{StorageClassSpecifier}
    1352 The placement of a storage-class specifier other than at the beginning of the declaration specifiers in a declaration is an obsolescent feature.~\cite[\S~6.11.5(1)]{C11}} \eg:
    1353 \begin{quote}
    1354 \lstDeleteShortInline@%
    1355 \begin{tabular}{@{}l@{\hspace{3em}}l@{\hspace{2em}}l@{}}
    1356 \multicolumn{1}{c@{\hspace{3em}}}{\textbf{\CFA}}        & \multicolumn{1}{c@{\hspace{2em}}}{\textbf{C}} \\
    1357 \begin{cfa}
    1358 extern [ 5 ] int x;
    1359 static * const int y;
    1360 \end{cfa}
    1361 &
    1362 \begin{cfa}
    1363 int extern x[ 5 ];
    1364 const int static * y;
    1365 \end{cfa}
    1366 &
    1367 \begin{cfa}
    1368 // externally visible array of 5 integers
    1369 // internally visible pointer to constant int
    1370 \end{cfa}
    1371 \end{tabular}
    1372 \lstMakeShortInline@%
    1373 \end{quote}
    1374 
    1375 The new declaration syntax can be used in other contexts where types are required, \eg casts and the pseudo-routine ©sizeof©:
    1376 \begin{quote}
    1377 \lstDeleteShortInline@%
    1378 \begin{tabular}{@{}l@{\hspace{3em}}l@{}}
    1379 \multicolumn{1}{c@{\hspace{3em}}}{\textbf{\CFA}}        & \multicolumn{1}{c}{\textbf{C}}        \\
    1380 \begin{cfa}
    1381 y = (`* int`)x;
    1382 i = sizeof(`[ 5 ] * int`);
    1383 \end{cfa}
    1384 &
    1385 \begin{cfa}
    1386 y = (`int *`)x;
    1387 i = sizeof(`int * [ 5 ]`);
    1388 \end{cfa}
    1389 \end{tabular}
    1390 \lstMakeShortInline@%
    1391 \end{quote}
    1392 
    1393 Finally, new \CFA declarations may appear together with C declarations in the same program block, but cannot be mixed within a specific declaration.
    1394 Therefore, a programmer has the option of either continuing to use traditional C declarations or take advantage of the new style.
    1395 Clearly, both styles need to be supported for some time due to existing C-style header-files, particularly for UNIX systems.
    13961191
    13971192
  • src/libcfa/bits/debug.c

    r41fcd94 reb7f20c  
    1111// Last Modified By :
    1212// Last Modified On :
    13 // Update Count     : 1
     13// Update Count     : 0
    1414//
    1515
     
    4747        void __cfaabi_dbg_bits_release() __attribute__((__weak__)) {}
    4848
    49         void __cfaabi_dbg_bits_print_safe  ( const char fmt[], ... ) __attribute__(( format(printf, 1, 2) )) {
     49        void __cfaabi_dbg_bits_print_safe  ( const char fmt[], ... ) __attribute__(( format (printf, 1, 2) )) {
    5050                va_list args;
    5151
     
    6060        }
    6161
    62         void __cfaabi_dbg_bits_print_nolock( const char fmt[], ... ) __attribute__(( format(printf, 1, 2) )) {
     62        void __cfaabi_dbg_bits_print_nolock( const char fmt[], ... ) __attribute__(( format (printf, 1, 2) )) {
    6363                va_list args;
    6464
     
    7676        }
    7777
    78         void __cfaabi_dbg_bits_print_buffer( char in_buffer[], int in_buffer_size, const char fmt[], ... ) __attribute__(( format(printf, 3, 4) )) {
     78        void __cfaabi_dbg_bits_print_buffer( char in_buffer[], int in_buffer_size, const char fmt[], ... ) __attribute__(( format (printf, 3, 4) )) {
    7979                va_list args;
    8080
  • src/libcfa/bits/debug.h

    r41fcd94 reb7f20c  
    1010// Created On       : Mon Nov 28 12:27:26 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 12:35:19 2018
    13 // Update Count     : 2
     12// Last Modified On : Sat Jul 22 10:02:24 2017
     13// Update Count     : 1
    1414//
    1515
     
    4141      extern void __cfaabi_dbg_bits_acquire();
    4242      extern void __cfaabi_dbg_bits_release();
    43       extern void __cfaabi_dbg_bits_print_safe  ( const char fmt[], ... ) __attribute__(( format(printf, 1, 2) ));
    44       extern void __cfaabi_dbg_bits_print_nolock( const char fmt[], ... ) __attribute__(( format(printf, 1, 2) ));
     43      extern void __cfaabi_dbg_bits_print_safe  ( const char fmt[], ... ) __attribute__(( format (printf, 1, 2) ));
     44      extern void __cfaabi_dbg_bits_print_nolock( const char fmt[], ... ) __attribute__(( format (printf, 1, 2) ));
    4545      extern void __cfaabi_dbg_bits_print_vararg( const char fmt[], va_list arg );
    46       extern void __cfaabi_dbg_bits_print_buffer( char buffer[], int buffer_size, const char fmt[], ... ) __attribute__(( format(printf, 3, 4) ));
     46      extern void __cfaabi_dbg_bits_print_buffer( char buffer[], int buffer_size, const char fmt[], ... ) __attribute__(( format (printf, 3, 4) ));
    4747#ifdef __cforall
    4848}
  • src/libcfa/bits/defs.h

    r41fcd94 reb7f20c  
    1010// Created On       : Thu Nov  9 13:24:10 2017
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 16:22:41 2018
    13 // Update Count     : 8
     12// Last Modified On : Tue Jan  2 09:17:06 2018
     13// Update Count     : 2
    1414//
    1515
     
    3434
    3535#ifdef __cforall
    36 void abort ( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ ));
     36#ifndef __NO_ABORT_OVERLOAD
     37void abort ( const char fmt[], ... ) __attribute__ ((__nothrow__, __leaf__, __noreturn__));
     38#endif
    3739extern "C" {
    3840#endif
    39 void __cabi_abort( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ ));
     41void abortf( const char fmt[], ... ) __attribute__ ((__nothrow__, __leaf__, __noreturn__));
    4042#ifdef __cforall
    4143}
  • src/libcfa/concurrency/coroutine.c

    r41fcd94 reb7f20c  
    1010// Created On       : Mon Nov 28 12:27:26 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 16:10:31 2018
    13 // Update Count     : 4
     12// Last Modified On : Fri Jul 21 22:34:57 2017
     13// Update Count     : 1
    1414//
    1515
     
    7777                __cfaabi_dbg_debug_do(
    7878                        if ( mprotect( this.storage, pageSize, PROT_READ | PROT_WRITE ) == -1 ) {
    79                                 abort( "(coStack_t *)%p.^?{}() : internal error, mprotect failure, error(%d) %s.", &this, errno, strerror( errno ) );
     79                                abortf( "(coStack_t *)%p.^?{}() : internal error, mprotect failure, error(%d) %s.", &this, errno, strerror( errno ) );
    8080                        }
    8181                );
     
    135135                __cfaabi_dbg_debug_do(
    136136                        if ( mprotect( storage, pageSize, PROT_NONE ) == -1 ) {
    137                                 abort( "(uMachContext &)%p.createContext() : internal error, mprotect failure, error(%d) %s.", this, (int)errno, strerror( (int)errno ) );
     137                                abortf( "(uMachContext &)%p.createContext() : internal error, mprotect failure, error(%d) %s.", this, (int)errno, strerror( (int)errno ) );
    138138                        } // if
    139139                );
    140140
    141141                if ( (intptr_t)storage == 0 ) {
    142                         abort( "Attempt to allocate %zd bytes of storage for coroutine or task execution-state but insufficient memory available.", size );
     142                        abortf( "Attempt to allocate %d bytes of storage for coroutine or task execution-state but insufficient memory available.", size );
    143143                } // if
    144144
  • src/libcfa/concurrency/invoke.c

    r41fcd94 reb7f20c  
    1010// Created On       : Tue Jan 17 12:27:26 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 16:18:11 2018
    13 // Update Count     : 4
     12// Last Modified On : Tue Feb  6 23:00:57 2018
     13// Update Count     : 3
    1414//
    1515
     
    5151        //Final suspend, should never return
    5252        __leave_coroutine();
    53         __cabi_abort( "Resumed dead coroutine" );
     53        abortf( "Resumed dead coroutine" );
    5454}
    5555
     
    8181        //Final suspend, should never return
    8282        __leave_thread_monitor( thrd );
    83         __cabi_abort( "Resumed dead thread" );
     83        abortf( "Resumed dead thread" );
    8484}
    8585
  • src/libcfa/concurrency/monitor.c

    r41fcd94 reb7f20c  
    1010// Created On       : Thd Feb 23 12:27:26 2017
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 16:12:20 2018
    13 // Update Count     : 4
     12// Last Modified On : Mon Jul 31 14:59:05 2017
     13// Update Count     : 3
    1414//
    1515
     
    8787                thread_desc * thrd = this_thread;
    8888
    89                 __cfaabi_dbg_print_safe( "Kernel : %10p Entering mon %p (%p)\n", thrd, this, this->owner);
     89                __cfaabi_dbg_print_safe("Kernel : %10p Entering mon %p (%p)\n", thrd, this, this->owner);
    9090
    9191                if( !this->owner ) {
     
    9393                        set_owner( this, thrd );
    9494
    95                         __cfaabi_dbg_print_safe( "Kernel :  mon is free \n" );
     95                        __cfaabi_dbg_print_safe("Kernel :  mon is free \n");
    9696                }
    9797                else if( this->owner == thrd) {
     
    9999                        this->recursion += 1;
    100100
    101                         __cfaabi_dbg_print_safe( "Kernel :  mon already owned \n" );
     101                        __cfaabi_dbg_print_safe("Kernel :  mon already owned \n");
    102102                }
    103103                else if( is_accepted( this, group) ) {
     
    108108                        reset_mask( this );
    109109
    110                         __cfaabi_dbg_print_safe( "Kernel :  mon accepts \n" );
     110                        __cfaabi_dbg_print_safe("Kernel :  mon accepts \n");
    111111                }
    112112                else {
    113                         __cfaabi_dbg_print_safe( "Kernel :  blocking \n" );
     113                        __cfaabi_dbg_print_safe("Kernel :  blocking \n");
    114114
    115115                        // Some one else has the monitor, wait in line for it
     
    118118                        BlockInternal( &this->lock );
    119119
    120                         __cfaabi_dbg_print_safe( "Kernel : %10p Entered  mon %p\n", thrd, this);
     120                        __cfaabi_dbg_print_safe("Kernel : %10p Entered  mon %p\n", thrd, this);
    121121
    122122                        // BlockInternal will unlock spinlock, no need to unlock ourselves
     
    124124                }
    125125
    126                 __cfaabi_dbg_print_safe( "Kernel : %10p Entered  mon %p\n", thrd, this);
     126                __cfaabi_dbg_print_safe("Kernel : %10p Entered  mon %p\n", thrd, this);
    127127
    128128                // Release the lock and leave
     
    136136                thread_desc * thrd = this_thread;
    137137
    138                 __cfaabi_dbg_print_safe( "Kernel : %10p Entering dtor for mon %p (%p)\n", thrd, this, this->owner);
     138                __cfaabi_dbg_print_safe("Kernel : %10p Entering dtor for mon %p (%p)\n", thrd, this, this->owner);
    139139
    140140
    141141                if( !this->owner ) {
    142                         __cfaabi_dbg_print_safe( "Kernel : Destroying free mon %p\n", this);
     142                        __cfaabi_dbg_print_safe("Kernel : Destroying free mon %p\n", this);
    143143
    144144                        // No one has the monitor, just take it
     
    151151                        // We already have the monitor... but where about to destroy it so the nesting will fail
    152152                        // Abort!
    153                         abort( "Attempt to destroy monitor %p by thread \"%.256s\" (%p) in nested mutex." );
     153                        abortf("Attempt to destroy monitor %p by thread \"%.256s\" (%p) in nested mutex.");
    154154                }
    155155
     
    158158                __monitor_group_t group = { &this, 1, func };
    159159                if( is_accepted( this, group) ) {
    160                         __cfaabi_dbg_print_safe( "Kernel :  mon accepts dtor, block and signal it \n" );
     160                        __cfaabi_dbg_print_safe("Kernel :  mon accepts dtor, block and signal it \n");
    161161
    162162                        // Wake the thread that is waiting for this
     
    177177                }
    178178                else {
    179                         __cfaabi_dbg_print_safe( "Kernel :  blocking \n" );
     179                        __cfaabi_dbg_print_safe("Kernel :  blocking \n");
    180180
    181181                        wait_ctx( this_thread, 0 )
     
    190190                }
    191191
    192                 __cfaabi_dbg_print_safe( "Kernel : Destroying %p\n", this);
     192                __cfaabi_dbg_print_safe("Kernel : Destroying %p\n", this);
    193193
    194194        }
     
    199199                lock( this->lock __cfaabi_dbg_ctx2 );
    200200
    201                 __cfaabi_dbg_print_safe( "Kernel : %10p Leaving mon %p (%p)\n", this_thread, this, this->owner);
     201                __cfaabi_dbg_print_safe("Kernel : %10p Leaving mon %p (%p)\n", this_thread, this, this->owner);
    202202
    203203                verifyf( this_thread == this->owner, "Expected owner to be %p, got %p (r: %i, m: %p)", this_thread, this->owner, this->recursion, this );
     
    209209                // it means we don't need to do anything
    210210                if( this->recursion != 0) {
    211                         __cfaabi_dbg_print_safe( "Kernel :  recursion still %d\n", this->recursion);
     211                        __cfaabi_dbg_print_safe("Kernel :  recursion still %d\n", this->recursion);
    212212                        unlock( this->lock );
    213213                        return;
     
    228228                __cfaabi_dbg_debug_do(
    229229                        if( this_thread != this->owner ) {
    230                                 abort( "Destroyed monitor %p has inconsistent owner, expected %p got %p.\n", this, this_thread, this->owner);
     230                                abortf("Destroyed monitor %p has inconsistent owner, expected %p got %p.\n", this, this_thread, this->owner);
    231231                        }
    232232                        if( this->recursion != 1 ) {
    233                                 abort( "Destroyed monitor %p has %d outstanding nested calls.\n", this, this->recursion - 1);
     233                                abortf("Destroyed monitor %p has %d outstanding nested calls.\n", this, this->recursion - 1);
    234234                        }
    235235                )
     
    256256                // If we haven't left the last level of recursion
    257257                // it must mean there is an error
    258                 if( this->recursion != 0) { abort( "Thread internal monitor has unbalanced recursion" ); }
     258                if( this->recursion != 0) { abortf("Thread internal monitor has unbalanced recursion"); }
    259259
    260260                // Fetch the next thread, can be null
     
    302302        (this_thread->monitors){m, count, func};
    303303
    304         // __cfaabi_dbg_print_safe( "MGUARD : enter %d\n", count);
     304        // __cfaabi_dbg_print_safe("MGUARD : enter %d\n", count);
    305305
    306306        // Enter the monitors in order
     
    308308        enter( group );
    309309
    310         // __cfaabi_dbg_print_safe( "MGUARD : entered\n" );
     310        // __cfaabi_dbg_print_safe("MGUARD : entered\n");
    311311}
    312312
     
    314314// Dtor for monitor guard
    315315void ^?{}( monitor_guard_t & this ) {
    316         // __cfaabi_dbg_print_safe( "MGUARD : leaving %d\n", this.count);
     316        // __cfaabi_dbg_print_safe("MGUARD : leaving %d\n", this.count);
    317317
    318318        // Leave the monitors in order
    319319        leave( this.m, this.count );
    320320
    321         // __cfaabi_dbg_print_safe( "MGUARD : left\n" );
     321        // __cfaabi_dbg_print_safe("MGUARD : left\n");
    322322
    323323        // Restore thread context
     
    427427                thread_desc * this_thrd = this_thread;
    428428                if ( this.monitor_count != this_thrd->monitors.size ) {
    429                         abort( "Signal on condition %p made with different number of monitor(s), expected %i got %i", &this, this.monitor_count, this_thrd->monitors.size );
     429                        abortf( "Signal on condition %p made with different number of monitor(s), expected %i got %i", &this, this.monitor_count, this_thrd->monitors.size );
    430430                }
    431431
    432432                for(int i = 0; i < this.monitor_count; i++) {
    433433                        if ( this.monitors[i] != this_thrd->monitors[i] ) {
    434                                 abort( "Signal on condition %p made with different monitor, expected %p got %i", &this, this.monitors[i], this_thrd->monitors[i] );
     434                                abortf( "Signal on condition %p made with different monitor, expected %p got %i", &this, this.monitors[i], this_thrd->monitors[i] );
    435435                        }
    436436                }
     
    534534        if(actual_count == 0) return;
    535535
    536         __cfaabi_dbg_print_buffer_local( "Kernel : waitfor internal proceeding\n" );
     536        __cfaabi_dbg_print_buffer_local( "Kernel : waitfor internal proceeding\n");
    537537
    538538        // Create storage for monitor context
     
    551551                        __acceptable_t& accepted = mask[index];
    552552                        if( accepted.is_dtor ) {
    553                                 __cfaabi_dbg_print_buffer_local( "Kernel : dtor already there\n" );
     553                                __cfaabi_dbg_print_buffer_local( "Kernel : dtor already there\n");
    554554                                verifyf( accepted.size == 1,  "ERROR: Accepted dtor has more than 1 mutex parameter." );
    555555
     
    563563                        }
    564564                        else {
    565                                 __cfaabi_dbg_print_buffer_local( "Kernel : thread present, baton-passing\n" );
     565                                __cfaabi_dbg_print_buffer_local( "Kernel : thread present, baton-passing\n");
    566566
    567567                                // Create the node specific to this wait operation
     
    577577                                        }
    578578                                #endif
    579                                 __cfaabi_dbg_print_buffer_local( "\n" );
     579                                __cfaabi_dbg_print_buffer_local( "\n");
    580580
    581581                                // Set the owners to be the next thread
     
    588588                                monitor_restore;
    589589
    590                                 __cfaabi_dbg_print_buffer_local( "Kernel : thread present, returned\n" );
     590                                __cfaabi_dbg_print_buffer_local( "Kernel : thread present, returned\n");
    591591                        }
    592592
     
    598598
    599599        if( duration == 0 ) {
    600                 __cfaabi_dbg_print_buffer_local( "Kernel : non-blocking, exiting\n" );
     600                __cfaabi_dbg_print_buffer_local( "Kernel : non-blocking, exiting\n");
    601601
    602602                unlock_all( locks, count );
     
    607607
    608608
    609         verifyf( duration < 0, "Timeout on waitfor statments not supported yet." );
    610 
    611         __cfaabi_dbg_print_buffer_local( "Kernel : blocking waitfor\n" );
     609        verifyf( duration < 0, "Timeout on waitfor statments not supported yet.");
     610
     611        __cfaabi_dbg_print_buffer_local( "Kernel : blocking waitfor\n");
    612612
    613613        // Create the node specific to this wait operation
     
    631631        monitor_restore;
    632632
    633         __cfaabi_dbg_print_buffer_local( "Kernel : exiting\n" );
     633        __cfaabi_dbg_print_buffer_local( "Kernel : exiting\n");
    634634
    635635        __cfaabi_dbg_print_buffer_local( "Kernel : accepted %d\n", *mask.accepted);
     
    640640
    641641static inline void set_owner( monitor_desc * this, thread_desc * owner ) {
    642         // __cfaabi_dbg_print_safe( "Kernal :   Setting owner of %p to %p ( was %p)\n", this, owner, this->owner );
     642        // __cfaabi_dbg_print_safe("Kernal :   Setting owner of %p to %p ( was %p)\n", this, owner, this->owner );
    643643
    644644        //Pass the monitor appropriately
     
    672672static inline thread_desc * next_thread( monitor_desc * this ) {
    673673        //Check the signaller stack
    674         __cfaabi_dbg_print_safe( "Kernel :  mon %p AS-stack top %p\n", this, this->signal_stack.top);
     674        __cfaabi_dbg_print_safe("Kernel :  mon %p AS-stack top %p\n", this, this->signal_stack.top);
    675675        __condition_criterion_t * urgent = pop( this->signal_stack );
    676676        if( urgent ) {
     
    814814        thread_desc * thrd = this_thread;
    815815        if( !this.monitors ) {
    816                 // __cfaabi_dbg_print_safe( "Branding\n" );
     816                // __cfaabi_dbg_print_safe("Branding\n");
    817817                assertf( thrd->monitors.data != NULL, "No current monitor to brand condition %p", thrd->monitors.data );
    818818                this.monitor_count = thrd->monitors.size;
  • src/libcfa/concurrency/preemption.c

    r41fcd94 reb7f20c  
    1010// Created On       : Mon Jun 5 14:20:42 2017
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 16:12:58 2018
    13 // Update Count     : 12
     12// Last Modified On : Tue Feb  6 15:00:36 2018
     13// Update Count     : 10
    1414//
    1515
     
    197197
    198198        if ( pthread_sigmask( SIG_UNBLOCK, &mask, NULL ) == -1 ) {
    199             abort( "internal error, pthread_sigmask" );
     199            abortf( "internal error, pthread_sigmask" );
    200200        }
    201201}
     
    208208
    209209        if ( pthread_sigmask( SIG_BLOCK, &mask, NULL ) == -1 ) {
    210             abort( "internal error, pthread_sigmask" );
     210            abortf( "internal error, pthread_sigmask" );
    211211        }
    212212}
     
    247247// Called from kernel_startup
    248248void kernel_start_preemption() {
    249         __cfaabi_dbg_print_safe( "Kernel : Starting preemption\n" );
     249        __cfaabi_dbg_print_safe("Kernel : Starting preemption\n");
    250250
    251251        // Start with preemption disabled until ready
     
    268268// Called from kernel_shutdown
    269269void kernel_stop_preemption() {
    270         __cfaabi_dbg_print_safe( "Kernel : Preemption stopping\n" );
     270        __cfaabi_dbg_print_safe("Kernel : Preemption stopping\n");
    271271
    272272        // Block all signals since we are already shutting down
     
    284284        // Preemption is now fully stopped
    285285
    286         __cfaabi_dbg_print_safe( "Kernel : Preemption stopped\n" );
     286        __cfaabi_dbg_print_safe("Kernel : Preemption stopped\n");
    287287}
    288288
     
    328328        if( !preemption_ready() ) { return; }
    329329
    330         __cfaabi_dbg_print_buffer_decl( " KERNEL: preempting core %p (%p).\n", this_processor, this_thread);
     330        __cfaabi_dbg_print_buffer_decl(" KERNEL: preempting core %p (%p).\n", this_processor, this_thread);
    331331
    332332        preemption_in_progress = true;                      // Sync flag : prevent recursive calls to the signal handler
     
    348348
    349349        if ( pthread_sigmask( SIG_BLOCK, &mask, NULL ) == -1 ) {
    350             abort( "internal error, pthread_sigmask" );
     350            abortf( "internal error, pthread_sigmask" );
    351351        }
    352352
     
    365365                                        continue;
    366366                        case EINVAL :
    367                                         abort( "Timeout was invalid." );
     367                                        abortf("Timeout was invalid.");
    368368                                default:
    369                                         abort( "Unhandled error %d", err);
     369                                        abortf("Unhandled error %d", err);
    370370                        }
    371371                }
     
    374374                assertf(sig == SIGALRM, "Kernel Internal Error, sigwait: Unexpected signal %d (%d : %d)\n", sig, info.si_code, info.si_value.sival_int);
    375375
    376                 // __cfaabi_dbg_print_safe( "Kernel : Caught alarm from %d with %d\n", info.si_code, info.si_value.sival_int );
     376                // __cfaabi_dbg_print_safe("Kernel : Caught alarm from %d with %d\n", info.si_code, info.si_value.sival_int );
    377377                // Switch on the code (a.k.a. the sender) to
    378378                switch( info.si_code )
     
    382382                case SI_TIMER:
    383383                case SI_KERNEL:
    384                         // __cfaabi_dbg_print_safe( "Kernel : Preemption thread tick\n" );
     384                        // __cfaabi_dbg_print_safe("Kernel : Preemption thread tick\n");
    385385                        lock( event_kernel->lock __cfaabi_dbg_ctx2 );
    386386                        tick_preemption();
     
    396396
    397397EXIT:
    398         __cfaabi_dbg_print_safe( "Kernel : Preemption thread stopping\n" );
     398        __cfaabi_dbg_print_safe("Kernel : Preemption thread stopping\n");
    399399        return NULL;
    400400}
  • src/libcfa/interpose.c

    r41fcd94 reb7f20c  
    1010// Created On       : Wed Mar 29 16:10:31 2017
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 16:18:09 2018
    13 // Update Count     : 75
     12// Last Modified On : Wed Feb  7 09:05:18 2018
     13// Update Count     : 59
    1414//
    1515
     
    2828}
    2929
     30#define __NO_ABORT_OVERLOAD // no abort overload avoid ambiguities
    3031#include "bits/debug.h"
    3132#include "bits/defs.h"
     
    5051                        error = dlerror();
    5152                        if ( error ) {
    52                                 abort( "interpose_symbol : failed to open libc, %s\n", error );
     53                                abortf( "interpose_symbol : failed to open libc, %s\n", error );
    5354                        }
    5455                #endif
     
    6869
    6970        error = dlerror();
    70         if ( error ) abort( "interpose_symbol : internal error, %s\n", error );
     71        if ( error ) abortf( "interpose_symbol : internal error, %s\n", error );
    7172
    7273        return originalFunc.fptr;
     
    9798
    9899struct {
    99         void (* exit)( int ) __attribute__ (( __noreturn__ ));
    100         void (* abort)( void ) __attribute__ (( __noreturn__ ));
     100        __typeof__( exit  ) exit  __attribute__(( noreturn ));
     101        __typeof__( abort ) abort __attribute__(( noreturn ));
    101102} __cabi_libc;
    102103
     
    122123
    123124// Forward declare abort after the __typeof__ call to avoid ambiguities
    124 void exit( int status, const char fmt[], ... ) __attribute__ (( format(printf, 2, 3), __nothrow__, __leaf__, __noreturn__ ));
    125 void abort( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ ));
     125void abort ( const char fmt[], ... ) __attribute__ ((__nothrow__, __leaf__, __noreturn__));
    126126
    127127extern "C" {
    128         void abort( void ) __attribute__ (( __nothrow__, __leaf__, __noreturn__ )) {
    129                 abort( NULL );
    130         }
    131 
    132         void __cabi_abort( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ )) {
     128        void abort( void ) __attribute__ ((__nothrow__, __leaf__, __noreturn__)) {
     129                abortf( NULL );
     130        }
     131
     132        void abortf( const char fmt[], ... ) __attribute__ ((__nothrow__, __leaf__, __noreturn__)) {
    133133                va_list argp;
    134134                va_start( argp, fmt );
     
    137137        }
    138138
    139         void exit( int status ) __attribute__ (( __nothrow__, __leaf__, __noreturn__ )) {
    140                 __cabi_libc.exit( status );
    141         }
    142 }
    143 
    144 void * kernel_abort    ( void ) __attribute__ (( __nothrow__, __leaf__, __weak__ )) { return NULL; }
    145 void   kernel_abort_msg( void * data, char * buffer, int size ) __attribute__ (( __nothrow__, __leaf__, __weak__ )) {}
    146 int kernel_abort_lastframe( void ) __attribute__ (( __nothrow__, __leaf__, __weak__ )) { return 4; }
     139        void exit( int __status ) __attribute__ ((__nothrow__, __leaf__, __noreturn__)) {
     140                __cabi_libc.exit(__status);
     141        }
     142}
     143
     144void * kernel_abort    ( void ) __attribute__ ((__nothrow__, __leaf__, __weak__)) { return NULL; }
     145void   kernel_abort_msg( void * data, char * buffer, int size ) __attribute__ ((__nothrow__, __leaf__, __weak__)) {}
     146int kernel_abort_lastframe( void ) __attribute__ ((__nothrow__, __leaf__, __weak__)) { return 4; }
    147147
    148148enum { abort_text_size = 1024 };
     
    150150static int abort_lastframe;
    151151
    152 void exit( int status, const char fmt[], ... ) __attribute__ (( format(printf, 2, 3), __nothrow__, __leaf__, __noreturn__ )) {
    153     va_list args;
    154     va_start( args, fmt );
    155     vfprintf( stderr, fmt, args );
    156     va_end( args );
    157         __cabi_libc.exit( status );
    158 }
    159 
    160 void abort( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ )) {
     152void abort( const char fmt[], ... ) __attribute__ ((__nothrow__, __leaf__, __noreturn__)) {
    161153        void * kernel_data = kernel_abort();                    // must be done here to lock down kernel
    162154        int len;
     
    234226
    235227void sigHandler_segv( __CFA_SIGPARMS__ ) {
    236         abort( "Addressing invalid memory at location %p\n"
     228        abortf( "Addressing invalid memory at location %p\n"
    237229                        "Possible cause is reading outside the address space or writing to a protected area within the address space with an invalid pointer or subscript.\n",
    238230                        sfp->si_addr );
     
    240232
    241233void sigHandler_ill( __CFA_SIGPARMS__ ) {
    242         abort( "Executing illegal instruction at location %p.\n"
     234        abortf( "Executing illegal instruction at location %p.\n"
    243235                        "Possible cause is stack corruption.\n",
    244236                        sfp->si_addr );
     
    256248          default: msg = "unknown";
    257249        } // choose
    258         abort( "Computation error %s at location %p.\n", msg, sfp->si_addr );
     250        abortf( "Computation error %s at location %p.\n", msg, sfp->si_addr );
    259251}
    260252
  • src/prelude/builtins.c

    r41fcd94 reb7f20c  
    99// Author           : Peter A. Buhr
    1010// Created On       : Fri Jul 21 16:21:03 2017
    11 // Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb  8 12:47:59 2018
    13 // Update Count     : 19
     11// Last Modified By : Andrew Beach
     12// Last Modified On : Tus Jul 25 15:33:00 2017
     13// Update Count     : 14
    1414//
    1515
     
    2020#include "../libcfa/virtual.h"
    2121#include "../libcfa/exception.h"
    22 
    23 void exit( int status, const char fmt[], ... ) __attribute__ (( format(printf, 2, 3), __nothrow__, __leaf__, __noreturn__ ));
    24 void abort ( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ ));
    2522
    2623// exponentiation operator implementation
Note: See TracChangeset for help on using the changeset viewer.