How the operating system allocated to dual-channels memory?
You are completely misunderstanding what dual channel memory means; it is an implementation detail that is supposed to make memory access faster but completely invisible during operation. 

Let's say you have (simplified) a computer with two RAM chips. The computer could have one connection to both chips, or two connections, one to each chip. The CPU issues a command to read say 256 bit. With single channel memory, one command to transfer 256 bit is sent to the two RAM chips, and it takes some time to transfer 256 bit. With dual channel memory, the CPU automatically (without the OS doing _anything) sends two commands, one to each RAM chip, and each chip transmits 128 bits through its channel. Both commands run in parallel, so the time for memory transfer will be half the time.