For this question, swap does not include RAM and only refers to the configured space on the disk. According to, http://www.ualberta.ca/CNS/RESEARCH/LinuxClusters/mem.html, a program's memory usage consists of text, data, bss, stack, and heap. The stack has a soft limit which can be removed. Let's assume it is removed. It is known the swap can augment heap (Can swap space accomodate single process?). Can swap also support or augment the stack, text, data, and bss parts of the memory required by a process, should RAM become insufficient?
Which parts of Memory can Swap Support
memory;swap