ARM's Speculation Tracking Support Lands In GCC As Part Of Spectre V1 Safeguards
When -mtrack-speculation is enabled, the compiler generates code for tracking data speculation to see whether the CPU control flow speculation matches its data flow calculations in order to see if the CPU is speculating incorrectly and the code potentially susceptible to a Spectre Variant One style exploit.
This speculation tracking support was added for AArch64 in the current GCC implementation but could be added to other architectures too. It doesn't sound like ARM will bring this to 32-bit ARM due to less registers and being more complicated to implement this functionality. I haven't seen any AArch64 GCC benchmarks with track-speculation enabled but will add it to my performance testing TODO list.
Those wanting the support right now can grab it via GCC SVN/Git while it will be part of the GCC 9.1 stable release in 2019.