There should not be any difference in pin behaviour between compilers. XC8 emits a BSF PORTB, 0x4 and I assume Mikro would do the same if you used PORTB.B4 rather than PORTB.B5. The delays you have inserted should be adequate to avoid RMW issues.
You mention different PIC models, pin and port numbers, and compilers, but not different TM1637s. The TM1637 modules have capacitors on the CLK and DIO, that are supposed to be 100pF. If one or more of them was mistakenly populated with a much larger value capacitor such then the waveforms you are seeing would make a lot more sense.
Missing or intermittent power supply connections can cause similar weird effects because things get powered through the data lines.