Summary: | 碩士 === 國立交通大學 === 資訊科學與工程研究所 === 105 === rules. It replaces certain
instructions with equivalent ones that follow the sandbox rules. In particular, some instructions must be placed at specific alignments and instructions cannot sit across the bundle boundaries. The above two constraints create "holes" in the instruction address space, which are padded with the nop (0x90) instructions. Furthermore,
due to the padding process, some short jump instructions are space-exhausted and must be replaced with longer ones. However, naively replacing short jumps with longer ones might break the above two constraints and cause unacceptable time and space wasting. Therefore, we designed an algorithm for converting the spaceexhausted
short jumps and guarantees that above two constraints hold. The algorithm works recursively through the dependency of the short jump instructions. By our experiment, small libraries will be larger than NaCl ones by about 8%.
The normal sized libraries will be larger than NaCl ones by about 44% on average. We also suggest using the translator as an alternative to download the original libraries from the server if the network bandwidth is lower than 7.5Mbps. By algorithm, the change ratio of the short jumps is about 8.4%. There are 3~4% overhead on small libraries and 13~15% overhead on normal sized libraries.
|