- Timestamp:
- Oct 2, 2017, 6:02:32 PM (8 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- 21b7161
- Parents:
- 3096ec1 (diff), 617b4b2 (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:
- src/tests
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
src/tests/.expect/64/literals.txt
r3096ec1 r11a2d9b 1252 1252 ((void)(-((long double )0x.0123456789p09))); 1253 1253 ((void)__f__F_c__1('a')); 1254 ((void)__f__F_Sc__1( ((signed char )20)));1254 ((void)__f__F_Sc__1(20)); 1255 1255 ((void)__f__F_Uc__1(((unsigned char )21u))); 1256 ((void)__f__F_s__1( ((signed short int )22)));1256 ((void)__f__F_s__1(22)); 1257 1257 ((void)__f__F_Us__1(((unsigned short int )23u))); 1258 1258 ((void)__f__F_Ul__1(((unsigned long int )24))); -
src/tests/Makefile.am
r3096ec1 r11a2d9b 22 22 concurrent = yes 23 23 quick_test += coroutine thread monitor 24 concurrent_test = coroutine thread monitor multi-monitor sched-int-block sched-int-disjoint sched-int-wait sched-ext-barge sched-ext-else sched-ext-parse sched-ext-statment preempt 24 concurrent_test = \ 25 coroutine \ 26 thread \ 27 monitor \ 28 multi-monitor \ 29 preempt \ 30 sched-int-block \ 31 sched-int-disjoint \ 32 sched-int-wait \ 33 sched-ext-barge \ 34 sched-ext-dtor \ 35 sched-ext-else \ 36 sched-ext-parse \ 37 sched-ext-recurse \ 38 sched-ext-statment \ 39 sched-ext-when 40 25 41 else 26 42 concurrent=no -
src/tests/Makefile.in
r3096ec1 r11a2d9b 320 320 @BUILD_CONCURRENCY_TRUE@concurrent = yes 321 321 @BUILD_CONCURRENCY_FALSE@concurrent_test = 322 @BUILD_CONCURRENCY_TRUE@concurrent_test = coroutine thread monitor multi-monitor sched-int-block sched-int-disjoint sched-int-wait sched-ext-barge sched-ext-else sched-ext-parse sched-ext-statment preempt 322 @BUILD_CONCURRENCY_TRUE@concurrent_test = \ 323 @BUILD_CONCURRENCY_TRUE@ coroutine \ 324 @BUILD_CONCURRENCY_TRUE@ thread \ 325 @BUILD_CONCURRENCY_TRUE@ monitor \ 326 @BUILD_CONCURRENCY_TRUE@ multi-monitor \ 327 @BUILD_CONCURRENCY_TRUE@ preempt \ 328 @BUILD_CONCURRENCY_TRUE@ sched-int-block \ 329 @BUILD_CONCURRENCY_TRUE@ sched-int-disjoint \ 330 @BUILD_CONCURRENCY_TRUE@ sched-int-wait \ 331 @BUILD_CONCURRENCY_TRUE@ sched-ext-barge \ 332 @BUILD_CONCURRENCY_TRUE@ sched-ext-dtor \ 333 @BUILD_CONCURRENCY_TRUE@ sched-ext-else \ 334 @BUILD_CONCURRENCY_TRUE@ sched-ext-parse \ 335 @BUILD_CONCURRENCY_TRUE@ sched-ext-recurse \ 336 @BUILD_CONCURRENCY_TRUE@ sched-ext-statment \ 337 @BUILD_CONCURRENCY_TRUE@ sched-ext-when 338 323 339 324 340 # applies to both programs -
src/tests/coroutine.c
r3096ec1 r11a2d9b 10 10 // Created On : Thu Jun 8 07:29:37 2017 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Thu Jun 8 07:37:12201713 // Update Count : 512 // Last Modified On : Sun Sep 17 21:38:15 2017 13 // Update Count : 7 14 14 // 15 15 … … 18 18 19 19 coroutine Fibonacci { 20 int fn; // used for communication20 int fn; // used for communication 21 21 }; 22 22 … … 26 26 27 27 void main( Fibonacci & this ) { 28 int fn1, fn2; // retained between resumes29 this.fn = 0; // case 028 int fn1, fn2; // retained between resumes 29 this.fn = 0; // case 0 30 30 fn1 = this.fn; 31 suspend(); // return tolast resume31 suspend(); // restart last resume 32 32 33 this.fn = 1; // case 1 34 fn2 = fn1; 35 fn1 = this.fn; 36 suspend(); // return to last resume 33 this.fn = 1; // case 1 34 fn2 = fn1; fn1 = this.fn; 35 suspend(); // restart last resume 37 36 38 for ( ;; ) { // general case37 for ( ;; ) { // general case 39 38 this.fn = fn1 + fn2; 40 fn2 = fn1; 41 fn1 = this.fn; 42 suspend(); // return to last resume 39 fn2 = fn1; fn1 = this.fn; 40 suspend(); // restart last resume 43 41 } // for 44 42 } 45 43 46 44 int next( Fibonacci & this ) { 47 resume( this ); // transfer tolast suspend45 resume( this ); // restart last suspend 48 46 return this.fn; 49 47 } … … 52 50 Fibonacci f1, f2; 53 51 for ( int i = 1; i <= 10; i += 1 ) { 54 sout | next( f1 ) | ' ' |next( f2 ) | endl;52 sout | next( f1 ) | next( f2 ) | endl; 55 53 } // for 56 54 } -
src/tests/gmp.c
r3096ec1 r11a2d9b 10 10 // Created On : Tue Apr 19 08:55:51 2016 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Mon Sep 4 09:51:18201713 // Update Count : 55 012 // Last Modified On : Thu Sep 28 18:33:51 2017 13 // Update Count : 555 14 14 // 15 15 … … 97 97 98 98 sout | "Factorial Numbers" | endl; 99 Int fact; 100 fact = 1; // 1st case 99 Int fact = 1; // 1st case 101 100 sout | (int)0 | fact | endl; 102 101 for ( unsigned int i = 1; i <= 40; i += 1 ) {
Note:
See TracChangeset
for help on using the changeset viewer.