Monthly Archives: April 2015
Tsinghua ucore kernel with GKD
I talked to Professor Chen from Tsing Hua (http://media.cs.tsinghua.edu.cn/cn/cheny), i tried their education kernel (https://github.com/chyyuu/ucore_lab). I modified a little bit their Makefile so that it can be compiled in Mac and debug using my GKD debugger. 2015/04/30
I finally understand why “DW_OP_fbreg: 0” is possible
In the following function kmalloc2, take a look the first parameter, the memory location of that parameter is stated by dwarf “DW_AT_location : 2 byte block: 91 0 (DW_OP_fbreg: 0)”, where “DW_OP_fbreg: 0” means stack+0. I was thinking why it is possible. Because when cpu executed call instruction, it already pushed 4 bytes into the […] 2015/04/14
objdump has bug
objdump command has bug, i tried to use this command “objdump -dS kernel” to display mixed assembly and c code. But objdump has bug, it dump the same piece of c source code in two different memory locations. I double checked the dwarf data, nothing wrong. On more prove the dwarf is correct, my GKD […] 2015/04/11
I finally understand why same parameter even has multiple locations
I finally understand why same parameter even has multiple locations. My pass concept is parameter stay in the stack. But after hacking the dwarf, it show me same parameter have multiple location during execution. Take a look below image, I wrote a function call kmalloc2 (blue arrow), the third parameter “size” has three locations (yellow […] 2015/04/07