====== Differences ====== This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
soc:2009:lynusvaz:journal:week4 [2009/06/17 21:08] lynusvaz created |
soc:2009:lynusvaz:journal:week4 [2009/06/22 21:44] (current) lynusvaz |
||
---|---|---|---|
Line 9: | Line 9: | ||
Commit: [[http://git.etherboot.org/?p=people/lynusvaz/gpxe.git;a=commit;h=2e730a8908cd91b322a1a96f024b8ba59fe1987c|Beware, this is very rough, and I still have to do the cleaning up]] | Commit: [[http://git.etherboot.org/?p=people/lynusvaz/gpxe.git;a=commit;h=2e730a8908cd91b322a1a96f024b8ba59fe1987c|Beware, this is very rough, and I still have to do the cleaning up]] | ||
+ | June 18: Continued working on the same idea. Worked on the memory leaks, and putting in the quotes for the arithmetic parser, too. Commit: [[http://git.etherboot.org/?p=people/lynusvaz/gpxe.git;a=commit;h=f2bd84ba6d4180464fed885703d2d1be1c64bc96|Almost works]] | ||
+ | June 19: Had a talk with Stefan about the work done so far. He mentioned that a table-based parser might be a good idea, since the expansion code works almost the same. I tried out that approach, first as a stand-alone expansion function. So it's back to valgrind, to test the memory allocation. It does look much better than the previous code, since there is not too much code duplication. Once I tested it, I integrated it into gPXE. Commit: [[http://git.etherboot.org/?p=people/lynusvaz/gpxe.git;a=commit;h=56c619c876c01b3a9bdcced39425e89030617fe8|Table-based]] | ||
+ | |||
+ | June 20: Trying to decide the implementation of if-else branches (next week's task). This is what I've thought of: | ||
+ | if <cond> | ||
+ | <statements> | ||
+ | else | ||
+ | <statements> | ||
+ | fi | ||
+ | I will also have a stack of boolean values, representing the evaluated conditions. Each time an if is encountered, the condition is evaluated and pushed on the stack. Similarly, when an else is encountered, the top of stack is negated, and when a fi is found, the top condition is pushed off. Statements should be executed only if the value on the top of the stack is true, or they can change the stack. | ||
+ | |||
+ | |||
+ | June 21: Did some last testing, and sent out my work to Etherboot-developers. [[http://git.etherboot.org/?p=people/lynusvaz/gpxe.git;a=commit;h=b56dbdab708f546bd8ff4eb71d3c9c7125a33255|Here it is.]] |