This patch addresses a couple of problems:
- The maximum supported offset of LE is -4094.
- The offset of WLS also needs to be checked, this uses a maximum positive offset of 4094.
The use of BasicBlockUtils has been changed because the block offsets weren't being initialised, but isBBInRange checks both positive and negative offsets. ARMISelLowering has been tweaked because the test case presented another pattern that wasn't supported.
just a nit, perhaps it reads easier if this is just this instead of a nested if: