Latency is a challenge in digital computer music. You must understand what is causing latency in general to reduce it.
• Preferences > Audio > Devices > I/O Buffer Size
This type of latency is related to the computer (power) and the sound card. The smaller the buffer size, the lower the latency, but the higher the CPU load. Finding the right buffer size for your project, computer, and sound card requires a lot of trial and error. Buffer sizes that are too small will cause glitches, spikes, and crackles.
• Latency caused by plugins:
Every computation causes latency. Some plugins need more, some less. As a rule of thumb, simple EQs or compressors/limiter do not need much computing power. Pitch-related plugins or fancy sound design plugins can cause huge latency. This is valid for software instruments too. Some need more some need less CPU power.
• We all love Latency Compensation, ( Preferences > Audio > General > Plugin Latency > Compensation > ...)
this adds a delay to all other tracks which don't a heavy computational plugins inserted. Without latency compensation, every track would have it's own latency. That would be a nightmare, especially for rhythmic events. Now, because of the smart use of delays, we have only one summed latency.
• Sample Rate:
Project Setting > Audio > General > Sample Rate
Although, I never change my sample rate for latency reasons, it's good to know that the higher the sample rate, the lower the latency, but the higher the CPU load.
• Maybe I forgot some other latency causing effects...
Logic Pro has a feature to combat latency in recording: Low Latency Mode.
Preferences > Audio > General > Plugin Latency > Low Latency Mode
Low Latency Mode disables some plugins, but you can record almost without latency (still depending on the I/O settings). It's important to disable Low Latency Mode after the recording and while playing back. In some configurations, such as using UAD plugins, Low Latency Mode must be enabled all the time. In this case the plugins are computed on external hardware. Please read the vendor's manuals.
Track delay and Region Delay:
I use Region Delay (and Track Delay) very often. But only for musical reasons, e.g. when an instrument or audio file (or track) needs to be adjusted in one direction or the other.
Avoid to play with Recording Delay.
I hope this helps a little.