汇编与gdb调试

常用操作符

类型语法例子备注
常量符号$ 开头$-42$0x15213hex or oct
寄存器符号 % 开头%esi%raxvalue or adddress
内存地址括号括起来(%rbx)0x1c(%rax)0x4(%rcx, %rdi, 0x1)

常用汇编指令

InstructionEffect
mov %rbx, %rdxrdx = rbx
ass (%rdx), %r8r8 += value at rdx
mul $3, %r8r8 *= 3
sub $1, %r8r8--
lea (%rdx, %rbx, 2), %rdxrdx = rdx + rbx*2

阅读剩余部分 -

计算机系统导论课堂笔记

Bits, Bytes, and Integers

Representing information as Bits

Base 2 Number Representation
Byte = 8 Bits -> Base 16 number Representation
Data Representation

C Data TypeTypical 32-bitInter IA32x86-64
............

Bit-level manipulations

and or not xor

Representing & Manipulating Sets

Shift Operations
    Left Shift: Throw away extra bits on left. Fill with 0's on right.
    Right Shitf: Throw away extra bits on right.
        Logical Shift: Fill with 0's on left.
        Arithmetic Shift: Replicate most siginificant bit on left.
    Undefined Behavior: <0 || >= word size


阅读剩余部分 -

基于本地PAC的国外流量加速代理

因为学校教育网的原因,许多时候打开国外地址需要手动切换免费地址收费地址,不仅麻烦而且会很容易忘记关收费地址记性差怪我咯,所以使用两台服务器完成PAC的自动代理。其实也跟协议有关咯,此处不细说,就是想不用sock5。原理图如下:

阅读剩余部分 -

When you are old

William Butler Yeats原文

When you are old and grey and full of sleep,

And nodding by the fire, take down this book,

And slowly read, and dream of the soft look

Your eyes had once, and of their shadows deep;

How many loved your moments of glad grace,

And loved your beauty with love false or true,

But one man loved the pilgrim Soul in you,

And loved the sorrows of your changing face;

And bending down beside the glowing bars,

Murmur, a little sadly, how Love fled

And paced upon the mountains overhead

And hid his face amid a crowd of stars.

阅读剩余部分 -

如果当时

夜深忽梦少年事系列

如果当时
作曲 : 许嵩
作词 : 许嵩
为什么 你当时对我好
又为什么 现在变得冷淡了
我知道 爱要走难阻挠
反正不是我的 我也不该要
你和我 曾经有共同爱好
谁的耳边 总有绝句在萦绕
我们俩 用文言文对话真的很搞笑
还笑那曹操贪慕着小乔











阅读剩余部分 -

最新文章

最近回复

分类

归档

其它

微博

基佬们

Fork me on GitHub