Ultrafast photonic neuromorphic processing and nonlinearity mitigation in long-haul transmissions by nonlinear optical signal processing