System V AMD64 ABI calling conventions

The calling convention of the System V AMD64 ABI is followed on Solaris, Linux, FreeBSD, Mac OS X, and other UNIX-like or POSIX-compliant operating systems. The first six integer or pointer arguments are passed in registers RDI, RSI, RDX, RCX, R8, and R9, while XMM0, XMM1, XMM2, XMM3, XMM4, XMM5, XMM6 and XMM7 are used for floating point arguments. For system calls, R10 is used instead of RCX. As in the Microsoft x64 calling convention, additional arguments are passed on the stack and the return value is stored in RAX.

Registers RBP, RBX, and R12-R15 are callee-save registers; all others must be saved by the caller if they wish to preserve their values.

Unlike the Microsoft calling convention, a shadow space is not provided; on function entry, the return address is adjacent to the seventh integer argument on the stack.

Over!

x86 pslldq to Loongson psllq

x86 pslldq 指令逻辑左移字节为单位的数据,而转换成龙芯的MMI只能使用 dsll 和 dsrl 指令模拟实现,需要特别注意的是 dsll 和 dsrl 指令移动的数据是以位为单位的。

/* SSE: pslldq (bytes) */
#define _mm_psllq(_D, _d, _s, _s64, _tf)                    \
        "subu %["#_tf"], %["#_s64"], %["#_s"] \n\t"         \
        "dsrl %["#_tf"], %["#_d"l], %["#_tf"] \n\t"         \
        "dsll %["#_D"h], %["#_d"h], %["#_s"] \n\t"          \
        "dsll %["#_D"l], %["#_d"l], %["#_s"] \n\t"          \
        "or %["#_D"h], %["#_D"h], %["#_tf"] \n\t"
pslldq $4, %xmm0 => mm_psllq(d, d, s32, s64, t)

Over!

udevd worker timeout

Error information

Waiting for UDev uevents to be processed    [BUSY]
udevd[155]: worker [173] timeout, kill it
udevd[155]: seq 1431 '/devices/pci0000:00/0000:00:1c.1/0000:12:00.0' killed
udevd[155]: worker [173] terminated by signal 9 (Killed)

PCI device

12:00.0 Network controller: Broadcom Corporation BCM4313 802.11b/g/n Wireless LAN Controller (rev 01)

How to fix?
Edit /etc/rc.conf

MODULES=(fuse brcmsmac)  # add brcmsmac

Over!

Linux 输入设备共享程序: RInput

是否在调试中因频繁切换 Target 和 Host 的输入设备而感觉头大?是否因为 Target 主机的键盘不适应还感到不爽?RInput
帮你解决这个问题,它可以通过定义的一个按键来将 Host 主机的输入设备在两个主机间切换。

源代码:http://heiher.info/sftp/repos/rinput.git
二进制程序:http://heiher.info/sftp/files/rinput/

使用方法:
Target: (Server)
./rinputd bind_address port

Host: (Client)
./rinput server_address port event_device_path … (<= 10) 默认 Switch Key Pause Over!