- Timestamp:
- Jan 18, 2025, 3:46:06 PM (8 months ago)
- Branches:
- master
- Children:
- d0b6712
- Parents:
- fa59c40 (diff), df56e25 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - Location:
- doc
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/LaTeXmacros/lstlang.sty
rfa59c40 r8e90fd6 8 8 %% Created On : Sat May 13 16:34:42 2017 9 9 %% Last Modified By : Peter A. Buhr 10 %% Last Modified On : Wed Jul 24 07:40:11 202411 %% Update Count : 4 510 %% Last Modified On : Fri Jan 17 14:29:52 2025 11 %% Update Count : 46 12 12 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 13 13 … … 117 117 __auto_type, basetypeof, _Bool, bool, catch, catchResume, choose, coerce, cofor, corun, countof, _Complex, __complex, __complex__, 118 118 __const, __const__, continue, coroutine, _Decimal32, _Decimal64, _Decimal128, disable, dtype, enable, exception, __extension__, 119 fallthrough, f allthru, finally, fixup, __float80, float80, __float128, float128, _Float16, _Float32, _Float32x, _Float64,119 fallthrough, finally, fixup, __float80, float80, __float128, float128, _Float16, _Float32, _Float32x, _Float64, 120 120 _Float64x, _Float128, _Float128x, forall, fortran, ftype, generator, _Generic, _Imaginary, __imag, __imag__, inline, 121 121 __inline, __inline__, int128, __int128, __int128_t, __label__, monitor, mutex, _Noreturn, __builtin_offsetof, one_t, or, -
doc/papers/OOPSLA17/generic_types.tex
rfa59c40 r8e90fd6 66 66 morekeywords={_Alignas,_Alignof,__alignof,__alignof__,asm,__asm,__asm__,_At,_Atomic,__attribute,__attribute__,auto, 67 67 _Bool,catch,catchResume,choose,_Complex,__complex,__complex__,__const,__const__,disable,dtype,enable,__extension__, 68 fallthrough,f allthru,finally,forall,ftype,_Generic,_Imaginary,inline,__label__,lvalue,_Noreturn,one_t,otype,restrict,_Static_assert,68 fallthrough,finally,forall,ftype,_Generic,_Imaginary,inline,__label__,lvalue,_Noreturn,one_t,otype,restrict,_Static_assert, 69 69 _Thread_local,throw,throwResume,trait,try,ttype,typeof,__typeof,__typeof__,zero_t}, 70 70 }% -
doc/papers/concurrency/Paper.tex
rfa59c40 r8e90fd6 162 162 _Alignas, _Alignof, __alignof, __alignof__, asm, __asm, __asm__, __attribute, __attribute__, 163 163 auto, _Bool, catch, catchResume, choose, _Complex, __complex, __complex__, __const, __const__, 164 coroutine, disable, dtype, enable, exception, __extension__, fallthrough, f allthru, finally,164 coroutine, disable, dtype, enable, exception, __extension__, fallthrough, finally, 165 165 __float80, float80, __float128, float128, forall, ftype, generator, _Generic, _Imaginary, __imag, __imag__, 166 166 inline, __inline, __inline__, __int128, int128, __label__, monitor, mutex, _Noreturn, one_t, or, -
doc/papers/general/Paper.tex
rfa59c40 r8e90fd6 143 143 _Alignas, _Alignof, __alignof, __alignof__, asm, __asm, __asm__, __attribute, __attribute__, 144 144 auto, _Bool, catch, catchResume, choose, _Complex, __complex, __complex__, __const, __const__, 145 coroutine, disable, dtype, enable, exception, __extension__, fallthrough, f allthru, finally,145 coroutine, disable, dtype, enable, exception, __extension__, fallthrough, finally, 146 146 __float80, float80, __float128, float128, forall, ftype, _Generic, _Imaginary, __imag, __imag__, 147 147 inline, __inline, __inline__, __int128, int128, __label__, monitor, mutex, _Noreturn, one_t, or, -
doc/papers/llheap/Paper.tex
rfa59c40 r8e90fd6 108 108 _Alignas, _Alignof, __alignof, __alignof__, and, asm, __asm, __asm__, _Atomic, __attribute, __attribute__, 109 109 __auto_type, basetypeof, _Bool, catch, catchResume, choose, coerce, _Complex, __complex, __complex__, __const, __const__, 110 coroutine, _Decimal32, _Decimal64, _Decimal128, disable, enable, exception, __extension__, fallthrough, f allthru, finally, fixup,110 coroutine, _Decimal32, _Decimal64, _Decimal128, disable, enable, exception, __extension__, fallthrough, finally, fixup, 111 111 __float80, float80, __float128, float128, _Float16, _Float32, _Float32x, _Float64, _Float64x, _Float128, _Float128x, 112 112 forall, fortran, generator, _Generic, _Imaginary, __imag, __imag__, inline, __inline, __inline__, int128, __int128, __int128_t, -
doc/refrat/keywords.tex
rfa59c40 r8e90fd6 11 11 %% Created On : Sun Aug 6 08:17:27 2017 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Fri Apr 6 15:16:11 201814 %% Update Count : 713 %% Last Modified On : Fri Jan 17 14:45:13 2025 14 %% Update Count : 8 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 16 \begin{tabular}{@{}llllll@{}} … … 28 28 ©exception© \\ 29 29 ©fallthrough© \\ 30 ©fallthru© \\31 30 \end{tabular} 32 31 & -
doc/refrat/refrat.tex
rfa59c40 r8e90fd6 11 11 %% Created On : Wed Apr 6 14:52:25 2016 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Mon Oct 5 09:02:53 202014 %% Update Count : 11 013 %% Last Modified On : Fri Jan 17 14:45:04 2025 14 %% Update Count : 111 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 16 … … 3348 3348 3349 3349 The ©choose© statement is the same as the ©switch© statement except control transfers to the end of the ©choose© statement at a ©case© or ©default© labeled statement. 3350 The ©fallthr u© statement is used to fall through to the next ©case© or ©default© labeled statement.3350 The ©fallthrough© statement is used to fall through to the next ©case© or ©default© labeled statement. 3351 3351 The following have identical meaning: 3352 3352 \begin{flushleft} … … 3366 3366 case 1: ... ; // exit 3367 3367 case 2: ... ; // exit 3368 case 3: ... ; fallthr u;3369 case 4: ... ; fallthr u;3368 case 3: ... ; fallthrough; 3369 case 4: ... ; fallthrough; 3370 3370 default: ... ; // exit 3371 3371 } -
doc/theses/aaron_moss_PhD/phd/cfa-macros.tex
rfa59c40 r8e90fd6 27 27 _Alignas, _Alignof, __alignof, __alignof__, asm, __asm, __asm__, __attribute, __attribute__, 28 28 auto, bool, _Bool, catch, catchResume, choose, _Complex, __complex, __complex__, __const, __const__, 29 coroutine, disable, dtype, enable, exception, __extension__, fallthrough, f allthru, finally,29 coroutine, disable, dtype, enable, exception, __extension__, fallthrough, finally, 30 30 __float80, float80, __float128, float128, forall, ftype, _Generic, _Imaginary, __imag, __imag__, 31 31 inline, __inline, __inline__, __int128, int128, __label__, monitor, mutex, _Noreturn, one_t, or, -
doc/theses/andrew_beach_MMath/cfalab.sty
rfa59c40 r8e90fd6 76 76 choose, _Complex, __complex, __complex__, __const, __const__, 77 77 coroutine, disable, dtype, enable, exception, __extension__, 78 fallthrough, f allthru, finally, __float80, float80, __float128,78 fallthrough, finally, __float80, float80, __float128, 79 79 float128, forall, ftype, generator, _Generic, _Imaginary, __imag, 80 80 __imag__, inline, __inline, __inline__, __int128, int128, __label__, -
doc/theses/andrew_beach_MMath/features.tex
rfa59c40 r8e90fd6 822 822 control flow. 823 823 Because of this requirement, local control flow out of the finally block 824 is forbidden. The compiler precludes any @break@, @continue@, @fallthr u@ or824 is forbidden. The compiler precludes any @break@, @continue@, @fallthrough@ or 825 825 @return@ that causes control to leave the finally block. Other ways to leave 826 826 the finally block, such as a @longjmp@ or termination are much harder to check, -
doc/theses/fangren_yu_MMath/intro.tex
rfa59c40 r8e90fd6 518 518 519 519 \begin{enumerate} 520 \item 521 \item 522 \item 520 \item The \CFA compiler performance and capability have been greatly improved through recent development. The compilation time of various \CFA library units and test programs have been reduced from the order of minutes down to 10-20 seconds, which made it possible to develop and test more complicated \CFA programs that utilize sophisticated type system features. The details of compiler optimization work are covered in a previous technical report. 521 \item The thesis presents a systematic review of the new features that have been added to the \CFA language and its type system. Some of the more recent inclusions to \CFA such as tuples and generic structure types were not well tested when they were being developed, due to the limitation of compiler performance. Several issues coming from the interactions of various language features are identified and discussed in this thesis; some of them are now fully resolved, while others are given temporary fixes and need to be reworked in the future. 522 \item Finally, this thesis provides constructive ideas of fixing the outstanding issues in \CFA language design and implementation, and gives a path for future improvements to \CFA language and compiler. 523 523 \end{enumerate} 524 524 -
doc/uC++toCFA/uC++toCFA.tex
rfa59c40 r8e90fd6 11 11 %% Created On : Wed Apr 6 14:53:29 2016 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Fri Nov 15 09:55:34 202414 %% Update Count : 62 4913 %% Last Modified On : Fri Jan 17 07:39:09 2025 14 %% Update Count : 6284 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 16 … … 197 197 198 198 199 \section{Stream I/O}200 201 \CFA output streams automatically separate values and insert a newline at the end of the print.202 \begin{cquote}203 \begin{tabular}{@{}l|l@{}}204 \begin{uC++}205 #include <@iostream@>206 using namespace std;207 int i; double d; char c;208 cin >> i >> d >> c;209 cout << i << ' ' << d << ' ' << c | endl;210 \end{uC++}211 &212 \begin{cfa}213 #include <@fstream.hfa@>214 215 int i; double d; char c;216 sin | i | d | c;217 sout | i | d | c218 \end{cfa}219 \end{tabular}220 \end{cquote}221 222 223 199 \section{Looping} 224 200 … … 240 216 for ( i; 0 @-@~ 10 ) { ... } 241 217 \end{cfa} 242 \\ 243 \hline 218 \end{tabular} 219 \end{cquote} 220 221 \begin{cquote} 222 \begin{tabular}{@{}l|l@{}} 244 223 \begin{uC++} 245 224 int i = 0 … … 253 232 @else@ { ... } // i == 10 254 233 \end{cfa} 255 \\ 256 \hline 234 \end{tabular} 235 \end{cquote} 236 237 \begin{cquote} 238 \begin{tabular}{@{}l|l@{}} 257 239 \begin{uC++} 258 240 @L1:@ for ( ;; ) { … … 271 253 } 272 254 } 255 \end{cfa} 256 \end{tabular} 257 \end{cquote} 258 259 260 \section{Stream I/O} 261 262 \CFA output streams automatically separate values and insert a newline at the end of the print. 263 \begin{cquote} 264 \begin{tabular}{@{}l|l@{}} 265 \begin{uC++} 266 #include <@iostream@> 267 using namespace std; 268 int i; double d; char c; 269 cin >> i >> d >> c; 270 cout << i << ' ' << d << ' ' << c << endl; 271 \end{uC++} 272 & 273 \begin{cfa} 274 #include <@fstream.hfa@> 275 276 int i; double d; char c; 277 sin | i | d | c; 278 sout | i | d | c 279 \end{cfa} 280 \end{tabular} 281 \end{cquote} 282 To disable/enable automatic newline at the end of printing, use @nlOff@/@nlOn@ and @nl@. 283 \begin{cquote} 284 \begin{tabular}{@{}l|l@{}} 285 \begin{uC++} 286 287 for ( int i = 0; i < 5; i += 1 ) cout << i << ' '; 288 cout << @endl@; 289 290 0 1 2 3 4 291 \end{uC++} 292 & 293 \begin{cfa} 294 sout | @nlOff@; // disable auto nl 295 for ( i; 5 ) sout | i; 296 sout | @nl@; 297 sout | @nlOn@; // reenable auto nl 298 0 1 2 3 4 299 \end{cfa} 300 \end{tabular} 301 \end{cquote} 302 Floating-point numbers without a fraction print with a decimal point, which can be disabled with @nodp@. 303 \begin{cquote} 304 \begin{tabular}{@{}l|l@{}} 305 \begin{uC++} 306 cout << 3.0 << ' ' << showpoint << setprecision(0) << 3.0 << endl; 307 3 3. 308 \end{uC++} 309 & 310 \begin{cfa} 311 sout | @nodp( 3.0 )@ | 3.0; 312 3 3. 273 313 \end{cfa} 274 314 \end{tabular} … … 291 331 if ( ... ) @_Throw@ E( /* initialization */ ); 292 332 ... 293 } @_CatchResume@( E & ) { ... // reference 294 } catch( E & ) { ... 295 } catch( ... ) { ... // catch any 296 } _Finally { ... 297 } 333 } @_CatchResume@( E & /* reference */ ) { ... } 334 catch( E & ) { ... } 335 catch( ... /* catch any */ ) { ... } 336 _Finally { ... } 298 337 \end{uC++} 299 338 & … … 308 347 if ( ... ) @throw@ @ExceptionInst@( E, /* intialization */ ); 309 348 ... 310 } @catchResume@( E * ) { ... // pointer 311 } catch( E * ) { ... 312 } catch( exception_t * ) { ... // catch any 313 } finally { ... 314 } 349 } @catchResume@( E @*@ /* pointer */ ) { ... } 350 catch( E * ) { ... } 351 catch( exception_t @*@ /* catch any */ ) { ... } 352 finally { ... } 315 353 \end{cfa} 316 354 \end{tabular} … … 330 368 ... suspend(); ... 331 369 } 332 } @_CatchResume@( E & ) { // reference 333 ... 334 } catch( E & ) { 335 ... 336 } 370 } @_CatchResume@( E & /* reference */ ) { ... } 371 catch( E & ) { ... } 337 372 } 338 373 \end{uC++} … … 346 381 ... suspendPoll ... 347 382 disable_ehm(); 348 } @catchResume@( E * ) { // pointer 349 ... 350 } catch( E & ) { 351 ... 352 } 383 } @catchResume@( E * ) { ... } 384 catch( E & ) { ... } 353 385 } 354 386 \end{cfa} … … 556 588 557 589 558 \section{Thread}559 560 \begin{cquote}561 \begin{tabular}{@{}l|ll@{}}562 \begin{uC++}563 564 @_Task@ T {565 // private task fields566 void main() {567 ... @_Resume E( ... ) _At partner@;568 ... @uThisTask();@ ...569 }570 public:571 };572 \end{uC++}573 &574 \begin{cfa}575 #include <$thread$.hfa>576 @thread@ T {577 // private task fields578 579 };580 void main( @T & t@ ) {581 ... @resumeAt( partner, ExceptionInst( E, ... )@ );582 ... @active_thread();@ ...583 }584 \end{cfa}585 \\586 \multicolumn{2}{@{}l@{}}{\lstinline{T t; // start thread in main routine}}587 \end{tabular}588 \end{cquote}589 590 591 590 \section{\lstinline{COBEGIN}/\lstinline{COFOR}} 592 591 … … 602 601 BEGIN osacquire( cout ) << "C" << endl; END 603 602 BEGIN osacquire( cout ) << "D" << endl; END 604 BEGIN osacquire( cout ) << "E" << endl; END605 603 @COEND@ 606 604 @COFOR@( i, 1, 10, … … 619 617 corun { mutex( sout ) sout | "C"; } 620 618 corun { mutex( sout ) sout | "D"; } 621 corun { mutex( sout ) sout | "E"; }622 619 } 623 620 @cofor@( i; 10 ) { … … 703 700 } 704 701 \end{cfa} 702 \end{tabular} 703 \end{cquote} 704 705 706 \section{Thread} 707 708 \begin{cquote} 709 \begin{tabular}{@{}l|ll@{}} 710 \begin{uC++} 711 712 @_Task@ T { 713 // private task fields 714 void main() { 715 ... @_Resume E( ... ) _At partner@; 716 ... @uThisTask();@ ... 717 } 718 public: 719 }; 720 \end{uC++} 721 & 722 \begin{cfa} 723 #include <$thread$.hfa> 724 @thread@ T { 725 // private task fields 726 727 }; 728 void main( @T & t@ ) { 729 ... @resumeAt( partner, ExceptionInst( E, ... )@ ); 730 ... @active_thread();@ ... 731 } 732 \end{cfa} 733 \\ 734 \multicolumn{2}{@{}l@{}}{\lstinline{T t; // start thread in main routine}} 705 735 \end{tabular} 706 736 \end{cquote} -
doc/user/user.tex
rfa59c40 r8e90fd6 11 11 %% Created On : Wed Apr 6 14:53:29 2016 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Sat Dec 7 16:53:37 202414 %% Update Count : 697 013 %% Last Modified On : Fri Jan 17 14:20:39 2025 14 %% Update Count : 6971 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 16 … … 893 893 still works. 894 894 Nevertheless, reversing the default action would have a non-trivial effect on case actions that compound, such as the above example of processing shell arguments. 895 Therefore, to preserve backwards compatibility, it is necessary to introduce a new kind of ©switch© statement, called \Indexc{choose}, with no implicit fall-through semantics and an explicit fall-through if the last statement of a case-clause ends with the new keyword \Indexc{fallthrough} /\-\Indexc{fallthru}, \eg:895 Therefore, to preserve backwards compatibility, it is necessary to introduce a new kind of ©switch© statement, called \Indexc{choose}, with no implicit fall-through semantics and an explicit fall-through if the last statement of a case-clause ends with the new keyword \Indexc{fallthrough}, \eg: 896 896 \begin{cfa} 897 897 ®choose® ( i ) { … … 901 901 case 5: 902 902 ... 903 ®fallthr u®; §\C{// explicit fall through}§903 ®fallthrough®; §\C{// explicit fall through}§ 904 904 case 7: 905 905 ... … … 911 911 Like the ©switch© statement, the ©choose© statement retains the fall-through semantics for a list of ©case© clauses. 912 912 An implicit ©break© is applied only at the end of the \emph{statements} following a ©case© clause. 913 An explicit ©fallthr u© is retained because it is a C-idiom most C programmers expect, and its absence might discourage programmers from using the ©choose© statement.913 An explicit ©fallthrough© is retained because it is a C-idiom most C programmers expect, and its absence might discourage programmers from using the ©choose© statement. 914 914 As well, allowing an explicit ©break© from the ©choose© is a carry over from the ©switch© statement, and expected by C programmers. 915 915 \item … … 950 950 case 3: 951 951 if ( ... ) { 952 ... ®fallthr u;® // goto case 4952 ... ®fallthrough;® // goto case 4 953 953 } else { 954 954 ... … … 985 985 for ( ... ) { 986 986 // multi-level transfer 987 ... ®fallthr ucommon;®987 ... ®fallthrough common;® 988 988 } 989 989 ... … … 8053 8053 \begin{cquote} 8054 8054 \Indexc{basetypeof}, \Indexc{choose}, \Indexc{coroutine}, \Indexc{disable}, 8055 \Indexc{enable}, \Indexc{exception}, \Indexc{fallthrough}, \Indexc{fallthr u},8055 \Indexc{enable}, \Indexc{exception}, \Indexc{fallthrough}, \Indexc{fallthrough}, 8056 8056 \Indexc{finally}, \Indexc{fixup}, \Indexc{forall},\Indexc{generator}, 8057 8057 \Indexc{int128}, \Indexc{monitor}, \Indexc{mutex}, \Indexc{one_t}, … … 8079 8079 \Indexc{exception} \\ 8080 8080 \Indexc{fallthrough} \\ 8081 \Indexc{fallthr u}\\8081 \Indexc{fallthrough} \\ 8082 8082 \end{tabular} 8083 8083 &
Note:
See TracChangeset
for help on using the changeset viewer.