Garbage collection is key to improving the productivity and code quality in virtually every computing system with dynamic memory requirements. It dramatically reduces the software complexity and consequently allows the programmers to concentrate on the real problems rather than struggling with memory management issues, which finally results in higher productivity. The code quality is also improved because the two most common memory related errors -dangling pointers and memory leaks -can be prevented (assuming that the garbage collectors are implemented correctly and the user programs are not malicious).However, real-time systems, particularly those with hard real-time requirements, always choose not to use garbage collection (or even dynamic memory) in order to avoid the unpredictable executions of garbage collectors as well as the chances of being blocked due to the lack of free memory. Much effort has been expended trying to build predictable garbage collectors which can provide both temporal and spatial guarantees. Unfortunately, most existing work leads to systems that cannot easily achieve a balance between temporal and spatial performance, although their worst-case behaviours in both dimensions can be predicted. Moreover, the real-time systems targeted by the existing real-time garbage collectors are not the state-ofthe-art ones. The scheduling of those garbage collectors has not been integrated into the modern real-time scheduling frameworks, which makes the benefits provided by those systems very difficult to obtain. This thesis argues that the aforementioned issues should be tackled by introducing new design criteria for real-time garbage collectors. The existing criteria are not enough to reflect the unique requirements of real-time systems. A new performance indicator is proposed to describe the capability of a real-time garbage collector to achieve better balance between temporal and spatial performance. Moreover, it is argued that new real-time garbage collectors should be integrated with the real-time task model and more advanced scheduling techniques should be adopted as well.A hybrid garbage collection algorithm, which combines both reference counting and mark-sweep, is designed according to the new design criteria. On the one hand, the reference counting component helps reduce the overall memory requirements. On the other hand, the mark-sweep component periodically identifies cyclic garbage, which cannot be found by the reference counting component. Both parts of the collector are executed by segregated tasks, which are released periodically as the hard real-time user tasks. In order to improve the performance of soft-or non-realtime tasks in our system while still guaranteeing the hard real-time requirements, the dual-priority scheduling algorithm is used for all the tasks including the GC tasks. A multi-heap approach is also proposed to bound the impacts of the softor non-real-time tasks on the overall memory usage as well as the executions of the GC tasks. More importantly, static ana...