Òåõíèêà îïòèìèçàöèè ïîä ëèíóõà

       

îïòèìèçèðîâàííûé âàðèàíò


Ðàçóìååòñÿ, îïåðàòîð goto íåîáÿçàòåëüíî äîëæåí ïðèñóòñòâîâàòü â ïðîãðàììíîì êîäå â ÿâíîì âèäå è îí âïîëíå ìîæíî áûòü "ðàñòâîðåí" â öèêëå:

while(a)                                                   // lab_1:   if (a) goto lab_4

{

                while(b)                                   // lab_2:   if (b) goto lab_3      /* ïåðåõîä íà áåçóñëîâíûé ïåðåõîä */

                {

                                /* êîä öèêëà */

                }                                              //              goto lab_2

}                                                              // lab_3:   goto lab_1

                                                                // lab_4:



Ñîäåðæàíèå ðàçäåëà