I was doing some bit operations and when i try to get the bit representation of a negative number say -1 on my Intel processor the value that i get is

11111111111111111111111111111111

I had this impression that the msb is used to store the sign of a number so i was expecting that only the 0 (the value for 1) and 31st (the sign bit)

bits should be 1 but then all the bits are 1. I am still unable to understand why is this the case?