In this paper, we present a dual-band all-optical logic gate based on a coherent perfect absorption metasurface. By utilizing the principle of coherent perfect absorption, we can manipulate the interference between two input signals by adjusting their relative phase difference. This allows us to implement logic functions such as AND, OR, and XOR in the second (1310 nm) and third (1550 nm) windows of the communication band. Moreover, we present the concept of "contrast" as a quantitative metric to assess the performance of each logic gate. The simulation results show that the contrast between the AND gate and the XOR gate can reach 6.4 dB and 17.8 dB at 1310 nm, as well as 6.1 dB and 18.9 dB at 1550 nm, rendering it highly advantageous for practical applications. The realization of ultrafast operation and low power consumption in coherent perfect absorption metasurfaces would significantly contribute to advancing the progress of optical data processing.