Replaced extendCuda function with an Extender function object

The Facebuffer needed for inter-processor communication is
created in the Extender constructor and deleted in the destructor
of the Extender class.