Fix signals layout and optimize