![]() no old software exists), this stage scans through the application source files and transforms the initialized global variables into members of one structure, called iglobStruct, and uninitialized global variables into members of another structure, called uglobStruct. If this is the first time software is being installed on the sensor nodes (i.e. Hermes adds one more stage (Structure generator) to the executable building process. Placement of global variables Since we desire a compiler-independent solution, Hermes uses the fact that members of a structure are placed in the same order in RAM as they are declared within the structure. ![]() But this calls for a complex modification to the core of a compiler, which in turn makes the solution difficult to port. Since the location of global variables in RAM is dependent on the compiler specifics, one solution is to change the compiler itself and place the global variables such that the similarity in positions of the variables between the old and the new versions is maximized. So the programmer has no control over the placement of the global variables in RAM. It should be noted that the actual order of the global variables in RAM is determined by the compiler implementation, not by the order in which they are declared in the user program. ![]() So, a mechanism to mitigate the effects of global variable shifts should be a very important component of application level modifications to make the delta script size proportional to the actual amount of change made in the software. The size of the delta script depends on the number of global variables that are shifted and the number of instructions that refer to those shifted variables. This is disproportionately larger than the actual amount of change made in the software. In this case, the size of the delta script produced by using only indirection table is 6090 bytes. (a) Old and (b) new images without indirection table (c) Old and (d) new images with indirection table in Hermes.
0 Comments
Leave a Reply. |