add queue, implement queue-based alignment