fixed mapping algorithm, which now allocates all computational
component. (Assumption -- All devices are static)