| ??? 11/28/02 11:27 Read: times |
#33353 - RE: linked list serial port buffer |
As already stated in earlier answers, linked lists and dynamic memory allocation are two different things and do not need to be used together. Even though the dynamic memory allocation itself is managed using linked lists. Even though they are really used together in many applications.
Some drawbacks of using dinamyc memory allocation and/or linked lists: 1) It takes some not negligible time to execute alloc and free. 2) Succesive "allocs" anf "frees" left the memory (the heap) full of "holes". The manager use to assign the first free memory block with enough size when alloc is called. The manager makes nothing to eliminate the free holes between used blocks (when free is called), except for mixing adjacent free blocks creating a longer block. A garbage collection procedure would be long and maybe unsafe. 3) A single error in a linked list structure usually means all the data is lost. A power fail when creating or deleting nodes will probably result in the corruption of the whole list. I suppose data is in a non-volatile memory, otherwise all the data will be lost anyway. Alfredo. |
| Topic | Author | Date |
| linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer, Jez | 01/01/70 00:00 | |
| RE: Erik | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: Erik | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| An appropriate example? | 01/01/70 00:00 | |
| RE: An appropriate example? | 01/01/70 00:00 | |
| RE: An appropriate example? | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: Interrupt precognition | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
| RE: linked list serial port buffer | 01/01/70 00:00 | |
RE: linked list serial port buffer | 01/01/70 00:00 |



