59 Commits

Author SHA1 Message Date
zenon
72da8e371b Initialize bestSolution to all -1 2018-06-08 11:12:00 +02:00
zenon
051a727caf Write complete solution array to shared memory without any delimiters 2018-06-08 11:03:54 +02:00
zenon
065f445c79 Change size of shared memory to MAX_SIZE instead of CIRC_BUF_SIZE 2018-06-08 10:58:01 +02:00
zenon
8605c6e820 getSolution writes head instead of where head is pointing 2018-06-08 10:21:33 +02:00
zenon
9cb4d66d4b Change wrong wait_sem to post_sem to avoid deadlock 2018-06-08 10:08:37 +02:00
zenon
da416ca283 Do unlinking of SEM_WRITE_END in supervisor 2018-06-07 18:24:12 +02:00
zenon
829cc3cb3a Change error messages 2018-06-07 18:13:37 +02:00
zenon
834f3f7bf7 Unlinking not done in generator except for SEM_WRITE_END 2018-06-07 18:04:38 +02:00
zenon
84c2dcdd78 Modify error messages 2018-06-07 17:58:02 +02:00
zenon
de4ed6532c Rearrange cleanup() function and copy wait_sem() function from
supervisor
2018-06-07 17:52:49 +02:00
zenon
6ee735a030 Modify cleanup() function and make semaphores and shared memory global 2018-06-07 17:46:41 +02:00
zenon
8f91b5f974 Added cleanup() function 2018-06-07 17:46:00 +02:00
zenon
51724a3637 Proper closing and unlinking of semaphores and shared memory 2018-06-07 17:38:20 +02:00
zenon
a04c1aee71 Change name of semaphores 2018-06-07 17:26:28 +02:00
zenon
3057b4a0d4 Add own wait function 2018-06-07 17:08:49 +02:00
zenon
8b9d48e4d8 Not necessary to modify array of caller function main() 2018-06-07 17:00:25 +02:00
zenon
56df02a288 Initialize array for new solution to -1 2018-06-07 16:58:16 +02:00
zenon
3e34253092 Remove initializer of bestSolution array 2018-06-07 16:51:12 +02:00
zenon
a7ebeb7246 Change MAX_ITEMS to CIRC_BUF_SIZE for shared memory access 2018-06-07 16:50:02 +02:00
zenon
ed71c16797 Add new variable for CIRC_BUF_SIZE 2018-06-07 16:48:04 +02:00
zenon
1fbd1bf2b8 Added code for replacing bestSolution so far with new one 2018-06-07 16:35:01 +02:00
Kranklyboy
699d1b9ed4 Read whole solutions from shared memory 2018-06-07 12:31:25 +02:00
Kranklyboy
a8d8999fa1 Allow one more int for separating solutions in shared memory 2018-06-07 12:30:17 +02:00
Kranklyboy
5a9d00c48a Write whole solutions to shared memory 2018-06-07 12:18:36 +02:00
zenon
10ec964fec Read and write solution characterwise 2018-06-07 10:40:55 +02:00
zenon
eb45b4eb92 Allow shared memory read 2018-06-07 10:35:49 +02:00
zenon
5fe85da2ef Loop until supervisor exits 2018-06-07 10:33:42 +02:00
zenon
93131dc027 Cleanup of shared memory and semaphores 2018-06-07 10:30:15 +02:00
zenon
3af17e0d84 Write whole solution to shared memory and -1 if acyclic 2018-06-07 10:22:30 +02:00
zenon
db393a0b43 Modify spacing 2018-06-07 10:10:55 +02:00
zenon
80afbc9473 Activate shared memory and semaphores 2018-06-07 10:09:45 +02:00
zenon
160d66c9c4 Remove unnecessary isEmpty() function 2018-06-07 10:07:47 +02:00
zenon
d1ca1d59ce Remove count of validItems which is not needed because of the use of
semaphores
2018-06-07 10:04:25 +02:00
zenon
49357d1173 Initial semaphore test 2018-06-06 19:22:25 +02:00
zenon
8dbd116b88 Working 2018-06-06 19:22:01 +02:00
zenon
71ac479aca Remove printing of solutions for testing purposes 2018-06-06 18:00:46 +02:00
zenon
52b5f0e361 Modify caller array instead of copy 2018-06-06 17:59:27 +02:00
zenon
a5c402bc84 Remove whitespace at EOL 2018-06-06 17:28:15 +02:00
zenon
9983d25742 Calculate index and add to feedback arc set 2018-06-06 17:25:30 +02:00
zenon
7766b09f65 Change MAX_SIZE to 16 2018-05-31 15:25:19 +02:00
zenon
7382f0a43d findIndex() function added 2018-05-31 15:13:22 +02:00
zenon
1c913d4b82 Comments 2018-05-31 15:00:57 +02:00
zenon
a0785c17bc Boilerplate for semaphores complete 2018-05-31 12:22:53 +02:00
zenon
0ae6626e32 Added algorithm for generating random permutations of the set of nodes 2018-05-31 12:17:25 +02:00
zenon
b43a600510 Shared memory and semaphore setup as well as correct free() calls 2018-05-30 17:22:26 +02:00
zenon
b9ca106eb1 Merge branch 'master' of gitlab.com:kranklyboy/fb_arc_set 2018-05-30 17:18:37 +02:00
zenon
e3095f8ce0 Shared memory and semaphore setup 2018-05-30 17:18:11 +02:00
zenon
9ac6d9fbfe Boilerplate for shared memory 2018-05-30 17:10:53 +02:00
Kranklyboy
b49428e3df Merge branch 'master' of gitlab.com:kranklyboy/fb_arc_set 2018-05-29 16:04:27 +02:00
Kranklyboy
f03189228f Correct spelling error 2018-05-29 16:04:15 +02:00