I.It is a test and set(load the previous value of R0 and store 1 into it),instruction,atomic in nature.Only one process executing TSL can only enter CS as it makes the value of variable=1 and other process trying to enter the CS would find value of variable=1 and hence wont enter the CS.
TSL can be thought of as
1.Load Ro
2 Store 1
3.CMP R0,#0
4.JNZ step 1
1 and 2 as atomic.
ME is guaranteed.
II. TSl suffers unbounded waiting.This is because there is no strict alteration and number of processes are also not bounded.
Lets us suppose
1.TSL
2.while(TSl!=1);
3.CS
4. store variable=0
P1:12 CS| P2 wants to enter but has to wait due to variable being 1 |P1 :4 | P3 enters executes TSL 1 2 CS | P2 wants to enter but has to wait due to variable being 1 |P3 :4 |P4 enters
So poor P2 everytime has to starve unlucky guy.
III. From the above example only we see that P2 although came first was scheduled later so FCFS not maintained.
Iv. ME guaranteed,
A)I Only